Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6
Default Inputting data from Userform

I have setup a user form that fills in Cells A through
D. I want to make sure that all the cells have data. Is
there a way to verify that all cells have data and if
they do not it prompts the user to enter the data before
the form can be sent, saved or closed?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 172
Default Inputting data from Userform

One simple way..............

Private Sub CommandButton1_Click()
If Len(textbox1.Value) = 0 or Len(textbox2.Value) = 0 or
Len(TextBox3.Value) = 0 or Len(TextBox4.Value) = 0 Then
MsgBox "Not all values are entered"
Else
'do something else
End If
End Sub

Cheers
Nigel

"Sony" wrote in message
...
I have setup a user form that fills in Cells A through
D. I want to make sure that all the cells have data. Is
there a way to verify that all cells have data and if
they do not it prompts the user to enter the data before
the form can be sent, saved or closed?





----== Posted via Newsfeed.Com - Unlimited-Uncensored-Secure Usenet News==----
http://www.newsfeed.com The #1 Newsgroup Service in the World! 100,000 Newsgroups
---= 19 East/West-Coast Specialized Servers - Total Privacy via Encryption =---
  #3   Report Post  
Posted to microsoft.public.excel.programming
No Name
 
Posts: n/a
Default Inputting data from Userform

That Worked great, thank you Nigel.
-----Original Message-----
One simple way..............

Private Sub CommandButton1_Click()
If Len(textbox1.Value) = 0 or Len(textbox2.Value) = 0

or
Len(TextBox3.Value) = 0 or Len(TextBox4.Value) = 0 Then
MsgBox "Not all values are entered"
Else
'do something else
End If
End Sub

Cheers
Nigel

"Sony" wrote in

message
...
I have setup a user form that fills in Cells A through
D. I want to make sure that all the cells have data.

Is
there a way to verify that all cells have data and if
they do not it prompts the user to enter the data

before
the form can be sent, saved or closed?





----== Posted via Newsfeed.Com - Unlimited-Uncensored-

Secure Usenet News==----
http://www.newsfeed.com The #1 Newsgroup Service in the

World! 100,000 Newsgroups
---= 19 East/West-Coast Specialized Servers - Total

Privacy via Encryption =---
.

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
Data inputting question sha2312 Excel Worksheet Functions 2 January 17th 08 05:48 AM
Inputting data into two worksheets 4762nicho Excel Discussion (Misc queries) 3 April 28th 07 12:54 PM
inputting data Shanor Excel Discussion (Misc queries) 0 June 15th 06 10:50 AM
Update a chart immediately after inputting data into data source MELMEL Charts and Charting in Excel 1 December 1st 05 09:34 PM
Inputting Source Data - help please foredis Charts and Charting in Excel 1 June 22nd 05 02:36 PM


All times are GMT +1. The time now is 06:45 PM.

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"