Discussion:
DeselectAll() Method Problem
(too old to reply)
Axel101
2007-12-18 10:27:01 UTC
Permalink
Hello,

I'm trying to deselect all items before selecting a new one. The code is the
following:

currentApplication.ActiveWindow.DeselectAll();
Shape shape = someShape;
currentApplication.ActiveWindow.Select(shape, (short)VisSelectArgs.visSelect);

After doing this with two shapes on my page both shapes are selected. If I
add a MessageBox showing something before the DeselectAll() Method
DeselectAll() works fine.

Can someone explain what's wrong with the first code?

thanks
Axel
John Goldsmith
2007-12-18 14:12:50 UTC
Permalink
Hello Axel,

Are you saying that you're not having any success in deselecting shapes
unless you've shown the MessageBox first?

Are you working with multiple Application object instances? Are you sure
that your 'current' application is the one you're after?

Best regards

John


John Goldsmith
www.visualSignals.typepad.co.uk
www.visualSignals.co.uk
Post by Axel101
Hello,
I'm trying to deselect all items before selecting a new one. The code is the
currentApplication.ActiveWindow.DeselectAll();
Shape shape = someShape;
currentApplication.ActiveWindow.Select(shape,
(short)VisSelectArgs.visSelect);
After doing this with two shapes on my page both shapes are selected. If I
add a MessageBox showing something before the DeselectAll() Method
DeselectAll() works fine.
Can someone explain what's wrong with the first code?
thanks
Axel
Loading...