Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
drop-down list that can be used firm-wide?
Hello!
I've been asked to make a form for everyone in our firm. It needs to have drop-down lists. I have tried the drop-down list method given in http://www.word.mvps.org/faqs/tblsfl...toTextList.htm and it works great, except that it won't work for other people unless I change our Normal.dot file that the firm uses, right? I don't have the access or the power to do that. Is there a way I can store the options in the document itself? Thank you again, -Lynne We're on a network and our Normal.Dot is controlled by the Powers That Be in the main office. I'vd |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
drop-down list that can be used firm-wide?
You don't really explain the purpose of the list, but what you should
probably do is create a template that you provide to all of the users that contains a userform. See the article "How to create a Userform" at: http://word.mvps.org/FAQs/Userforms/CreateAUserForm.htm The following code in a userform will populate a combobox on that form with data that is stored in a table in a Word document that is saved in a location that is available to all of the users: Private Sub UserForm_Initialize() Dim sourcedoc As Document, i As Integer, j As Integer, myitem As Range, m As Long, n As Long ' Modify the path in the following line so that it matches where you Saved Clients.doc Application.ScreenUpdating = False ' Open the file containing the client details Change the path and file name to suit your cicumstances Set sourcedoc = Documents.Open(FileName:="h:\projet\9501c-Sangaredi\11-Client\Document Management\Companies.doc") ' Get the number or clients = number of rows in the table of client details less one i = sourcedoc.Tables(1).Rows.Count - 1 ' Get the number of columns in the table of client details j = sourcedoc.Tables(1).Columns.Count ' Set the number of columns in the Listbox to match ' the number of columns in the table of client details cmbCompany.ColumnCount = j ' Define an array to be loaded with the client data Dim MyArray() As Variant 'Load client data into MyArray ReDim MyArray(i, j) For n = 0 To j - 1 For m = 0 To i - 1 Set myitem = sourcedoc.Tables(1).Cell(m + 2, n + 1).Range myitem.End = myitem.End - 1 MyArray(m, n) = myitem.Text Next m Next n ' Load data into combobox cmbCompany cmbCompany.List() = MyArray ' Close the file containing the client details sourcedoc.Close SaveChanges:=wdDoNotSaveChanges End Sub Also, see the article "Distributing macros to other users" at: http://www.word.mvps.org/FAQs/Macros...buteMacros.htm -- Hope this helps. Please reply to the newsgroup unless you wish to avail yourself of my services on a paid consulting basis. Doug Robbins - Word MVP "WordProc" wrote in message ... Hello! I've been asked to make a form for everyone in our firm. It needs to have drop-down lists. I have tried the drop-down list method given in http://www.word.mvps.org/faqs/tblsfl...toTextList.htm and it works great, except that it won't work for other people unless I change our Normal.dot file that the firm uses, right? I don't have the access or the power to do that. Is there a way I can store the options in the document itself? Thank you again, -Lynne We're on a network and our Normal.Dot is controlled by the Powers That Be in the main office. I'vd |
#3
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
drop-down list that can be used firm-wide?
The form should be created as a template, with the AutoText entries stored
in the template. The template should then be placed in the workgroup templates folder. -- Suzanne S. Barnhill Microsoft MVP (Word) Words into Type Fairhope, Alabama USA Word MVP FAQ site: http://word.mvps.org Email cannot be acknowledged; please post all follow-ups to the newsgroup so all may benefit. "WordProc" wrote in message ... Hello! I've been asked to make a form for everyone in our firm. It needs to have drop-down lists. I have tried the drop-down list method given in http://www.word.mvps.org/faqs/tblsfl...toTextList.htm and it works great, except that it won't work for other people unless I change our Normal.dot file that the firm uses, right? I don't have the access or the power to do that. Is there a way I can store the options in the document itself? Thank you again, -Lynne We're on a network and our Normal.Dot is controlled by the Powers That Be in the main office. I'vd |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Conditional Drop down list?? | Microsoft Word Help | |||
Drop down list from another drop down list in Word? | Microsoft Word Help | |||
check box and drop down list disappear | Microsoft Word Help | |||
using drop down list in a word form | Microsoft Word Help | |||
How do I create a drop down list in a form using Word? | New Users |