Hi,
Into a range(A1:E1) I've a validate control from list (2,4,6,8). it's possible tu disable the imput from keyboard??
The users can insert value into a cell only with select-list.
thank
Fabrizio
Hi,
Into a range(A1:E1) I've a validate control from list (2,4,6,8). it's possible tu disable the imput from keyboard??
The users can insert value into a cell only with select-list.
thank
Fabrizio
Ciao Fabrizio,
How are you validating the input of 2, 4, 6, 8? You can do this in VBA or you could add data validation and in the source, only allow 2, 4, 6, 8. This way the user selects the drop down and these are the only choices.
HTH
Regards, Jeff
Ciao Jeff, (ciao is better that Hi..)
the second, with Selection.Validation.
The control play also if the user write from keyboard, but unother control(Worksheet_Change) don't run.
I want to force the users tu use the mouse (select list).
I think this is one solution to my last post "use Intersect()"
fabrizio
Si Fabirizio, Ciao e molto bene,
Is this question the same as your other post Problem with Intersect(Target)?
First thought, I don't think it is a good idea to take the keyboard away from the user nor do I believe, in my limited VBA experience, can you limit non-keyboard usage to just a few cells. I'm may be off, but just don't know how.
Second, my suggestion would be to use the data validation. Highlight A1:E1 >> apply data validation >> Allow: List >> Source: 2, 4, 6, 8 >> You can set an error if the user trys to manually input anything else.
http://www.contextures.com/xlDataVal01.html
Yes/No,
I try tu use my control (old post) and it play with enter imput or with select (from data validation), but not go if I imput the value and play arrow down.
For this i thought to block keyboard...
I use data validation every day, I know that.
Fabrizio
OK - try this event code in cell A1.
here is the attached with that code.Please Login or Register to view this content.
There is not a VBA way to "block keyboard". Look in the Object Browser for the word Key and see...
One test is worth a thousand opinions.
Click the * Add Reputation below to say thanks.
Ciao Marvin,
the problem is my control.
Thi is my file:
Try to select for each Seven dwarfs, the same day of holiday.
If you use the select list (associate at Selection.Validation) 1th ok, 2th ok, and 3th will be non able!!
try more with keyboard, 1-2-3-4- all are ready to go to holiday...
Cartel1.xlsm
Sorry,
I don't understand the problem. We need some translation help here.
@Marvin,
If somehow I could get ahold of my friend in Padova, IT I would, but alas, not happening.
@Fabrizio,
With your attached spreadsheet, in D6 and E 6 I enter a 4, but then in F6 when entering a 4 you get the waring about holidays. Can you give a little clearer detail here on what you do want to happen and what you do not want to happen.
Jeff,
the two value is the hour of holiday (4 for half day, 8 for all worked day)
if D6, and E6 value are already compiled, nobody can go in holiday in the same day.
You've also tryed tu use the keyboard??
Could this problem really be: Only allow a total of 8 hours per row? If a value is entered that makes the row total greater than 8 it is blanked out?
basic code to block the keyboard
you could implement this with a selectionchange event but make sure that you use a beforeclose event to reinstate the keyboard! also be aware that it blocks the keyboard for all applications and not just excel (you can change that by specifying a threadid in the last argument of the setwindowshookex call).Please Login or Register to view this content.
I'm not sure I would recommend this in an excel application but that's your call. ;-)
Josie
if at first you don't succeed try doing it the way your wife told you to
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks