Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 7
Default VBA and Validation Lists

Is there any way to automatically (without double clicking or clicking
the down arrow) display a list to choose from if a cell is used for
validation. I have numerous cells that are "validation".

Example:

Cell C2 (on sheet1) is linked to a list (defined as "Styles") on
sheet2 using the Data - Validation from the excel menus. A user
either has to click on this cell then click the down arrow or double
click the cell in order for the choices to display.

I need to have it auto display (using VBA is fine) because the
spreadsheet will be used on a mouseless computer. So if the user tabs
over and the cell is selected, the choices will drop down, the user
can use the up and down keys to highlight what they want, hit enter,
then hit tab again to move on.

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,253
Default VBA and Validation Lists

I'm not sure I'd use this..but it seems to work.
Code should go into the sheet's code module.


Private Sub Worksheet_SelectionChange(ByVal Target As Range)
Dim lValType As Long
If Target.Cells.Count 1 Then Exit Sub
On Error Resume Next
lValType = Target.Validation.Type
On Error GoTo 0
If lValType = xlValidateList Then SendKeys "%{down}"
End Sub


Ammend, refine & improve where needed.



keepITcool

< email : keepitcool chello nl (with @ and .)
< homepage: http://members.chello.nl/keepitcool


(Network Admin) wrote :

Is there any way to automatically (without double clicking or clicking
the down arrow) display a list to choose from if a cell is used for
validation. I have numerous cells that are "validation".

Example:

Cell C2 (on sheet1) is linked to a list (defined as "Styles") on
sheet2 using the Data - Validation from the excel menus. A user
either has to click on this cell then click the down arrow or double
click the cell in order for the choices to display.

I need to have it auto display (using VBA is fine) because the
spreadsheet will be used on a mouseless computer. So if the user tabs
over and the cell is selected, the choices will drop down, the user
can use the up and down keys to highlight what they want, hit enter,
then hit tab again to move on.

Thanks


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default VBA and Validation Lists

Try holding the Alt key down and then use either the up or down arrow while
in the cell with data validation.

Neil

"Network Admin" wrote in message
om...
Is there any way to automatically (without double clicking or clicking
the down arrow) display a list to choose from if a cell is used for
validation. I have numerous cells that are "validation".

Example:

Cell C2 (on sheet1) is linked to a list (defined as "Styles") on
sheet2 using the Data - Validation from the excel menus. A user
either has to click on this cell then click the down arrow or double
click the cell in order for the choices to display.

I need to have it auto display (using VBA is fine) because the
spreadsheet will be used on a mouseless computer. So if the user tabs
over and the cell is selected, the choices will drop down, the user
can use the up and down keys to highlight what they want, hit enter,
then hit tab again to move on.

Thanks



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
Validation lists... NWO Excel Discussion (Misc queries) 4 March 26th 09 02:53 AM
How to clear validation lists based on other validation lists Ben Excel Discussion (Misc queries) 1 March 12th 07 07:11 PM
Data validation with validation lists and combo boxs Keith Excel Discussion (Misc queries) 1 October 12th 06 11:08 AM
Using Lists/Validation Bruce Excel Discussion (Misc queries) 1 March 30th 06 05:28 AM
Validation lists Molly[_2_] Excel Programming 2 April 13th 04 04:05 PM


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