Clear Content of a cell

cata2200

Board Regular
Joined
Jul 29, 2006
Messages
60
Hi

I create to lists to be used together with Validation facility. First one is Static (9 entries). Second one is dynamic, based on the selection result from first one.
Let's say Cell $A$1 has this Validation from a Static list, "Alist". Cell $a$2 has validation from dynamic list "Blist". When I choose a value in cell $a$1, I'd like the cell $a$2 to have null value.

Can I do this? Help

Regards, Catalin
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.

Lewiy

Well-known Member
Joined
Jan 5, 2007
Messages
4,284
Something like this?:
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Target.Address = "$A$1" Then
    Range("A2") = ""
End If
End Sub
 

Peter_SSs

MrExcel MVP, Moderator
Joined
May 28, 2005
Messages
58,393
Office Version
  1. 365
Platform
  1. Windows
This is not too clear to me, but based on ..
When I choose a value in cell $a$1, I'd like the cell $a$2 to have null value.
... then see if this does what you want.

<font face=Courier New><SPAN style="color:#00007F">Private</SPAN> <SPAN style="color:#00007F">Sub</SPAN> Worksheet_Change(<SPAN style="color:#00007F">ByVal</SPAN> Target <SPAN style="color:#00007F">As</SPAN> Range)
    <SPAN style="color:#00007F">If</SPAN> Target.Address = "$A$1" <SPAN style="color:#00007F">Then</SPAN> Range("A2").ClearContents
<SPAN style="color:#00007F">End</SPAN> <SPAN style="color:#00007F">Sub</SPAN></FONT>
 

Forum statistics

Threads
1,186,160
Messages
5,956,272
Members
438,245
Latest member
bhavdip_mangukiya

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top