Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Programming Student in trouble... Please help!
Index -> Programming, Visual Basic and Other Basics -> Visual Basic Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
nightcrawler




PostPosted: Thu Apr 05, 2007 7:47 am   Post subject: Programming Student in trouble... Please help!

I am trying to get a text box to only accept a certain number of numbers...

Question I need to restrict the user so that they have to enter in 9 digits before they are allowed to move on... No more, no less...

Question Can anybody please help me??
Sponsor
Sponsor
Sponsor
sponsor
rdrake




PostPosted: Thu Apr 05, 2007 10:29 am   Post subject: RE:Programming Student in trouble... Please help!

Do text boxes not have a Length property? Find a property like that and check it against a certain value, like 9 in your example.
cool dude




PostPosted: Thu Apr 05, 2007 1:05 pm   Post subject: Re: Programming Student in trouble... Please help!

yes rdrake there is built in length function called len()

i made an example program to do exactly what you asked. please don't mind the variable usage.



example.vbp
 Description:

Download
 Filename:  example.vbp
 Filesize:  603 Bytes
 Downloaded:  153 Time(s)

cool dude




PostPosted: Thu Apr 05, 2007 1:12 pm   Post subject: Re: Programming Student in trouble... Please help!

sorry wrong attachment


example.frm
 Description:

Download
 Filename:  example.frm
 Filesize:  1.1 KB
 Downloaded:  153 Time(s)

Aziz




PostPosted: Tue Apr 10, 2007 5:18 pm   Post subject: RE:Programming Student in trouble... Please help!

There is a property called MaxLength I believe
Display posts from previous:   
   Index -> Programming, Visual Basic and Other Basics -> Visual Basic Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 5 Posts ]
Jump to:   


Style:  
Search: