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: 155
Default Numeric data only in text box on userform

hi there,

I use the following code to make sure that all required fields are complete
prior to commiting data to my master log.

Question: I want to use this code to check that all numeric fields contain
only numeric data (postive, negative, whole and decimals). I have modified
the numeric field names to 'txtNear_Miss_num" to flag all numeric text boses.

Can anyone help with the code on this?


For Each ctrl In frmRaglanDailyInput.Controls
If TypeOf ctrl Is msforms.TextBox Then
If ctrl.Value = "" And ctrl.Name Like "*1*" Then
MsgBox "Missing Data in " & ctrl.Name
Exit Sub
End If
End If
Next

--
Carlee
 
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
converting text to numeric data babooz Excel Worksheet Functions 3 May 19th 06 08:14 AM
Sorting Data, Text and Numeric Shorty[_3_] Excel Programming 5 March 1st 06 09:17 PM
Numeric in Text to convert back to the form of Numeric for VLookup Purposes achilles Excel Discussion (Misc queries) 4 February 6th 06 07:05 AM
Text Box for Numeric Data Chrissy[_5_] Excel Programming 12 October 30th 03 10:53 AM
Use numeric data from a textbox on an userform Excel[_3_] Excel Programming 0 July 23rd 03 04:45 PM


All times are GMT +1. The time now is 12:28 AM.

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"