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: 4
Default Issue with form field lengths

I am doing an order information form in VBA and have an area for credit
card numbers. We take all major credit cards, and so I have the card
number broken up into 4 fields. The idea is that you do not need to
press the tab button to go on to the next field, it will setfocus in a
macro...but is there a way to test for a length of a certain number of
digits in a field? (So if their are 4 numbers in textbox1, then
setfocus textbox2) Right now I am using if then statements to
determine if the number typed in is over 999, but this is flawed for
discover cards, because the 2nd set of digits is usually 0000 for the
number. Any ideas? Please post code example. Thanks

 
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
Pivot Table Page Field Issue (Not sorting) Barb Reinhardt Excel Discussion (Misc queries) 2 May 1st 09 05:23 PM
Active X Controls Tabbing from Form Field 2 Form Field Tfrup12 Excel Discussion (Misc queries) 0 February 19th 08 08:15 PM
Economical grouping of lengths out of much longer lengths Richard (a Builder not a Mathematician) Excel Worksheet Functions 1 January 19th 08 10:28 PM
How do I set up excel to tab from field to field in a form? bigmac6365 Excel Discussion (Misc queries) 2 September 30th 05 08:32 PM
Text Box on User Form Set Focus Issue John Flynn Excel Programming 0 September 6th 03 02:41 PM


All times are GMT +1. The time now is 06:17 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"