ATTENTION: You are viewing a page formatted for mobile devices; to view the full web page, click HERE.

DonationCoder.com Software > FARR Plugins and Aliases

FScript 1.19 Issues

(1/3) > >>

Perry Mowbray:
I've been updating my plugins to the latest version of FScript (as requested in this thread).

First plugin went fine after I figured out what was going on.

So I headed onto #2 and it hasn't gone as smoothly as I'd hoped  :(

Plugin #2 uses vbScript, and worked fine in the previous versions of FScript that I was using. But after upgrading to 1.19 I think that FScript is not calling the onProcessTrigger function.

So I decided to start at the beginning, and I've converted the original javaScript examples to vbScript. I've attached them, if anybody else wants to check.

Note: I've left the signature for onProcessTrigger as was supplied with the original sample, but I've tried the other signature that works with my javaScript plugin without success.

Perry Mowbray:
ecaradec has just got back to me about this onProcessTrigger issue.

He suggested that onProcessTriggerV2 be tried: and it works!

OK: Problem not solved but easily worked around. I have not tested the other languages, so I'm not sure if they affected in the same way; but if you are using something apart from javaScript and onProcessTrigger is not being called - Try onProcessTriggerV2

Thanks ecaradec  :-*

ecaradec:
Hello Perry,

I found the source of your problem, the issue is that the vbscript needs to declare every parameter used. You have to use the full function declaration even if you don't use every parameter. I probably added a parameter in the last version of fscript causing the vbscript call to fail now.  The full signature is :

function onProcessTrigger(path, caption, groupname, pluginid,thispluginid,score,entrytype,voidp)

The issue was very easy as the script engine returned an error code with exactly the correct issue. I really need to add some error messages   :P

mouser:
now we have the real solution to all of the compatibility problems -- it is that all plugins need to upgrade to onProcessTriggerV2.

ecaradec:
no, onProcessTrigger works, the issue is the number of parameters. Fscript pass all parameters to the scripting host. That's not a problem with javascript that is very forgivable about the number of parameters given. VBScript, ruby, etc... expect the exact correct number of parameters.
With recent FARR defining function onProcessTrigger(path, caption, groupname, pluginid,thispluginid,score,entrytype,voidp) will work all the time. Depending of the features of the language we could get full compatibility by defining a function that allow for extra parameters, or overload the function with one of the same name with a different set of parameters.

Navigation

[0] Message Index

[#] Next page

Go to full version