Results 1 to 6 of 6

Looping through text boxes

Threaded View

Cygnos Looping through text boxes 05-24-2008, 01:49 PM
VBA Noob Maybe Sub Macro1()... 05-24-2008, 02:17 PM
Cygnos Hmm well im using a UserForm,... 05-24-2008, 03:06 PM
Norie Take a look at the Controls... 05-24-2008, 03:10 PM
Cygnos Nori, you're deffo the hero... 05-24-2008, 03:19 PM
Kuskush Hi try this: Sub... 05-24-2008, 03:46 PM
  1. #1
    Registered User
    Join Date
    12-29-2007
    Posts
    18

    Looping through text boxes

    Hey Guys,

    another probatly stupid question:

    I have lots of objects in my userform, especially textboxes.
    So when i need to change the text in all them boxes i usually do it
    Text1.Text = Some stupid value in a stupid excel sheet
    Text2.Text = Some stupid value in a stupid excel sheet
    Text3.Text = Some stupid value in a stupid excel sheet
    Text4.Text = Some stupid value in a stupid excel sheet
    Text5.Text = Some stupid value in a stupid excel sheet

    Question: IS it possible to simplify this by coding something like
    For i = 1 to 45
    Text & i & .text = Some stupid value in a stupid excel sheet
    Next i
    (tried it , not working )

    Can anyone help me out? Ty
    Last edited by VBA Noob; 05-24-2008 at 02:03 PM.

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