SmartTag actions appear two times?

Add-in Express™ Support Service
That's what is more important than anything else

SmartTag actions appear two times?
 
Anton


Guest


The Actions for my SmartTag appear two times in the list when I click on the SmartTag in Word and I cannot find a way to prevent this.

What am I doing wrong?
Posted 12 Jan, 2006 22:17:04 Top
Anton


Guest


And one more question. Can I change the Caption of the SmartTag Actions after they have been created, for example in the ActionNeeded event?

Removing all the actions and creating new ones with new captions would be ok too, I just want to be able to control the captions each time the SmartTag menu appears.
Posted 12 Jan, 2006 22:37:13 Top
Anton


Guest


The third copy of the SmartTag action just appeared in the menu, this is so strange ...
Posted 12 Jan, 2006 22:41:53 Top
Anton


Guest


Calling the following method I could get back to two copies of the action.

... Actions.Clear();
Posted 12 Jan, 2006 22:51:33 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Anton.

The Actions for my SmartTag appear two times in the list when I click on the SmartTag in Word and I cannot find a way to prevent this.
What am I doing wrong?

You shouldn't manupulate the UseShim property of the SmarttagModule if you have registered the smart tag with the C++ shim. Now your smart tag is registered twice (with shim and without one). In this case you can do the following:
1. Set the UseShim property to true and register the smart tag project
via the 'Register ADX Project' option.
2. Unregister the smart tag project via the 'Unregister ADX Project'
option.
It should help you to unregister the smart tag completely.

And one more question. Can I change the Caption of the SmartTag Actions after they have been created, for example in the ActionNeeded event?

No. The ActionNeeded event is called once when a smart tag has been recognized.

If you are still having problems you can send me the project. I will check it.
Posted 14 Jan, 2006 04:25:41 Top
Anton Karl




Posts: 2
Joined: 2006-01-17
Thank you. I understand that the ActionNeeded is only fired once, but can I create a new tag with new captions dynamically whenever a smarttag is needed, for example in the Recognize event? More genarally, Is there any way at all to have a different list of options everytime a smarttag is needed, based on the smarttagged word.

And another question. If I open a custom Form from my add-in, how do I return focus to Word in code. I want my Form to remain open.
Posted 17 Jan, 2006 16:15:17 Top
Anton Karl




Posts: 2
Joined: 2006-01-17
And one more :)

Can I get access to an event that happens just when the smarttag is activated by moving the mouse over the smarttagged word.

Something like: onMouseOverSmartTag ...

That would be really great!

And get information about what word the mouse is over (if many words have the smarttag underline)
Posted 17 Jan, 2006 16:27:36 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Anton.

I understand that the ActionNeeded is only fired once, but can I create a new tag with new captions dynamically whenever a smarttag is needed, for example in the Recognize event? More genarally, Is there any way at all to have a different list of options everytime a smarttag is needed, based on the smarttagged word.

You can download an example using the following link:
http://www.add-in-express.com/projects/dynamicsmarttags.zip

If I open a custom Form from my add-in, how do I return focus to Word in code.

As far as I know there is no way to do it.

Can I get access to an event that happens just when the smarttag is activated by moving the mouse over the smarttagged word.

No.
Posted 18 Jan, 2006 11:43:21 Top
Sergey Grischenko


Add-in Express team


Posts: 7233
Joined: 2004-07-05
Hi Anton.

It seems that I found a solution how you can return focus to Word.
You can download an example here:
http://www.add-in-express.com/projects/dynamicsmarttags2.zip
Posted 25 Jan, 2006 08:34:41 Top