Thread: Macro control
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
D.S.[_3_] D.S.[_3_] is offline
external usenet poster
 
Posts: 60
Default Macro control

Not that I know of.

D.S.
"Edwin Merced" wrote in message
...
But what I would like is to write in a cell and make that go to the code

in
VBA. Is it possible?

"D.S." wrote in message
...
I might suggest a couple ways, but not sure exactly what your trying to

do.
Here's one example.

In the VB Editor "Project Explorer", right click on "ThisWorkbook", and
select "View Code". Click the drop down box on the left side, and pick
workbook. Now click the right drop down box and select
"SheetSelectionChange"

add the following code

If ActiveCell.Value = "test" Then
Range("B1").Value = "test"
Else
Range("B1").Value = ""
End If

Now, go to cell "A1" in your worksheet and type the word "test" (without

the
quotes)

Now watch what happens in "B1" when you click the mouse on any cell

except
"A1", then try clicking on "A1".

Is this anything like you're looking for? You can use other workbook

events
to trigger your code. Look up "workbook object" in the VB Editor Help

menu,
then select "Events"

Did this help?

D.S.


"Edwin Merced" wrote in message
...
How do I instruct a macro to respond to a variable outside of the VB

editor?