ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Data Validation - Dependent List (https://www.excelbanter.com/excel-programming/413303-data-validation-dependent-list.html)

Prasad Gopinath

Data Validation - Dependent List
 
I have a spreadsheet where I need to set up Data Validation for a Dependent
list.

Sheet 1 - Validation List
Column A - Service
Column B - Price

Cell A1 value - Super NYC Show
Cell B1 value - $ 75

Is there any way I can set up Data Validation in Sheet 2 where if I selected
Selected Super NYC Show in Sheet 2, it will automatically pull up the
corresponding $ 75 value in the adjacent cell of the said spread sheet?

Prasad


Doug Glancy

Data Validation - Dependent List
 
Prasad,

Take a look at this site:

http://www.contextures.com/xlDataVal02.html

hth,

Doug

"Prasad Gopinath" wrote in
message ...
I have a spreadsheet where I need to set up Data Validation for a
Dependent
list.

Sheet 1 - Validation List
Column A - Service
Column B - Price

Cell A1 value - Super NYC Show
Cell B1 value - $ 75

Is there any way I can set up Data Validation in Sheet 2 where if I
selected
Selected Super NYC Show in Sheet 2, it will automatically pull up the
corresponding $ 75 value in the adjacent cell of the said spread sheet?

Prasad




Debra Dalgleish

Data Validation - Dependent List
 
You can use a VLookup formula to show the price for the selected
service. There's an example in an Order Form, shown he

http://www.contextures.com/xlOrderForm01.html

Prasad Gopinath wrote:
I have a spreadsheet where I need to set up Data Validation for a Dependent
list.

Sheet 1 - Validation List
Column A - Service
Column B - Price

Cell A1 value - Super NYC Show
Cell B1 value - $ 75

Is there any way I can set up Data Validation in Sheet 2 where if I selected
Selected Super NYC Show in Sheet 2, it will automatically pull up the
corresponding $ 75 value in the adjacent cell of the said spread sheet?

Prasad



--
Debra Dalgleish
Contextures
www.contextures.com/tiptech.html
Blog: http://blog.contextures.com


RyanH

Data Validation - Dependent List
 
I would use the double click event in the Worksheet 2 Module. The code below
assumes the cells you will be clicking on is in Col.A. All you have to do is
double click the cell and the code will execute to what you want.

Option Explicit

Private Sub Worksheet_BeforeDoubleClick(ByVal Target As Range, Cancel As
Boolean)

Dim Service As Range

If Target.Column = 1 Then

'prevents default action
Cancel = True

'sets range and enters value from sheet1
Set Service = Sheets("Sheet1").Range("A:A").Find(What:=Target,
LookIn:=xlValues)
Target.Offset(0, 1).Value = Service.Offset(0, 1).Value

End If

End Sub

Hope this helps! If so click "Yes" below.
--
Cheers,
Ryan


"Prasad Gopinath" wrote:

I have a spreadsheet where I need to set up Data Validation for a Dependent
list.

Sheet 1 - Validation List
Column A - Service
Column B - Price

Cell A1 value - Super NYC Show
Cell B1 value - $ 75

Is there any way I can set up Data Validation in Sheet 2 where if I selected
Selected Super NYC Show in Sheet 2, it will automatically pull up the
corresponding $ 75 value in the adjacent cell of the said spread sheet?

Prasad



All times are GMT +1. The time now is 05:00 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com