Results 1 to 4 of 4
  1. #1

    generator_add_function issue

    Hi, I am fairly new to WR, I m using 9.2 and have worked through the tutorial and read the user guide. I am trying to create a function using the built in generator to get WR to send an email with an attachment however after creating the function and attempting to use it I get and error message saying "unreognised function". If i restart WR then the newly created function is removed from the insert function menu. Am i missing something

    Cheers Dougie

  2. #2

    Re: generator_add_function issue

    generator_add_function does not create a function, it does add a function (that you must write within your script) to the Function Generator.

    If you have not created the function itself (and just called generator_add_function), this explains the error "unrecognised function".

    Creating a function is something like:
    <font class="small">Code:</font><hr /><pre>
    public function myFunction (myParam1, myParam2) {
    # enter your code here
    </pre><hr />

    Second question:
    Why was the function removed from the Function Generator after restarting WR?
    That's because generator_add_function does not add the function to the Function Generator permanently, it does only add it within your current WR session. So you have to call it again after (re)starting WR.
    There are 2 ways to do that automatically:
    a) You can define a startup script that shall be executed after starting WR (it's a configuration entry somewhere in the Tools-menu).
    b) The script "tslinit" will be executed at every start of WR. You cann add your piece of code into this script.


  3. #3

    Re: generator_add_function issue

    Thanks very much for the help, that explains a great deal. I did not see that adding to the function generator is only valid for that session in the user guide.


  4. #4

    Re: generator_add_function issue

    The only hint that it will not be valid permanently could be that there exists no generator_remove_function ... [img]/images/graemlins/wink.gif[/img]



Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
BetaSoft Inc.
All times are GMT -8. The time now is 05:54 PM.

Copyright BetaSoft Inc.