system.util.getProjectName
This function is used in Python Scripting.
Description​
Returns the name of the project that is currently being run. When run from the Gateway scope from a resource that originates from a singular project (reports, SFCs, etc.), will return that resources project.
When called from a scope that does not have an associated project (a Tag Event Script), the function will return the name of the Gateway scripting project. If a Gateway scripting project has not been configured, then returns an empty string.
Client Permission Restrictions​
This scripting function has no Client Permission restrictions.
Syntax​
system.util.getProjectName()
Parameters​
Nothing
Returns​
String - The name of the currently running project.
Scope​
Gateway, Vision Client, Perspective Session
Code Examples​
Example #1
# This code would display the name of the currently running project
system.gui.messageBox("You are running project: %s" % system.util.getProjectName())