ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Multipage: [Me.Controls("Page" & i).Name] does not work (https://www.excelbanter.com/excel-programming/356997-multipage-%5Bme-controls-page-i-name%5D-does-not-work.html)

Zurn[_34_]

Multipage: [Me.Controls("Page" & i).Name] does not work
 

A usefull code is working with .Controls
eg I have several txtboxes named txtHallo1 txtHallo2 ...

for iCH = 1 to ...
Me.Controls("txtHallo" & iCH).text
next iCH

My problem;
How can you do this for multipage pages?

Me.Multisheet.Page1
Me.Multisheet.Page2
Me.Multisheet.Page3
Me.Multisheet.Page4
Me.Multisheet.Page5

Is there a special shortcut? because me.controls("Page" & iCH) does not
work.

Zurn


--
Zurn
------------------------------------------------------------------------
Zurn's Profile: http://www.excelforum.com/member.php...o&userid=14645
View this thread: http://www.excelforum.com/showthread...hreadid=525996


Papou

Multipage: [Me.Controls("Page" & i).Name] does not work
 
Hello
For i = 0 To Me.MultiPage1.Pages.Count - 1
MsgBox Me.MultiPage1.Pages(i).Caption
Next i

HTH
Cordially
Pascal



Zurn[_35_]

Multipage: [Me.Controls("Page" & i).Name] does not work
 

Off course! I was blinded by the Controls that I did not think about
this.

Thanks Papou!


--
Zurn
------------------------------------------------------------------------
Zurn's Profile: http://www.excelforum.com/member.php...o&userid=14645
View this thread: http://www.excelforum.com/showthread...hreadid=525996



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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com