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: 14
Default Data Validation is it proper to use it in this situation

Hello

Im a beginner to VBA in excel and this is probably the wrong way to go
about it...

But I want to have a list of companies in a column. When the user
selects a company that will create a column with the "attention name"
with respect to the company. Then have both company and attetnion
appear in another column. I have done this with excels data
validation for the companies name but am having problems with the
attention part. Ive been trying with the apollo part only using
select case

Any suggestions is appreciated
Lisa

Select Case Cells(5, "c")
Case "Apollo"
Cells(2, "A") = "APOLLO "

'Cells(9, "h") = "Attention smith"
'Cells(10, "h") = "Attention john"

With Selection.Validation
.Add Type:=xlValidateList, AlertStyle:=xlValidAlertStop,
Operator:= _
xlBetween, Formula1:="=$H$9:$H$10"
.IgnoreBlank = True
.InCellDropdown = True
.InputTitle = ""
.ErrorTitle = ""
.InputMessage = ""
.ErrorMessage = ""
.ShowInput = True
.ShowError = True
End With

Cells(3, "a") = Cells(5, "e")

Case "brooks"
Cells(2, "a") = "Brooks ltd"

Case "peterson"
Cells(2, "a") = "peterson ltd"


Case Else
Cells(2, "B") = ""


End Select


 
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
custom data validation on cells with data validation values AKrobbins Excel Worksheet Functions 2 June 21st 11 04:20 PM
Difficulty Aligning Series Data With Proper Dates Mike M. Charts and Charting in Excel 3 September 30th 09 03:49 AM
"Tricky Situation" - Validation Formula Teddy-B Excel Discussion (Misc queries) 4 November 24th 07 07:43 PM
Convert data into proper time format [email protected] Excel Worksheet Functions 1 April 25th 06 07:39 PM
validation rule - force text entries to appear as Proper jennifer Excel Worksheet Functions 1 March 27th 06 03:19 AM


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