Home > database >  The membership card only allow a credit card, how does not allow entry with PB
The membership card only allow a credit card, how does not allow entry with PB

Time:09-20

The membership card only allow a credit card, how does not allow entry with PB

CodePudding user response:

Many methods,
Such as CPU keydown event has occurred in the judgment, recorded in the instance variables when the text is empty of CPU, then judged not empty into the CPU time, such as more than 500, is the text=", 500, of course, also can use the variable flexible point

CodePudding user response:

What system? ~ ~

CodePudding user response:

reference 1st floor ys1207 response:
method are many,
Such as CPU keydown event has occurred in the judgment, recorded in the instance variables when the text is empty of CPU, then judged not empty into the CPU time, such as more than 500, is the text=", 500, of course, also can use the variable flexible point


If it is copy and paste?

CodePudding user response:

In editchanged judgment, if the input is less than the length of the membership card of the digits (e.g., 12), directly to empty,

CodePudding user response:

Copy judgment are not allowed to accept time is OK to input speed forever than a credit card

CodePudding user response:

reference xgyun reply: 3/f
reference 1st floor ys1207 response: many methods,
Such as CPU keydown event has occurred in the judgment, recorded in the instance variables when the text is empty of CPU, then judged not empty into the CPU time, such as more than 500, is the text=', 500, of course, also can use the variable flexible point

If it is copy and paste?


Simple, getfocus events with the Clipboard (' ') not to go

CodePudding user response:

Card number field is read-only, are not allowed to enter, next to a "credit card" button, click and enter the credit card read card interface, will read the card displayed on the card number column, line

CodePudding user response:

refer to 6th floor ys1207 response:
reference 3 floor xgyun reply:
Refer to 1st floor ys1207 response: many methods,
Such as CPU keydown event has occurred in the judgment, recorded in the instance variables when the text is empty of CPU, then judged not empty into the CPU time, such as more than 500, is the text=', 500, of course, also can use the variable flexible point

If it is copy and paste?

Simple, getfocus events with the Clipboard (' ') don't have to do is

CodePudding user response:

Learning, ha ha

CodePudding user response:

refer to 7th floor ribut9225 response:
card number column are read-only, are not allowed to enter, next to a "credit card" button, click and enter the card read card interface, will read the card displayed on the card number column, line ah
credit card interface is allowed to enter or to read the card number? If allowed to enter the first read only and no action

CodePudding user response:

references to the tenth floor fengxiaohan211 response:
refer to 7th floor ribut9225 response:
Card number field is read-only, are not allowed to enter, next to a "credit card" button, click and enter the card read card interface, will read the card displayed on the card number column, line ah card interface is allowed to enter or to read the card number? If allowed to enter the first read only and no action


Brothers, is read-only, read-only, of course, can't enter

CodePudding user response:

The text box set to read only with respect to OK

CodePudding user response:

What is "card" card? If is IC card or ID card, and use specialized equipment to read, put the card number of the edit box set to read only is ok, because the card is in code and then write in the box, from a device if it is or magnetic stripe CARDS, barcode CARDS, then set the edit box as read-only are not enough, because itself is to copy the two card use the keyboard to input, so there are two kinds of processing methods:
First, you can reference 7 floor, to bring up a charge window, the window, there is a card name edit box, this box is invisible in the interface, the interface elements, or simply in the interface, when it losefocus, mandatory setfocus again, to ensure that the input focus is always in the edit box, so the credit card, the card will brush in this box, and if use the keyboard to input manually, because the box is blocked, users don't see what you lose is, won't be the effect of the input is similar to,
Second, don't want to pop-up window (the user experience is not very good, operation is more troublesome), because the elements of the original window may be too much, can not use forced setfocus to deal with input focus on accidental or intentional be transferred to other elements, so only in the card number edit box itself fluctuation kongfu, there are two places need to be addressed:
1, in the edit box the KEYDOWN event has occurred in the test of time between the two buttons, if more than a long time interval (such as more than 100 ms) put the contents of the edit box empty (i.e., 1/f, method), because with the keyboard input, must use credit card as fast as input,
2, in the KEYDOWN event has occurred, if the user pressed the card number of allowed characters and a carriage return character (for example, to use the paste shortcut, affirmation is to press Control + V, and Control key certainly should not be allowed in the card number characters, V may), as soon as an error, and the contents of the edit box blank, on the other hand, will bring right-click menu to edit box, namely the RButtonDown event processing,
  • Related