ekiza23
13 years agoContributor
Naming the methods in the Script Extensions
Hi all,
I have been working with Script Extensions lately, and I have found a curious thing.
Note: I am using the same name for the "Name" and "Routine" fields in the Description.xml
It would seem that if a method that I am adding to a script extension starts with the word "execute" or "run", it will not be available in the autocomplete functionality of the runtime object. If I change the name (both in the script file and the Description.xml), it will work.
examples:
DOES NOT work:
<Method Name="executeMysqlCommand" Routine="executeMysqlCommand">
</Method>
DOES work:
<Method Name="mysqlCommand" Routine="mysqlCommand">
</Method>
DOES NOT work:
<Method Name="runSQLFileInstructions" Routine="runSQLFileInstructions">
</Method>
DOES work:
<Method Name="sqlFileInstructions" Routine="sqlFileInstructions">
</Method>
Are there any specific rules on naming Subs and Functions for Script Extensions?
I have been working with Script Extensions lately, and I have found a curious thing.
Note: I am using the same name for the "Name" and "Routine" fields in the Description.xml
It would seem that if a method that I am adding to a script extension starts with the word "execute" or "run", it will not be available in the autocomplete functionality of the runtime object. If I change the name (both in the script file and the Description.xml), it will work.
examples:
DOES NOT work:
<Method Name="executeMysqlCommand" Routine="executeMysqlCommand">
</Method>
DOES work:
<Method Name="mysqlCommand" Routine="mysqlCommand">
</Method>
DOES NOT work:
<Method Name="runSQLFileInstructions" Routine="runSQLFileInstructions">
</Method>
DOES work:
<Method Name="sqlFileInstructions" Routine="sqlFileInstructions">
</Method>
Are there any specific rules on naming Subs and Functions for Script Extensions?