Results 1 to 2 of 2
  1. #1
    Join Date
    Aug 2006

    Question Unanswered: Word Visual Basic (VBA) MultiPage .additem code?

    Quick question - I'm using Microsoft Visual Basic 6.3 (VBA) for a multi page Form in Word to walk users through entering their resume. I have been designing this using the mulitpage option of a form with tabs for each of the resume areas. Some of the tabs will have the same type of data - for example - entering the types of degrees follks have, Phd, MA, BS etc.....

    I'd like to use the same code over & over for the choices I'm providing in the
    ComboBoxes but don't know how to list multi "add items" across the code.

    I tried the following but it bombed
    With cbodegree01 and cbodegree02 AND

    Here, I'll include my code it hopes that will help.

    Option Explicit
    Private Sub cmdOK_Click()
    Application.ScreenUpdating = False
    With ActiveDocument
    'Degree Bookmarks
    .Bookmarks("Type_of_Degree").Range.Text = cbodegree01.Value & ","
    Application.ScreenUpdating = True
    Unload Me
    End With
    End Sub

    Private Sub UserForm_Initialize()
    'Degree Combo Box Choices
    With cbodegree01
    .AddItem "AA"
    .AddItem "AAS"
    .AddItem "AD"
    End With

    I really need to combine the since I have a lot of choices and half way thru the coding I got an error that the code was too long.

    Any help is appreciated! Thanks!
    Last edited by loquin; 08-31-06 at 18:26. Reason: clarification that it's VBA and not VB.

  2. #2
    Join Date
    Aug 2006

    new thoughts on Word VB MultiPage .additems

    I'm now realizing the approach in my previous post may not be the way to go so would appreciate any suggestions on maybe storing the drop down items in a sep. text file and then referencing that file from within the VB code.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts