Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default Read Order When Using Tags on UserForm; Typename

Does anyone know the order in which VBA reads through tags when looping
through all tags of same name? It doesn't seem to follow a logical route
when reading the tags. All the textboxes are on the same userform tab. The
textboxes are in a 4x3 grid with the center column having the text boxes I'm
after here. I have tab stops assigned to the textboxes as well, but it
doesn't follow that order - which I would thought it would. Thanks for your
time.

For Each ctl In RREForm.Controls
If TypeName(ctl) = "TextBox" Then
If ctl.Tag = "Medical Benefit Plan" Then
If ctl.Text < "" And ctl.Visible = True Then
Cells(NextPlanRow, 3) = ctl.Text
NextPlanRow = NextPlanRow + 1
End If
End If
. . . . other loops . . . . .
Next ctl
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8,520
Default Read Order When Using Tags on UserForm; Typename

You are right. It list the text boxes in the order in which the control was
placed in the userform.
--
If this post helps click Yes
---------------
Jacob Skaria


"gims289" wrote:

Does anyone know the order in which VBA reads through tags when looping
through all tags of same name? It doesn't seem to follow a logical route
when reading the tags. All the textboxes are on the same userform tab. The
textboxes are in a 4x3 grid with the center column having the text boxes I'm
after here. I have tab stops assigned to the textboxes as well, but it
doesn't follow that order - which I would thought it would. Thanks for your
time.

For Each ctl In RREForm.Controls
If TypeName(ctl) = "TextBox" Then
If ctl.Tag = "Medical Benefit Plan" Then
If ctl.Text < "" And ctl.Visible = True Then
Cells(NextPlanRow, 3) = ctl.Text
NextPlanRow = NextPlanRow + 1
End If
End If
. . . . other loops . . . . .
Next ctl

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
TypeName function ArthurJ Excel Programming 8 October 12th 08 04:57 PM
TypeName of a UDT Pflugs Excel Programming 9 August 25th 07 09:29 PM
How can read object order by useing writing? ¬f©÷ Excel Programming 3 December 9th 04 04:29 AM
How can read object order by useing writing? ¬f©÷ New Users to Excel 0 December 7th 04 05:02 PM
Rephrasing argument for typename and a different result Hari[_3_] Excel Programming 6 June 15th 04 05:14 PM


All times are GMT +1. The time now is 11:26 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"