+ Reply to Thread
Results 1 to 3 of 3

Populating a text area in a user form from an Array???

Hybrid View

  1. #1
    Forum Contributor arlu1201's Avatar
    Join Date
    09-09-2011
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2003 & 2007
    Posts
    19,167

    Re: Populating a text area in a user form from an Array???

    Is this solved?

    If you solve a problem yourself before anyone else has responded, please take a moment to describe your solution, chances are some other member will benefit.

    Also,

    I have added code tags to your post. As per forum rule 3, you need to use them whenever you put any code in your post. Please add them in future. If you need more information on how to use them, check my signature below this post.
    If I have helped, Don't forget to add to my reputation (click on the star below the post)
    Don't forget to mark threads as "Solved" (Thread Tools->Mark thread as Solved)
    Use code tags when posting your VBA code: [code] Your code here [/code]

  2. #2
    Registered User
    Join Date
    08-16-2012
    Location
    Florida
    MS-Off Ver
    Excel 2016
    Posts
    33

    Re: Populating a text area in a user form from an Array???

    Yes, it is solved...Sorry about not posting solution or using code tags.

    I flipped the array the other direction, so that it was 9 tall by 6 wide. (Just because it was easier to enter the info that way for me)
    Replaced combo boxes with text boxes.
    Added a button to start a Vlookup to populate the questions.
    Here is what I added:

    Private Sub LoadTopics_Click()
    Dim DBA As String
    DBA = Me.DBA.Value
    Me.Q1.Value = Application.WorksheetFunction.VLookup(DBA, Sheets("Sheet4").Range("g1:l10"), 2, False)
    Me.Q2.Value = Application.WorksheetFunction.VLookup(DBA, Sheets("Sheet4").Range("g1:l10"), 3, False)
    Me.Q3.Value = Application.WorksheetFunction.VLookup(DBA, Sheets("Sheet4").Range("g1:l10"), 4, False)
    Me.Q4.Value = Application.WorksheetFunction.VLookup(DBA, Sheets("Sheet4").Range("g1:l10"), 5, False)
    Me.Q5.Value = Application.WorksheetFunction.VLookup(DBA, Sheets("Sheet4").Range("g1:l10"), 6, False)
    
    End Sub

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1