Assigning a macro at runtime for double click event of a shape

K

Kota

Hi,

I want to assign a macro at runtime in VBA for double click event of a shape.

Please verify this syntex. I got from Visio 2003, but it is not working in
Visio 2002.

Application.ActiveWindow.Page.Shapes.ItemFromID(ShapeCount).CellsSRC(visSectionObject,
visRowEvent, visEvtCellDblClick).FormulaU =
"RUNMACRO(""Interactive_Agent.Module1.Macro2"")"

what may be the wrong in this syntex

I am working on Visio 2002.

Thanks,
Kota.
 
J

JuneTheSecond

I cannot run Visio2002 now, would you tell us the error message and the place
where error occurs, VBA or shapesheet?
 
J

JuneTheSecond

I am not sure, but if "Interactive_Agent" means project,
"RUNMACRO(""Interactive_Agent.Module1.Macro2"")"
should be replaced by
"RUNMACRO(""Module1.Macro2"",""Interactive_Agent"")" .
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top