If Function question

Closed
Captain M - Nov 4, 2009 at 09:19 AM
venkat1926 Posts 1863 Registration date Sunday June 14, 2009 Status Contributor Last seen August 7, 2021 - Nov 5, 2009 at 06:24 AM
Hello,
I am trying to get 3 cells to populate with different data by only choosing data from only one cell. If a1 = xxx then cell a2 will = yyy cell a3 will = zzz, this is set data that has to appear each time this combination is used a1 is xxx all the others will always be the same data, if this make any sense could you help me get these cells to populate. Many thanks
Related:

1 response

venkat1926 Posts 1863 Registration date Sunday June 14, 2009 Status Contributor Last seen August 7, 2021 811
Nov 5, 2009 at 06:24 AM
did not understand. I am rephrasing your question
In column A wherever XXx is entered then in the column B of the same row will be yyy and in column C of same row will be zzz.
if this understanding is correct then follow these instruction
right click the sheet tab and click view code
in the resuting window copy paste this EVENT CODE"

Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Column <> 1 Then Exit Sub
If Target = "xxx" Then
Cells(Target.Row, "b") = "yyy"
Cells(Target.Row, "c") = "zzz"
End If
End Sub


Now inthe sheet in column type some entry other than xxx see what happens
again in some other cell in column A enter xxx then see what happens.

if this is ok confirm
0