THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 24/05/2011 at 17:02, xxxxxxxx wrote:
Am I right that you can't use a button in the Execute Method of a tag plugin to do things like print. Or open a dialog message box?
I get illegal crossover errors when trying to do that.
In C++ I use the Message method to make button calls like this:
Bool MyTag::Message(GeListNode *node, LONG type, void *data)
{
switch (type)
{
case MSG_DESCRIPTION_COMMAND: // MSG_DESCRIPTION_COMMAND is send when button is clicked
{
DescriptionCommand *dc = (DescriptionCommand* )data; // data contains the description ID of the button
LONG button = dc->id[0].id; // get the ID of the button
switch (button) // check for different button IDs
{
case BUTTON1:
GePrint("Button1 was pushed");
break;
case BUTTON2:
GePrint("Button2 was pushed");
break;
}
}
}
return TRUE;
}
Am I supposed to do it that way in python too?
I don't think I saw any tags with buttons examples like this in the SDK.
Are there any examples of doing this with python?
-ScottA