LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 10
Default Counting textboxes

Hello! I got this piece of code from someone who helped me with a function
that counts the number of textboxes in a user form. However I do not not what
what 'oUF' means and how to use the function. I have never used functions
before so I do not know how to call it. I tried useing 'Call countTextboxes'
in another Sub but I suppose that you need something else...

Public Function countTextboxes(oUF As UserForm) As Long
Dim iCtrl As Long
For iCtrl = 0 To oUF.Controls.Count - 1
If TypeName(oUF.Controls(iCtrl)) = "TextBox" Then
countTextboxes = countTextboxes + 1
End If
Next iCtrl
End Function
 
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
Textboxes SAL Excel Discussion (Misc queries) 2 July 13th 07 12:24 AM
Textboxes Subs Excel Programming 2 September 28th 05 08:49 PM
tab between several textboxes Kim Excel Worksheet Functions 0 May 9th 05 04:08 PM
sum of textboxes Liedson31 Excel Programming 1 May 3rd 05 06:18 PM
textboxes libby Excel Programming 5 April 13th 04 06:32 PM


All times are GMT +1. The time now is 04:18 PM.

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

About Us

"It's about Microsoft Excel"