Yeah, you can check that "Don't show again" -- its basically just saying "I can't debug the target you picked!", which is kind of of obvious. It shouldn't give you an error so much as a warning when you step into Illustrator code, but that's probably what you mean.
As for the Hello World thing -- are you just popping up your own dialog, or was that an ADM dialog? If the former, its probably always there and just behind the application because the parent is incorrect -- getting the proper parent for Illustrator is a wonderful journey, full of strong curse words and new & colourful phrases!
Looks like it's using ADM. Here's the code from the getting started guide:
extern "C" ASAPI ASErr PluginMain(char* caller, char* selector, void* message)
ASErr error = kNoErr;
SPBasicSuite* sSPBasic = ((SPMessageData*)message)->basic;
ADMBasicSuite11 *sADMBasic = nil;
error = sSPBasic->AcquireSuite(kADMBasicSuite,
error = sSPBasic->ReleaseSuite(kADMBasicSuite,kADMBasicSuiteVersion11);
Stepping through the code, I can see that the MessageAlert method is reached and called, but nothing seems to happen in AI.
Odd then. That should pop up 'Hello World' when its starts up & 'Goodbye World!' when it shuts down, as I'm sure is obvious. Well, popping dialogs at those points isn't somethind I'd do personally -- if I wanted to show the user a dialog I'd wait until I got the 'application started' notifier, which is a lot farther along in the load time. So I wouldn't worry about that too much.
1 person found this helpful
Make sure your suites are getting registered correctly. What's sADMBasic set to when you hit that point?
Edit: Is that the code from the sample project? Or have you modified where that dialog is popped?
Message was edited by: btemp
sADMBasic is set to ADMBasicSuite11* at that point.
My goal with this plugin is just to start learning how the SDK is structured, so this little issue isn't really that important. If I was ever to need a dialog on startup, I would likely go with the notification as A. Patterson suggested. I was just surprised that it did not pop up an alert because the code is all out of the Getting Started document and I thought that maybe I had something configured incorrectly in Visual Studio. Maybe the docs are just not as reliable as I assumed. Eg. I can't seem to locate any information at all on kSPInterfaceCaller in the HTML reference. It talks about it in the getting started doc, but that's it.
Thanks for the help guys.
The Selectors & Callers are just glorified "action" notifiers. They could have made it one big enum list, but they broke it into classes so the code would look be more readable (which is good!). kSPInterfaceCaller just contains sub-actions like startup, shutdown & 'about'. The other callers (menu, annotation, tools, notify, etc.) are more interesting from a 'doing stuff' point of view
I was asking more about whether sADMBasic is pointing to valid data at that point. Its possible the suites haven't been loaded at that time, or that there is some issue with how they are being loaded. Did you check the value of 'error' there?