Copy link to clipboard
Copied
Dear wise women and men:
My script FMfindReplace opens a palette wPalF via menu or short cut. The scipt is started either via the Script Library or by placing it in the Statup folder.
I do not understand why the palette re-appears in step 4. I have not observed such behaviour in any other of my scripts with palettes...
The Notify function is IMHO streight forward:
case Constants.FA_Note_PostActiveDocChange:
if (object.ObjectValid()) { // change of document
KLD_F.oCurrentDoc = object;
Console ("wPalF.active = " + wPalF.active);
if (wPalF.active) {
KLD_F.bDocActive = true;
KLD_F.bBookActive = false;
wPalF.g07.rbDoc.value = true;
KLD_F.ButtonReset();
}
}
There exist notification constants for which no explanations are in the FDK documentation:
FA_Note_Dialog (84); FA_Note_Alert (85); FA_Note_Palette (86); ... FA_Note_FileOpen (94)
For curiosity I set up notification for FA_Note_Palette - it did not trigger during my actions.
positive
The palette also re-appears if I open another palette defined by scripts in Statup.
Once more the solution is: KISS - Keep It Simple and Stupid.
Reducing the trigger to just one (namely FA_Note_PostActiveDocChange let me change the document without re-appearing the panel after it had been closed.
There is still some fine-tuning reuired for the situation after "item not found any more" ...
Copy link to clipboard
Copied
I have searched for vagabonding globals and other possible causes, but found nothing which explains the behaviour.
So i just write it off under the heading Known Issues ...
Copy link to clipboard
Copied
Once more the solution is: KISS - Keep It Simple and Stupid.
Reducing the trigger to just one (namely FA_Note_PostActiveDocChange let me change the document without re-appearing the panel after it had been closed.
There is still some fine-tuning reuired for the situation after "item not found any more" ...