Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{hidden}
DO NOT EDIT THE CONTENT OF THIS PAGE DIRECTLY, UNLESS YOU KNOW WHAT YOU'RE DOING.
		THE STRUCTURE OF THE CONTENT IS VITAL IN BEING ABLE TO EXTRACT CHANGES FROM THE PAGE AND MERGE THEM BACK INTO SERVOY SOURCE{hidden}
{sub-section:description|text=}{sub-section}\\ 

{table:id=|class=servoy sReturnTypes}{tr:style=height: 30px;}{th}Return Types{th}{tr}{tr}{td}{span:class=sWordList}[ALIGNMENT]{span}{span:class=sWordList}[ANCHOR]{span}{span:class=sWordList}[BEVELTYPE]{span}{span:class=sWordList}[CURSOR]{span}{span:class=sWordList}[DEFAULTS]{span}{span:class=sWordList}[FONTSTYLE]{span}{span:class=sWordList}[JSBean]{span}{span:class=sWordList}[JSButton]{span}{span:class=sWordList}[JSCalculation]{span}{span:class=sWordList}[JSComponent]{span}{span:class=sWordList}[JSField]{span}{span:class=sWordList}[JSForm]{span}{span:class=sWordList}[JSLabel]{span}{span:class=sWordList}[JSMedia]{span}{span:class=sWordList}[JSMethod]{span}{span:class=sWordList}[JSPart]{span}{span:class=sWordList}[JSPortal]{span}{span:class=sWordList}[JSRelation]{span}{span:class=sWordList}[JSRelationItem]{span}{span:class=sWordList}[JSStyle]{span}{span:class=sWordList}[JSTab]{span}{span:class=sWordList}[JSTabPanel]{span}{span:class=sWordList}[JSValueList]{span}{span:class=sWordList}[JSVariable]{span}{span:class=sWordList}[MEDIAOPTION]{span}{span:class=sWordList}[PAGEORIENTATION]{span}{span:class=sWordList}[PRINTSLIDING]{span}{span:class=sWordList}[SCROLLBAR]{span}{span:class=sWordList}[TITLEJUSTIFICATION]{span}{span:class=sWordList}[TITLEPOSITION]{span}{span:class=sWordList}[UNITS]{span}{td}{tr}{table}\\ 

{table:id=|class=servoy sSummerysSummary}{colgroup}{column:padding=0px|width=80px}{column}{column}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=2}Method SummerySummary{th}{tr}{tbody}{tr}{td}[JSComponent]{td}{td}[#cloneComponent]\(newName, component)
Makes an exact copy of the given component (JSComponent/JSField/JSLabel) and gives it a new name.{td}{tr}{tbody}{tbody}{tr}{td}[JSComponent]{td}{td}[#cloneComponent]\(newName, component, \[newParentForm\])
Makes an exact copy of the given component (JSComponent/JSField/JSLabel), gives it a new name and optionally moves it to a new parent form, specified as a parameter.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]{td}{td}[#cloneForm]\(newName, jsForm)
Makes an exact copy of the given form and gives it the new name.{td}{tr}{tbody}{tbody}{tr}{td}[JSFormString]{td}{td}[#getForm#createBevelBorder]\(name)
Gets the specified form object and returns information about the form (see JSForm node)bevel_type, highlight_outer_color, highlight_inner_color, shadow_outer_color, shadow_inner_color)
Create a bevel border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]\[String]{td}{td}[#getForms#createEmptyBorder]\(top_width, right_width, bottom_width, left_width)
Create an empty border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]\[String]{td}{td}[#getForms#createEtchedBorder]\(datasource)
bevel_type, highlight_color, shadow_color)
Create an etched border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSFormString]\[]{td}{td}[#getForms#createFont]\(\[server\], \[tablename\])
Get an array of forms, that are all based on datasource/servername or tablenamename, style, size)
Create a font string.{td}{tr}{tbody}{tbody}{tr}{td}[JSMethodString]{td}{td}[#getGlobalMethod#createLineBorder]\(namethick, color)
GetsCreate ana existingline global method by the specified nameborder string.{td}{tr}{tbody}{tbody}{tr}{td}[JSMethod]\[String]{td}{td}[#getGlobalMethods#createMatteBorder]\()
The list of all global methodstop_width, right_width, bottom_width, left_width, color)
Create a matte border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSVariableString]{td}{td}[#getGlobalVariable#createPageFormat]\(name)
Gets an existing global variable by the specified namewidth, height, leftmargin, rightmargin, topmargin, bottommargin, \[orientation\], \[units\])
Create a page format string.{td}{tr}{tbody}{tbody}{tr}{td}[JSVariable]\[String]{td}{td}[#getGlobalVariables#createSpecialMatteBorder]\()
Gets an array of all global variablestop_width, right_width, bottom_width, left_width, top_color, right_color, bottom_color, left_color, rounding_radius, dash_pattern)
Create a special matte border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSMediaString]{td}{td}[#getMedia#createTitledBorder]\(name)
Gets the specified media object; can be assigned to a button/labeltitle_text, font, color, title_justification, title_position)
Create a titled border string.{td}{tr}{tbody}{tbody}{tr}{td}[JSMedia]\[JSCalculation]{td}{td}[#getMediaList#getCalculation]\(name, datasource)
GetsGet an existing calculation for the listgiven ofname alland media objectsdatasource.{td}{tr}{tbody}{tbody}{tr}{td}[JSCalculation]\[JSRelation]{td}{td}[#getRelation#getCalculations]\(namedatasource)
Gets anall existingthe relationcalculations byfor the specified name and returns a JSRelation Objectgiven datasource.{td}{tr}{tbody}{tbody}{tr}{td}[JSRelation]\[JSForm]{td}{td}[#getRelations#getForm]\(\[primary_server_name/primary_data_source\], \[primary_table_name\])
Gets anthe arrayspecified ofform allobject relations;and orreturns an array of all global relations ifinformation about the specifiedform table(see isJSForm NULLnode).{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]\[JSStyle]{td}{td}[#getStyle#getForms]\(name)
GetsGet thean stylearray specifiedof by the given nameall forms.{td}{tr}{tbody}{tbody}{tr}{td}[JSValueListJSForm]\[]{td}{td}[#getValueList#getForms]\(namedatasource)
GetsGet an existingarray valuelist by the specified name and returns a JSValueList Object that can be assigned to a fieldof forms, that are all based on datasource/servername.{td}{tr}{tbody}{tbody}{tr}{td}[JSValueListJSForm]\[]{td}{td}[#getValueLists#getForms]\(server, tablename)
GetsGet an array of forms, that are all valuelistsbased foron thedatasource/servername currentlyand active solutiontablename.{td}{tr}{tbody}{tbody}{tr}{td}[JSFormJSMethod]{td}{td}[#newForm#getGlobalMethod]\(name, server_name|data_source, \[table_name\], style, show_in_menu, width, height)
Creates a new JSForm Object)
Gets an existing global method by the specified name.{td}{tr}{tbody}{tbody}{tr}{td}[JSMethod]\[]{td}{td}[#newGlobalMethod#getGlobalMethods]\(code)
The Createslist aof newall global method with the specified codemethods.{td}{tr}{tbody}{tbody}{tr}{td}[JSVariable]{td}{td}[#newGlobalVariable#getGlobalVariable]\(name, type)
CreatesGets aan newexisting global variable withby the specified name and number type.{td}{tr}{tbody}{tbody}{tr}{td}[JSVariable]\[JSMedia]{td}{td}[#newMedia#getGlobalVariables]\(name, bytes)
CreatesGets aan newarray mediaof objectall that can be assigned to a label or a buttonglobal variables.{td}{tr}{tbody}{tbody}{tr}{td}[JSRelationJSMedia]{td}{td}[#newRelation#getMedia]\(name, primary_server_name|primary_data_source, \[primary_table_name\], foreign_server_name|foreign_data_source, \[foreign_table_name\], join_type)
Creates a new JSRelation Object with a specified name; includes the primary datasource, optional table name, foreign datasource, optional foreign table name, and the type of join for the new relation)
Gets the specified media object; can be assigned to a button/label.{td}{tr}{tbody}{tbody}{tr}{td}[JSMedia]\[JSStyle]{td}{td}[#newStyle#getMediaList]\(name, content)
Creates a new style withGets the givenlist cssof contentall string under the given namemedia objects.{td}{tr}{tbody}{tbody}{tr}{td}[JSValueListJSRelation]{td}{td}[#newValueList#getRelation]\(name, type)
CreatesGets aan newexisting valuelistrelation withby the specified name and returns a numberJSRelation typeObject.{td}{tr}{tbody}{tbody}{tr}{td}[BooleanJSRelation]\[]{td}{td}[#removeForm#getRelations]\(name)
Removes the specified form during the persistent connected client session\[primary_server_name/primary_data_source\], \[primary_table_name\])
Gets an array of all relations; or an array of all global relations if the specified table is NULL.{td}{tr}{tbody}{tbody}{tr}{td}[JSFormJSStyle]{td}{td}[#revertForm#getStyle]\(name)
RevertsGets the style specified form toby the original (blueprint) version of the form; will result in an exception error if the form is not an original formgiven name.{td}{tr}{tbody}{tbody}{tr}{td}[JSValueList]{td}{td}[#getValueList]\(name)
Gets an existing valuelist by the specified name and returns a JSValueList Object that can be assigned to a field.{td}{tr}{tbody}{tabletbody}\\ 

{table:id=function|class=servoy sDetail{tr}{colgroup}{column:padding=0px|width=100%}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=cloneComponent|class=node}{tr:id=name}{td}h6.cloneComponent{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSComponent]{span}{span:id=iets|style=float: left; font-weight: bold;}cloneComponent{span}{span:id=iets|style=float: left;}\(newName, component, \[newParentForm\]){span}{td}{tr}{tr:id=des}{td}{sub-section:cloneComponent_des|text=|trigger=button}{sub-section}{sub-section:cloneComponent_des|trigger=none|class=sIndent}Makes an exact copy of the given component (JSComponent/JSField/JSLabel), gives it a new name and optionally moves it to a new parent form.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:cloneComponent_snc|text=|trigger=button}{sub-section}{sub-section:cloneComponent_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:cloneComponent_prs|text=|trigger=button}{sub-section}{sub-section:cloneComponent_prs|trigger=none|class=sIndent}\{[String]} newName -- the new name of the cloned component
\{[JSComponent]} component -- the component to clone
\{[JSForm]} \[newParentForm\] -- the new parent form
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:cloneComponent_ret|text=|trigger=button}{sub-section}{sub-section:cloneComponent_ret|trigger=none|class=sIndent}[JSComponent] -- the exact copy of the given component{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:cloneComponent_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneComponent_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:cloneComponent_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneComponent_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:cloneComponent_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneComponent_sam|trigger=none}{code:language=javascript}
// get an existing field to clone.
var field = solutionModel.getForm("formWithField").getField("fieldName");
// get the target form for the copied/cloned field
var form = solutionModel.getForm("targetForm");
// make a clone/copy of the field and re parent it to the target form.
var clone = solutionModel.cloneComponent("clonedField",field,form);
// show it
forms["targetForm"].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}td}[JSValueList]\[]{td}{td}[#getValueLists]\()
Gets an array of all valuelists for the currently active solution.{td}{tr}{tbody}{tbody}{tr}{td}[JSCalculation]{td}{td}[#newCalculation]\(code, type, datasource)
Creates a new calculation for the given code and the type, if it builds on a column (name is a column name) then type will be ignored.{td}{tr}{tbody}{tbody}{tr}{td}[JSCalculation]{td}{td}[#newCalculation]\(code, datasource)
Creates a new calculation for the given code, the type will be the column where it could be build on (if name is a column name),
else it will default to JSVariable.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]{td}{td}[#newForm]\(name, superForm)
Creates a new form with the given JSForm as its super form.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]{td}{td}[#newForm]\(name, dataSource, styleName, show_in_menu, width, height)
Creates a new JSForm Object.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]{td}{td}[#newForm]\(name, serverName, tableName, styleName, show_in_menu, width, height)
Creates a new JSForm Object.{td}{tr}{tbody}{tbody}{tr}{td}[JSMethod]{td}{td}[#newGlobalMethod]\(code)
Creates a new global method with the specified code.{td}{tr}{tbody}{tbody}{tr}{td}[JSVariable]{td}{td}[#newGlobalVariable]\(name, type)
Creates a new global variable with the specified name and number type.{td}{tr}{tbody}{tbody}{tr}{td}[JSMedia]{td}{td}[#newMedia]\(name, bytes)
Creates a new media object that can be assigned to a label or a button.{td}{tr}{tbody}{tbody}{tr}{td}[JSRelation]{td}{td}[#newRelation]\(name, primaryDataSource, foreignDataSource, joinType)
Creates a new JSRelation Object with a specified name; includes the primary datasource, foreign datasource and the type of join for the new relation.{td}{tr}{tbody}{tbody}{tr}{td}[JSRelation]{td}{td}[#newRelation]\(name, primaryServerName, primaryTableName, foreignServerName, foreignTableName, joinType)
Creates a new JSRelation Object with a specified name; includes the primary server and table name, foreign server and table name, and the type of join for the new relation.{td}{tr}{tbody}{tbody}{tr}{td}[JSStyle]{td}{td}[#newStyle]\(name, content)
Creates a new style with the given css content string under the given name.{td}{tr}{tbody}{tbody:id=cloneForm|class=node}{tr:id=name}{td}h6.cloneForm{td}{tr}{tr:id=sig[JSValueList]{td}{td}{span:style=float: left; margin-right: 5px;}[JSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}cloneForm{span}{span:id=iets|style=float: left;}\(newName, jsForm){span}{td}{tr}{tr:id=des}{td}{sub-section:cloneForm_des|text=|trigger=button}{sub-section}{sub-section:cloneForm_des|trigger=none|class=sIndent}Makes an exact copy of the given form and gives it the new name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:cloneForm_snc|text=|trigger=button}{sub-section}{sub-section:cloneForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:cloneForm_prs|text=|trigger=button}{sub-section}{sub-section:cloneForm_prs|trigger=none|class=sIndent}\{[String]} newName -- the new name for the form clone
\{[JSForm]} jsForm -- the form to be cloned
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:cloneForm_ret|text=|trigger=button}{sub-section}{sub-section:cloneForm_ret|trigger=none|class=sIndent}[JSForm] -- a JSForm{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:cloneForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:cloneForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:cloneForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:cloneForm_sam|trigger=none}{code:language=javascript}
// get an existing form
var form = solutionModel.getForm("existingForm")
// make a clone/copy from it
var clone = solutionModel.cloneForm("clonedForm", form)
// add a new label to the clone
clone.newLabel("added label",50,50,80,20);
// show it
forms["clonedForm"].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getForm[#newValueList]\(name, type)
Creates a new valuelist with the specified name and number type.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeCalculation]\(name, datasource)
Removes the calculation specified by name and datasource.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeForm]\(name)
Removes the specified form during the persistent connected client session.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeGlobalMethod]\(name)
Removes the specified global method.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeGlobalVariable]\(name)
Removes the specified global variable.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeMedia]\(name)
Removes the media item specified by name.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeRelation]\(name)
Removes the relation specified by name.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeStyle]\(name)
Removes the specified style.{td}{tr}{tbody}{tbody}{tr}{td}[Boolean]{td}{td}[#removeValueList]\(name)
Removes the specified valuelist.{td}{tr}{tbody}{tbody}{tr}{td}[JSForm]{td}{td}[#revertForm]\(name)
Reverts the specified form to the original (blueprint) version of the form; will result in an exception error if the form is not an original form.{td}{tr}{tbody}{tbody}{tr}{td}[JSMethod]{td}{td}[#wrapMethodWithArguments]\(method, args)
Get a JSMethod instance with arguments to be assigned to an event.{td}{tr}{tbody}{table}\\ 

{table:id=function|class=servoy sDetail}{colgroup}{column:padding=0px|width=100%}{column}{colgroup}{tr:style=height: 30px;}{th:colspan=1}Method Details{th}{tr}{tbody:id=cloneComponent-String_JSComponent|class=node}{tr:id=name}{td}h6.getFormcloneComponent{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSFormJSComponent]{span}{span:id=iets|style=float: left; font-weight: bold;}getFormcloneComponent{span}{span:id=iets|style=float: left;}\(namenewName, component){span}{td}{tr}{tr:id=des}{td}{sub-section:getFormcloneComponent-String_JSComponent_des|text=|trigger=button}{sub-section}{sub-section:getFormcloneComponent-String_JSComponent_des|trigger=none|class=sIndent}GetsMakes an theexact specifiedcopy formof objectthe andgiven returns information about the form (see JSForm node)component (JSComponent/JSField/JSLabel) and gives it a new name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getFormcloneComponent-String_JSComponent_snc|text=|trigger=button}{sub-section}{sub-section:getFormcloneComponent-String_JSComponent_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getFormcloneComponent-String_JSComponent_prs|text=|trigger=button}{sub-section}{sub-section:getFormcloneComponent-String_JSComponent_prs|trigger=none|class=sIndent}\{[String]} namenewName -- the specifiednew name of the form cloned component
\{[JSComponent]} component -- the component to clone
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getFormcloneComponent-String_JSComponent_ret|text=|trigger=button}{sub-section}{sub-section:getFormcloneComponent-String_JSComponent_ret|trigger=none|class=sIndent}[JSFormJSComponent] -- a JSForm the exact copy of the given component{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getFormcloneComponent-String_JSComponent_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormcloneComponent-String_JSComponent_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getFormcloneComponent-String_JSComponent_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormcloneComponent-String_JSComponent_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getFormcloneComponent-String_JSComponent_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormcloneComponent-String_JSComponent_sam|trigger=none}{code:language=javascript}
var myForm = solutionModel.getForm('existingFormName'
// get an existing field to clone.
var field = solutionModel.getForm("formWithField").getField("fieldName");
//get make thea styleclone/copy of the form (for all other properties see JSForm node)field
var styleNameclone = myForm.styleNamesolutionModel.cloneComponent("clonedField",field);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getFormscloneComponent-String_JSComponent_JSForm|class=node}{tr:id=name}{td}h6.getFormscloneComponent{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]\[JSComponent]{span}{span:id=iets|style=float: left; font-weight: bold;}getFormscloneComponent{span}{span:id=iets|style=float: left;}\(\[server\], \[tablename\]newName, component, newParentForm){span}{td}{tr}{tr:id=des}{td}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_des|text=|trigger=button}{sub-section}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_des|trigger=none|class=sIndent}GetMakes an exact arraycopy of forms, that are all based on datasource/servername or tablename the given component (JSComponent/JSField/JSLabel), gives it a new name and moves it to a new parent form, specified as a parameter.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_snc|text=|trigger=button}{sub-section}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_prs|text=|trigger=button}{sub-section}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_prs|trigger=none|class=sIndent}\{[String]} newName -- the new name of the cloned component
\{[server\JSComponent]} component -- the datasourcecomponent orto servernameclone
\{[StringJSForm]} \[tablename\]newParentForm -- the new parent tablenameform
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_ret|text=|trigger=button}{sub-section}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_ret|trigger=none|class=sIndent}[JSForm]\[JSComponent] -- the anexact arraycopy of JSFormthe typegiven elementscomponent{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getFormscloneComponent-String_JSComponent_JSForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getFormscloneComponent-String_JSComponent_JSForm_sam|trigger=none}{code:language=javascript}
// get an existing field to clone.
var formsfield = solutionModel.getForms(datasource)
for (var i in forms)
		application.output(forms[i].name).getForm("formWithField").getField("fieldName");
// get the target form for the copied/cloned field
var form = solutionModel.getForm("targetForm");
// make a clone/copy of the field and re parent it to the target form.
var clone = solutionModel.cloneComponent("clonedField",field,form);
// show it
forms["targetForm"].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalMethodcloneForm|class=node}{tr:id=name}{td}h6.getGlobalMethodcloneForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethodJSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalMethodcloneForm{span}{span:id=iets|style=float: left;}\(namenewName, jsForm){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalMethodcloneForm_des|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodcloneForm_des|trigger=none|class=sIndent}GetsMakes an existing global method by exact copy of the given form and gives it the specifiednew name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalMethodcloneForm_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodcloneForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalMethodcloneForm_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodcloneForm_prs|trigger=none|class=sIndent}\{[String]} namenewName -- the new name of the specified global method for the form clone
\{[JSForm]} jsForm -- the form to be cloned
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalMethodcloneForm_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodcloneForm_ret|trigger=none|class=sIndent}[JSMethodJSForm] -- a JSMethodJSForm{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalMethodcloneForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodcloneForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalMethodcloneForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodcloneForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalMethodcloneForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodcloneForm_sam|trigger=none}{code:language=javascript}
var// methodget = an existing form
var form = solutionModel.getGlobalMethodgetForm("nameOfGlobalMethodexistingForm"); 
	if (method != null) application.output(method.code
// make a clone/copy from it
var clone = solutionModel.cloneForm("clonedForm", form)
// add a new label to the clone
clone.newLabel("added label",50,50,80,20);
// show it
forms["clonedForm"].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalMethodscreateBevelBorder|class=node}{tr:id=name}{td}h6.getGlobalMethodscreateBevelBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethod]\[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalMethodscreateBevelBorder{span}{span:id=iets|style=float: left;}\(bevel_type, highlight_outer_color, highlight_inner_color, shadow_outer_color, shadow_inner_color){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalMethodscreateBevelBorder_des|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodscreateBevelBorder_des|trigger=none|class=sIndent}TheCreate lista ofbevel allborder global methodsstring.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalMethodscreateBevelBorder_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodscreateBevelBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalMethodscreateBevelBorder_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodscreateBevelBorder_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show\{[Number]} bevel_type -- bevel border type (SM\_BEVELTYPE.RAISED or SM\_BEVELTYPE.LOWERED)
\{[String]} highlight_outer_color -- bevel border highlight outer color
\{[String]} highlight_inner_color -- bevel border highlight inner color
\{[String]} shadow_outer_color -- bevel border shadow outer color
\{[String]} shadow_inner_color -- bevel border shadow outer color
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalMethodscreateBevelBorder_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalMethodscreateBevelBorder_ret|trigger=none|class=sIndent}[JSMethod]\[] -- an array of JSMethod type elementsString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalMethodscreateBevelBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodscreateBevelBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalMethodscreateBevelBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodscreateBevelBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalMethodscreateBevelBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethodscreateBevelBorder_sam|trigger=none}{code:language=javascript}
var methodsform = solutionModel.getGlobalMethodsgetForm("someForm");
form.borderType 	if (methods != null)
		for (var x in methods) 
			application.output(methods[x].getName())= solutionModel.createBevelBorder(SM_BEVELTYPE.RAISED,'#ff0000','#00ff00','#ff0000','#00ff00');
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalVariablecreateEmptyBorder|class=node}{tr:id=name}{td}h6.getGlobalVariablecreateEmptyBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSVariableString]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalVariablecreateEmptyBorder{span}{span:id=iets|style=float: left;}\(nametop_width, right_width, bottom_width, left_width){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalVariablecreateEmptyBorder_des|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablecreateEmptyBorder_des|trigger=none|class=sIndent}GetsCreate an existingempty global variable by the specified nameborder string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalVariablecreateEmptyBorder_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablecreateEmptyBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalVariablecreateEmptyBorder_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablecreateEmptyBorder_prs|trigger=none|class=sIndent}\{[StringNumber]} nametop_width -- thetop specifiedwidth nameof ofempty theborder globalin variablepixels
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalVariable_\{[Number]} right_width -- right width of empty border in pixels
\{[Number]} bottom_width -- bottom width of empty border in pixels
\{[Number]} left_width -- left width of empty border in pixels
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:createEmptyBorder_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablecreateEmptyBorder_ret|trigger=none|class=sIndent}[JSVariable] -- a JSVariableString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalVariablecreateEmptyBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablecreateEmptyBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalVariablecreateEmptyBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablecreateEmptyBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalVariablecreateEmptyBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablecreateEmptyBorder_sam|trigger=none}{code:language=javascript}
var globalVariableform = solutionModel.getGlobalVariable('globalVariableName'getForm("someForm");
	application.output(globalVariable.name + " has the default value of " + globalVariable.defaultValueform.borderType = solutionModel.createEmptyBorder(1,1,1,1);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalVariablescreateEtchedBorder|class=node}{tr:id=name}{td}h6.getGlobalVariablescreateEtchedBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSVariable]\[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalVariablescreateEtchedBorder{span}{span:id=iets|style=float: left;}\(bevel_type, highlight_color, shadow_color){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalVariablescreateEtchedBorder_des|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablescreateEtchedBorder_des|trigger=none|class=sIndent}GetsCreate an arrayetched of all global variables.{border string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalVariablescreateEtchedBorder_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablescreateEtchedBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalVariablescreateEtchedBorder_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablescreateEtchedBorder_prs|trigger=none|class=sIndent}\{[Number]} bevel_type -- bevel border type
\{[String]} highlight_color -- bevel border highlight color
\{[String]} shadow_color -- bevel border shadow color
{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalVariablescreateEtchedBorder_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalVariablescreateEtchedBorder_ret|trigger=none|class=sIndent}[JSVariable]\[] -- an array of JSVariable type elementsString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalVariablescreateEtchedBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablescreateEtchedBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalVariablescreateEtchedBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablescreateEtchedBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalVariablescreateEtchedBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariablescreateEtchedBorder_sam|trigger=none}{code:language=javascript}
var globalVariablesform = solutionModel.getGlobalVariablesgetForm("someForm");
	for (var i in globalVariables)
		application.output(globalVariables[i].name + " has the default value of " + globalVariables[i].defaultValue);
{code}{sub-section}{form.borderType = solutionModel.createEtchedBorder(SM_BEVELTYPE.RAISED,'#ff0000','#00ff00');
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getMediacreateFont|class=node}{tr:id=name}{td}h6.getMediacreateFont{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMediaString]{span}{span:id=iets|style=float: left; font-weight: bold;}getMediacreateFont{span}{span:id=iets|style=float: left;}\(name, style, size){span}{td}{tr}{tr:id=des}{td}{sub-section:getMediacreateFont_des|text=|trigger=button}{sub-section}{sub-section:getMediacreateFont_des|trigger=none|class=sIndent}GetsCreate thea specified media object; can be assigned to a button/labelfont string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getMediacreateFont_snc|text=|trigger=button}{sub-section}{sub-section:getMediacreateFont_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getMediacreateFont_prs|text=|trigger=button}{sub-section}{sub-section:getMediacreateFont_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the specified name of the media object font
\{[Number]} style -- the style of the font (PLAIN, BOLD, ITALIC or BOLD+ITALIC)
\{[Number]} size -- the font size
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getMediacreateFont_ret|text=|trigger=button}{sub-section}{sub-section:getMediacreateFont_ret|trigger=none|class=sIndent}[JSMedia] -- a JSMedia elementString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getMediacreateFont_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediacreateFont_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getMediacreateFont_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediacreateFont_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getMediacreateFont_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediacreateFont_sam|trigger=none}{code:language=javascript}
var myMediaform = solutionModel.getMedia('button01.gif')
//now set the imageMedia property of your label or button
//myButton.imageMedia = myMedia
// OR
//myLabel.imageMedia = myMediagetForm("someForm");
var component = form.getComponent("someComponent")
component.fontType = solutionModel.createFont('Arial',SM_FONTSTYLE.BOLD,14);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getMediaListcreateLineBorder|class=node}{tr:id=name}{td}h6.getMediaListcreateLineBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMedia]\[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getMediaListcreateLineBorder{span}{span:id=iets|style=float: left;}\(thick, color){span}{td}{tr}{tr:id=des}{td}{sub-section:getMediaListcreateLineBorder_des|text=|trigger=button}{sub-section}{sub-section:getMediaListcreateLineBorder_des|trigger=none|class=sIndent}GetsCreate thea listline of all media objectsborder string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getMediaListcreateLineBorder_snc|text=|trigger=button}{sub-section}{sub-section:getMediaListcreateLineBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getMediaListcreateLineBorder_prs|text=|trigger=button}{sub-section}{sub-section:getMediaListcreateLineBorder_prs|trigger=none|class=sIndent}\{[Number]} thick -- border thickness in pixels
\{[String]} color -- color of the line border
{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getMediaListcreateLineBorder_ret|text=|trigger=button}{sub-section}{sub-section:getMediaListcreateLineBorder_ret|trigger=none|class=sIndent}[JSMedia]\[] -- a list with all the media objects.String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getMediaListcreateLineBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaListcreateLineBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getMediaListcreateLineBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaListcreateLineBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getMediaListcreateLineBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaListcreateLineBorder_sam|trigger=none}{code:language=javascript}
var mediaListform = solutionModel.getMediaListgetForm("someForm");
	if (mediaList.length != 0 && mediaList != null) {
		for (var x in mediaList) {
			application.output(mediaList[x]);
		}
	}form.borderType = solutionModel.createLineBorder(1,'#ff0000');
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getRelationcreateMatteBorder|class=node}{tr:id=name}{td}h6.getRelationcreateMatteBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelationString]{span}{span:id=iets|style=float: left; font-weight: bold;}getRelationcreateMatteBorder{span}{span:id=iets|style=float: left;}\(nametop_width, right_width, bottom_width, left_width, color){span}{td}{tr}{tr:id=des}{td}{sub-section:getRelationcreateMatteBorder_des|text=|trigger=button}{sub-section}{sub-section:getRelationcreateMatteBorder_des|trigger=none|class=sIndent}GetsCreate ana existingmatte relation by the specified name and returns a JSRelation Objectborder string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getRelationcreateMatteBorder_snc|text=|trigger=button}{sub-section}{sub-section:getRelationcreateMatteBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getRelationcreateMatteBorder_prs|text=|trigger=button}{sub-section}{sub-section:getRelationcreateMatteBorder_prs|trigger=none|class=sIndent}\{[StringNumber]} nametop_width -- thetop width specifiedof namematte ofborder thein relationpixels
{sub-section}{td}\{[Number]} right_width -- right width of matte border in pixels
\{[Number]} bottom_width -- bottom width of matte border in pixels
\{[Number]} left_width -- left width of matte border in pixels
\{[String]} color -- border color
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getRelationcreateMatteBorder_ret|text=|trigger=button}{sub-section}{sub-section:getRelationcreateMatteBorder_ret|trigger=none|class=sIndent}[JSRelation] -- a JSRelationString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getRelationcreateMatteBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationcreateMatteBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getRelationcreateMatteBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationcreateMatteBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getRelationcreateMatteBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationcreateMatteBorder_sam|trigger=none}{code:language=javascript}
var relationform = solutionModel.getRelation('name');
	application.output("The primary server name is " + relation.primaryServerNamegetForm("someForm");
	application.output("The primary table name is " + relation.primaryTableName); 
	application.output("The foreign table name is " + relation.foreignTableName); 
	application.output("The relation items are " + relation.getRelationItems());
{codeform.borderType = solutionModel.createMatteBorder(1,1,1,1,"#00ff00");
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getRelationscreatePageFormat|class=node}{tr:id=name}{td}h6.getRelationscreatePageFormat{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelation]\[String]{span}{span:id=iets|style=float: left; font-weight: bold;}getRelationscreatePageFormat{span}{span:id=iets|style=float: left;}\(\[primary_server_name/primary_data_sourcewidth, height, leftmargin, rightmargin, topmargin, bottommargin, \[orientation\], \[primary_table_nameunits\]){span}{td}{tr}{tr:id=des}{td}{sub-section:getRelationscreatePageFormat_des|text=|trigger=button}{sub-section}{sub-section:getRelationscreatePageFormat_des|trigger=none|class=sIndent}GetsCreate a anpage arrayformat ofstring.
all
relations;Note: orThe anunit arrayspecified offor allwidth, globalheight relationsand ifall themargins specifiedMUST tablebe isthe NULLsame.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getRelationscreatePageFormat_snc|text=|trigger=button}{sub-section}{sub-section:getRelationscreatePageFormat_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getRelationscreatePageFormat_prs|text=|trigger=button}{sub-section}{sub-section:getRelationscreatePageFormat_prs|trigger=none|class=sIndent}\[primary\_server\_name/primary\_data\_source\]width -- the specified namewidth of the serverpage orto datasourcebe for the specified table
\[primary\_table\_name\] printed.
height -- the specified nameheight of the page to table
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getRelations_ret|text=|trigger=button}{sub-section}{sub-section:getRelations_ret|trigger=none|class=sIndent}[JSRelation]\[] -- an array of all relations (all elements in the array are of type JSRelation){sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getRelations_seebe printed.
leftmargin -- the specified left margin of the page to be printed.
rightmargin -- the specified right margin of the page to be printed.
topmargin -- the specified top margin of the page to be printed.
bottommargin -- the specified bottom margin of the page to be printed.
\[orientation\] -- the specified orientation of the page to be printed; the default is Portrait mode
\[units\] -- the specified units for the width and height of the page to be printed; the default is pixels
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:createPageFormat_ret|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationscreatePageFormat_seeret|trigger=none|class=sIndent}[String]{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=linksee}{td}*ExternalAlso linkssee*\\{sub-section:getRelationscreatePageFormat_linksee|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationscreatePageFormat_linksee|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=samlink}{td}*SampleExternal links*\\{sub-section:getRelationscreatePageFormat_samlink|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelationscreatePageFormat_samlink|trigger=none}{sub-section}{code:language=javascript}
var relationsdiv}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:createPageFormat_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:createPageFormat_sam|trigger=none}{code:language=javascript}
var form = solutionModel.getRelations('server_name','table_name'getForm("someForm");
	if (relations.length != 0)
		for (var i in relations)
			application.output(relations[i].nameform.defaultPageFormat = solutionModel.createPageFormat(612,792,72,72,72,72,SM_ORIENTATION.PORTRAIT,SM_UNITS.PIXELS);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getStylecreateSpecialMatteBorder|class=node}{tr:id=name}{td}h6.getStylecreateSpecialMatteBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSStyleString]{span}{span:id=iets|style=float: left; font-weight: bold;}getStylecreateSpecialMatteBorder{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getStyle_destop_width, right_width, bottom_width, left_width, top_color, right_color, bottom_color, left_color, rounding_radius, dash_pattern){span}{td}{tr}{tr:id=des}{td}{sub-section:createSpecialMatteBorder_des|text=|trigger=button}{sub-section}{sub-section:getStylecreateSpecialMatteBorder_des|trigger=none|class=sIndent}GetsCreate thea stylespecial specifiedmatte by the given nameborder string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getStylecreateSpecialMatteBorder_snc|text=|trigger=button}{sub-section}{sub-section:getStylecreateSpecialMatteBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getStylecreateSpecialMatteBorder_prs|text=|trigger=button}{sub-section}{sub-section:getStylecreateSpecialMatteBorder_prs|trigger=none|class=sIndent}\{[StringNumber]} nametop_width -- top thewidth specifiedof namematte ofborder thein style
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getStyle_ret|text=|trigger=button}{sub-section}{sub-section:getStyle_ret|trigger=none|class=sIndent}[JSStyle]pixels
\{[Number]} right_width -- a JSStyle{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getStyle_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStyleright width of matte border in pixels
\{[Number]} bottom_width -- bottom width of matte border in pixels
\{[Number]} left_width -- left width of matte border in pixels
\{[String]} top_color -- top border color
\{[String]} right_color -- right border color
\{[String]} bottom_color -- bottom border color
\{[String]} left_color -- left border color
\{[Number]} rounding_radius -- width of the arc to round the corners
\{[Number]\[]} dash_pattern -- the dash pattern of border stroke
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:createSpecialMatteBorder_ret|text=|trigger=button}{sub-section}{sub-section:createSpecialMatteBorder_ret|trigger=none|class=sIndent}[String]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:createSpecialMatteBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:createSpecialMatteBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getStylecreateSpecialMatteBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStylecreateSpecialMatteBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getStylecreateSpecialMatteBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStylecreateSpecialMatteBorder_sam|trigger=none}{code:language=javascript}
var styleform = solutionModel.getStyle('my_existing_style')
	style.content = 'combobox { color: #0000ff;font: italic 10pt "Verdana";}'getForm("someForm");
// create a rectangle border (no rounded corners) and continous line
form.borderType = solutionModel.createSpecialMatteBorder(1,1,1,1,"#00ff00","#00ff00","#00ff00","#00ff00",0,null);
// create a border with rounded corners and dashed line (25 pixels drawn, then 25 pixels skipped)
// form.borderType = solutionModel.createSpecialMatteBorder(1,1,1,1,"#00ff00","#00ff00","#00ff00","#00ff00",10,new Array(25,25));
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getValueListcreateTitledBorder|class=node}{tr:id=name}{td}h6.getValueListcreateTitledBorder{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueListString]{span}{span:id=iets|style=float: left; font-weight: bold;}getValueListcreateTitledBorder{span}{span:id=iets|style=float: left;}\(name){span}title_text, font, color, title_justification, title_position){span}{td}{tr}{tr:id=des}{td}{sub-section:getValueListcreateTitledBorder_des|text=|trigger=button}{sub-section}{sub-section:getValueListcreateTitledBorder_des|trigger=none|class=sIndent}Gets an existing valuelist by the specified name and returnsCreate a JSValueListtitled Object that can be assigned to a fieldborder string.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getValueListcreateTitledBorder_snc|text=|trigger=button}{sub-section}{sub-section:getValueListcreateTitledBorder_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getValueListcreateTitledBorder_prs|text=|trigger=button}{sub-section}{sub-section:getValueListcreateTitledBorder_prs|trigger=none|class=sIndent}\{[String]} nametitle_text -- the specified name of the valuelist text from border
\{[String]} font -- title text font string
\{[String]} color -- border color
\{[Number]} title_justification -- title text justification
\{[Number]} title_position -- bevel title text position
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getValueListcreateTitledBorder_ret|text=|trigger=button}{sub-section}{sub-section:getValueListcreateTitledBorder_ret|trigger=none|class=sIndent}[JSValueList] -- a JSValueList objectString]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getValueListcreateTitledBorder_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListcreateTitledBorder_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getValueListcreateTitledBorder_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListcreateTitledBorder_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getValueListcreateTitledBorder_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListcreateTitledBorder_sam|trigger=none}{code:language=javascript}
var myValueListform = solutionModel.getValueList('myValueListHere')
//now set the valueList property of your field
//myField.valuelist = myValueListgetForm("someForm");
form.borderType = solutionModel.createTitledBorder('Test',solutionModel.createFont('Arial',SM_FONTSTYLE.PLAIN,10),'#ff0000',SM_TITLEJUSTIFICATION.CENTER,SM_TITLEPOSITION.TOP);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getValueListsgetCalculation|class=node}{tr:id=name}{td}h6.getValueListsgetCalculation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueList]\[JSCalculation]{span}{span:id=iets|style=float: left; font-weight: bold;}getValueListsgetCalculation{span}{span:id=iets|style=float: left;}\(name, datasource){span}{td}{tr}{tr:id=des}{td}{sub-section:getValueListsgetCalculation_des|text=|trigger=button}{sub-section}{sub-section:getValueListsgetCalculation_des|trigger=none|class=sIndent}GetsGet an arrayexisting ofcalculation all valuelists for the given currentlyname activeand solutiondatasource.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getValueListsgetCalculation_snc|text=|trigger=button}{sub-section}{sub-section:getValueListsgetCalculation_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getValueListsgetCalculation_prs|text=|trigger=button}{sub-section}{sub-section:getValueListsgetCalculation_prs|trigger=none|class=sIndent}\{[String]} name -- The name of the calculation
\{[String]} datasource -- The datasource the calculation belongs to.
{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getValueListsgetCalculation_ret|text=|trigger=button}{sub-section}{sub-section:getValueListsgetCalculation_ret|trigger=none|class=sIndent}[JSValueList]\[] -- an array of JSValueList objects{sub-section}JSCalculation]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getValueListsgetCalculation_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListsgetCalculation_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getValueListsgetCalculation_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListsgetCalculation_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getValueListsgetCalculation_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueListsgetCalculation_sam|trigger=none}{code:language=javascript}
var valueListscalc = solutionModel.getValueLists();
	if (valueLists != null && valueLists.length != 0)
		for (var i in valueLists)
			application.output(valueLists[i].name);newCalculation("function myCalculation() { return 123; }", JSVariable.INTEGER, "db:/example_data/customers");
var calc2 = solutionModel.newCalculation("function myCalculation2() { return '20'; }", "db:/example_data/customers");
var calc3 = solutionModel.newCalculation("function myCalculation3() { return 'Hello World!'; }",	JSVariable.TEXT, "db:/example_data/employees");

var c = solutionModel.getCalculation("myCalculation","db:/example_data/customers");
application.output("Name: " + c.getName() + ", Stored: " + c.isStored());

var allCalcs = solutionModel.getCalculations("db:/example_data/customers");
for (var i = 0; i < allCalcs.length; i++) {
	application.output(allCalcs[i]);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newFormgetCalculations|class=node}{tr:id=name}{td}h6.newFormgetCalculations{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSCalculation]\[JSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}newFormgetCalculations{span}{span:id=iets|style=float: left;}\(name, server_name|data_source, \[table_name\], style, show_in_menu, width, heightdatasource){span}{td}{tr}{tr:id=des}{td}{sub-section:newFormgetCalculations_des|text=|trigger=button}{sub-section}{sub-section:newFormgetCalculations_des|trigger=none|class=sIndent}Creates a new JSForm Object.

NOTE: SeeGets all the JSForm nodecalculations for more information about form objects that can be added to the newgiven formdatasource.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newFormgetCalculations_snc|text=|trigger=button}{sub-section}{sub-section:newFormgetCalculations_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newFormgetCalculations_prs|text=|trigger=button}{sub-section}{sub-section:newFormgetCalculations_prs|trigger=none|class=sIndent}name -- the specified name of the form
server_name|data_source -- the specified name of the server or datasource for the specified table
\[table\_name\] -- the specified name of the table
style\{[String]} datasource -- theThe specified style
show_in_menu -- if true show the name of the new form in the menu; or false for not showing
width -- the width of the form in pixels
height -- the height of the form in pixels
datasource the calculations belong to.
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newFormgetCalculations_ret|text=|trigger=button}{sub-section}{sub-section:newFormgetCalculations_ret|trigger=none|class=sIndent}[JSCalculation]\[JSForm] -- a new JSForm object{sub-section}{td{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newFormgetCalculations_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newFormgetCalculations_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newFormgetCalculations_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newFormgetCalculations_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newFormgetCalculations_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newFormgetCalculations_sam|trigger=none}{code:language=javascript}
var myFormcalc = solutionModel.newForm('newForm', 'myServer', 'myTable', 'myStyleName', false, 800, 600)
//now you can add stuff to the form (under JSForm node)
//add a label
myForm.newLabel('Name', 20, 20, 120, 30)
//add a "normal" text entry field
myForm.newTextField('dataProviderNameHere', 140, 20, 140,20)newCalculation("function myCalculation() { return 123; }", JSVariable.INTEGER, "db:/example_data/customers");
var calc2 = solutionModel.newCalculation("function myCalculation2() { return '20'; }", "db:/example_data/customers");
var calc3 = solutionModel.newCalculation("function myCalculation3() { return 'Hello World!'; }",	JSVariable.TEXT, "db:/example_data/employees");

var c = solutionModel.getCalculation("myCalculation","db:/example_data/customers");
application.output("Name: " + c.getName() + ", Stored: " + c.isStored());

var allCalcs = solutionModel.getCalculations("db:/example_data/customers");
for (var i = 0; i < allCalcs.length; i++) {
	application.output(allCalcs[i]);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newGlobalMethodgetForm|class=node}{tr:id=name}{td}h6.newGlobalMethodgetForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethodJSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}newGlobalMethodgetForm{span}{span:id=iets|style=float: left;}\(codename){span}{td}{tr}{tr:id=des}{td}{sub-section:newGlobalMethodgetForm_des|text=|trigger=button}{sub-section}{sub-section:newGlobalMethodgetForm_des|trigger=none|class=sIndent}Creates a new global method with the specified codeGets the specified form object and returns information about the form (see JSForm node).{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newGlobalMethodgetForm_snc|text=|trigger=button}{sub-section}{sub-section:newGlobalMethodgetForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newGlobalMethodgetForm_prs|text=|trigger=button}{sub-section}{sub-section:newGlobalMethodgetForm_prs|trigger=none|class=sIndent}\{[String]} codename -- the specified codename forof the globalform
method
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newGlobalMethodgetForm_ret|text=|trigger=button}{sub-section}{sub-section:newGlobalMethodgetForm_ret|trigger=none|class=sIndent}[JSMethodJSForm] -- a JSMethod object{JSForm{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newGlobalMethodgetForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethodgetForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newGlobalMethodgetForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethodgetForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newGlobalMethodgetForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethodgetForm_sam|trigger=none}{code:language=javascript}
var methodmyForm = solutionModel.newGlobalMethodgetForm('function myglobalmethod(){currentcontroller.newRecord()}')'existingFormName');
//get the style of the form (for all other properties see JSForm node)
var styleName = myForm.styleName;
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newGlobalVariablegetForms|class=node}{tr:id=name}{td}h6.newGlobalVariablegetForms{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]\[JSVariable]{span}{span:id=iets|style=float: left; font-weight: bold;}newGlobalVariablegetForms{span}{span:id=iets|style=float: left;}\(name, type){span}{td}{tr}{tr:id=des}{td}{sub-section:newGlobalVariablegetForms_des|text=|trigger=button}{sub-section}{sub-section:newGlobalVariablegetForms_des|trigger=none|class=sIndent}CreatesGet aan newarray globalof variable with the specified name and number type.

NOTE: The global variable number type is based on the value assigned from the SolutionModel\-JSVariable node; for example: JSVariable.INTEGER.all forms.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newGlobalVariablegetForms_snc|text=|trigger=button}{sub-section}{sub-section:newGlobalVariablegetForms_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:newGlobalVariablegetForms_prs|text=|trigger=button}{sub-section}{sub-section:newGlobalVariablegetForms_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name for the global variable
\{[Number]} type -- the specified number type for the global variable
{sub-section}{td}{tr{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:newGlobalVariablegetForms_ret|text=|trigger=button}{sub-section}{sub-section:newGlobalVariablegetForms_ret|trigger=none|class=sIndent}[JSForm]\[JSVariable] -- a JSVariable object an array of JSForm type elements{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newGlobalVariablegetForms_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariablegetForms_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newGlobalVariablegetForms_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariablegetForms_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newGlobalVariablegetForms_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariablegetForms_sam|trigger=none}{code:language=javascript}
var myGlobalVariableforms = solutionModel.newGlobalVariable('newGlobalVariable',JSVariable.INTEGER); 
	myGlobalVariable.defaultValue = 12;getForms()
for (var i in forms)
		application.output(forms[i].name)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newMediagetForms-String|class=node}{tr:id=name}{td}h6.newMediagetForms{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]\[JSMedia]{span}{span:id=iets|style=float: left; font-weight: bold;}newMediagetForms{span}{span:id=iets|style=float: left;}\(name, bytesdatasource){span}{td}{tr}{tr:id=des}{td}{sub-section:newMediagetForms-String_des|text=|trigger=button}{sub-section}{sub-section:newMediagetForms-String_des|trigger=none|class=sIndent}CreatesGet aan newarray mediaof objectforms, that canare beall assignedbased to a label or a buttonon datasource/servername.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newMediagetForms-String_snc|text=|trigger=button}{sub-section}{sub-section:newMediagetForms-String_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newMediagetForms-String_prs|text=|trigger=button}{sub-section}{sub-section:newMediagetForms-String_prs|trigger=none|class=sIndent}\{[String]} namedatasource -- The name of the newdatasource media
\{byte[]} bytes -- The contentor servername
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newMediagetForms-String_ret|text=|trigger=button}{sub-section}{sub-section:newMediagetForms-String_ret|trigger=none|class=sIndent}[JSForm]\[JSMedia] -- a JSMedia object an array of JSForm type elements{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newMediagetForms-String_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMediagetForms-String_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newMediagetForms-String_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMediagetForms-String_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newMediagetForms-String_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMedia_sam|trigger=none}{code:language=javascript}
var myMedia = solutionModel.newMedia('button01.gif',bytes)
//now set the imageMedia property of your label or button
//myButton.imageMedia = myMedia
// OR
//myLabel.imageMedia = myMediagetForms-String_sam|trigger=none}{code:language=javascript}
var forms = solutionModel.getForms(datasource)
for (var i in forms)
		application.output(forms[i].name)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getForms-String_String|class=node}{tr:id=name}{td}h6.getForms{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getForms{span}{span:id=iets|style=float: left;}\(server, tablename){span}{td}{tr}{tr:id=des}{td}{sub-section:getForms-String_String_des|text=|trigger=button}{sub-section}{sub-section:getForms-String_String_des|trigger=none|class=sIndent}Get an array of forms, that are all based on datasource/servername and tablename.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getForms-String_String_snc|text=|trigger=button}{sub-section}{sub-section:getForms-String_String_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getForms-String_String_prs|text=|trigger=button}{sub-section}{sub-section:getForms-String_String_prs|trigger=none|class=sIndent}\{[String]} server -- the datasource or servername
\{[String]} tablename -- the tablename
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getForms-String_String_ret|text=|trigger=button}{sub-section}{sub-section:getForms-String_String_ret|trigger=none|class=sIndent}[JSForm]\[] -- an array of JSForm type elements{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getForms-String_String_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getForms-String_String_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getForms-String_String_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getForms-String_String_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getForms-String_String_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getForms-String_String_sam|trigger=none}{code:language=javascript}
var forms = solutionModel.getForms(datasource,tablename)
for (var i in forms)
		application.output(forms[i].name)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalMethod|class=node}{tr:id=name}{td}h6.getGlobalMethod{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethod]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalMethod{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalMethod_des|text=|trigger=button}{sub-section}{sub-section:getGlobalMethod_des|trigger=none|class=sIndent}Gets an existing global method by the specified name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalMethod_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalMethod_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalMethod_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalMethod_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the specified global method
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalMethod_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalMethod_ret|trigger=none|class=sIndent}[JSMethod] -- a JSMethod{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalMethod_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethod_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalMethod_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethod_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalMethod_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethod_sam|trigger=none}{code:language=javascript}
var method = solutionModel.getGlobalMethod("nameOfGlobalMethod"); 
	if (method != null) application.output(method.code);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalMethods|class=node}{tr:id=name}{td}h6.getGlobalMethods{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethod]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalMethods{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalMethods_des|text=|trigger=button}{sub-section}{sub-section:getGlobalMethods_des|trigger=none|class=sIndent}The list of all global methods.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalMethods_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalMethods_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalMethods_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalMethods_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalMethods_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalMethods_ret|trigger=none|class=sIndent}[JSMethod]\[] -- an array of JSMethod type elements{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalMethods_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethods_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalMethods_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethods_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalMethods_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalMethods_sam|trigger=none}{code:language=javascript}
var methods = solutionModel.getGlobalMethods(); 
	if (methods != null)
		for (var x in methods) 
			application.output(methods[x].getName());
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalVariable|class=node}{tr:id=name}{td}h6.getGlobalVariable{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSVariable]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalVariable{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalVariable_des|text=|trigger=button}{sub-section}{sub-section:getGlobalVariable_des|trigger=none|class=sIndent}Gets an existing global variable by the specified name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalVariable_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalVariable_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalVariable_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalVariable_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the global variable
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalVariable_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalVariable_ret|trigger=none|class=sIndent}[JSVariable] -- a JSVariable{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalVariable_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariable_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalVariable_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariable_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalVariable_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariable_sam|trigger=none}{code:language=javascript}
var globalVariable = solutionModel.getGlobalVariable('globalVariableName');
	application.output(globalVariable.name + " has the default value of " + globalVariable.defaultValue);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getGlobalVariables|class=node}{tr:id=name}{td}h6.getGlobalVariables{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSVariable]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getGlobalVariables{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:getGlobalVariables_des|text=|trigger=button}{sub-section}{sub-section:getGlobalVariables_des|trigger=none|class=sIndent}Gets an array of all global variables.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getGlobalVariables_snc|text=|trigger=button}{sub-section}{sub-section:getGlobalVariables_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getGlobalVariables_prs|text=|trigger=button}{sub-section}{sub-section:getGlobalVariables_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getGlobalVariables_ret|text=|trigger=button}{sub-section}{sub-section:getGlobalVariables_ret|trigger=none|class=sIndent}[JSVariable]\[] -- an array of JSVariable type elements{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getGlobalVariables_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariables_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getGlobalVariables_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariables_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getGlobalVariables_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getGlobalVariables_sam|trigger=none}{code:language=javascript}
var globalVariables = solutionModel.getGlobalVariables();
	for (var i in globalVariables)
		application.output(globalVariables[i].name + " has the default value of " + globalVariables[i].defaultValue);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getMedia|class=node}{tr:id=name}{td}h6.getMedia{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMedia]{span}{span:id=iets|style=float: left; font-weight: bold;}getMedia{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getMedia_des|text=|trigger=button}{sub-section}{sub-section:getMedia_des|trigger=none|class=sIndent}Gets the specified media object; can be assigned to a button/label.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getMedia_snc|text=|trigger=button}{sub-section}{sub-section:getMedia_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getMedia_prs|text=|trigger=button}{sub-section}{sub-section:getMedia_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the media object
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getMedia_ret|text=|trigger=button}{sub-section}{sub-section:getMedia_ret|trigger=none|class=sIndent}[JSMedia] -- a JSMedia element{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getMedia_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMedia_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getMedia_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMedia_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getMedia_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMedia_sam|trigger=none}{code:language=javascript}
var myMedia = solutionModel.getMedia('button01.gif')
//now set the imageMedia property of your label or button
//myButton.imageMedia = myMedia
// OR
//myLabel.imageMedia = myMedia
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getMediaList|class=node}{tr:id=name}{td}h6.getMediaList{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMedia]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getMediaList{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:getMediaList_des|text=|trigger=button}{sub-section}{sub-section:getMediaList_des|trigger=none|class=sIndent}Gets the list of all media objects.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getMediaList_snc|text=|trigger=button}{sub-section}{sub-section:getMediaList_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getMediaList_prs|text=|trigger=button}{sub-section}{sub-section:getMediaList_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getMediaList_ret|text=|trigger=button}{sub-section}{sub-section:getMediaList_ret|trigger=none|class=sIndent}[JSMedia]\[] -- a list with all the media objects.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getMediaList_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaList_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getMediaList_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaList_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getMediaList_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getMediaList_sam|trigger=none}{code:language=javascript}
var mediaList = solutionModel.getMediaList();
	if (mediaList.length != 0 && mediaList != null) {
		for (var x in mediaList) {
			application.output(mediaList[x]);
		}
	}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getRelation|class=node}{tr:id=name}{td}h6.getRelation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelation]{span}{span:id=iets|style=float: left; font-weight: bold;}getRelation{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getRelation_des|text=|trigger=button}{sub-section}{sub-section:getRelation_des|trigger=none|class=sIndent}Gets an existing relation by the specified name and returns a JSRelation Object.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getRelation_snc|text=|trigger=button}{sub-section}{sub-section:getRelation_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getRelation_prs|text=|trigger=button}{sub-section}{sub-section:getRelation_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the relation
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getRelation_ret|text=|trigger=button}{sub-section}{sub-section:getRelation_ret|trigger=none|class=sIndent}[JSRelation] -- a JSRelation{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getRelation_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelation_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getRelation_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelation_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getRelation_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelation_sam|trigger=none}{code:language=javascript}
var relation = solutionModel.getRelation('name');
	application.output("The primary server name is " + relation.primaryServerName);
	application.output("The primary table name is " + relation.primaryTableName); 
	application.output("The foreign table name is " + relation.foreignTableName); 
	application.output("The relation items are " + relation.getRelationItems());
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getRelations|class=node}{tr:id=name}{td}h6.getRelations{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelation]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getRelations{span}{span:id=iets|style=float: left;}\(\[primary_server_name/primary_data_source\], \[primary_table_name\]){span}{td}{tr}{tr:id=des}{td}{sub-section:getRelations_des|text=|trigger=button}{sub-section}{sub-section:getRelations_des|trigger=none|class=sIndent}Gets an array of all relations; or an array of all global relations if the specified table is NULL.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getRelations_snc|text=|trigger=button}{sub-section}{sub-section:getRelations_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getRelations_prs|text=|trigger=button}{sub-section}{sub-section:getRelations_prs|trigger=none|class=sIndent}\[primary\_server\_name/primary\_data\_source\] -- the specified name of the server or datasource for the specified table
\[primary\_table\_name\] -- the specified name of the table
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getRelations_ret|text=|trigger=button}{sub-section}{sub-section:getRelations_ret|trigger=none|class=sIndent}[JSRelation]\[] -- an array of all relations (all elements in the array are of type JSRelation){sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getRelations_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelations_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getRelations_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelations_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getRelations_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getRelations_sam|trigger=none}{code:language=javascript}
var relations = solutionModel.getRelations('server_name','table_name');
	if (relations.length != 0)
		for (var i in relations)
			application.output(relations[i].name);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getStyle|class=node}{tr:id=name}{td}h6.getStyle{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSStyle]{span}{span:id=iets|style=float: left; font-weight: bold;}getStyle{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getStyle_des|text=|trigger=button}{sub-section}{sub-section:getStyle_des|trigger=none|class=sIndent}Gets the style specified by the given name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getStyle_snc|text=|trigger=button}{sub-section}{sub-section:getStyle_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getStyle_prs|text=|trigger=button}{sub-section}{sub-section:getStyle_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the style
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getStyle_ret|text=|trigger=button}{sub-section}{sub-section:getStyle_ret|trigger=none|class=sIndent}[JSStyle] -- a JSStyle{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getStyle_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStyle_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getStyle_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStyle_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getStyle_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getStyle_sam|trigger=none}{code:language=javascript}
var style = solutionModel.getStyle('my_existing_style')
	style.content = 'combobox { color: #0000ff;font: italic 10pt "Verdana";}'
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getValueList|class=node}{tr:id=name}{td}h6.getValueList{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueList]{span}{span:id=iets|style=float: left; font-weight: bold;}getValueList{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:getValueList_des|text=|trigger=button}{sub-section}{sub-section:getValueList_des|trigger=none|class=sIndent}Gets an existing valuelist by the specified name and returns a JSValueList Object that can be assigned to a field.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getValueList_snc|text=|trigger=button}{sub-section}{sub-section:getValueList_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:getValueList_prs|text=|trigger=button}{sub-section}{sub-section:getValueList_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the valuelist
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:getValueList_ret|text=|trigger=button}{sub-section}{sub-section:getValueList_ret|trigger=none|class=sIndent}[JSValueList] -- a JSValueList object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getValueList_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueList_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getValueList_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueList_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getValueList_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueList_sam|trigger=none}{code:language=javascript}
var myValueList = solutionModel.getValueList('myValueListHere')
//now set the valueList property of your field
//myField.valuelist = myValueList
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=getValueLists|class=node}{tr:id=name}{td}h6.getValueLists{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueList]\[]{span}{span:id=iets|style=float: left; font-weight: bold;}getValueLists{span}{span:id=iets|style=float: left;}\(){span}{td}{tr}{tr:id=des}{td}{sub-section:getValueLists_des|text=|trigger=button}{sub-section}{sub-section:getValueLists_des|trigger=none|class=sIndent}Gets an array of all valuelists for the currently active solution.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:getValueLists_snc|text=|trigger=button}{sub-section}{sub-section:getValueLists_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=prs}{td}*Parameters*\\{sub-section:getValueLists_prs|text=|trigger=button}{sub-section}{sub-section:getValueLists_prs|trigger=none|class=sIndent}{sub-section}{td}{tr}{builder-show}{tr:id=ret}{td}*Returns*\\{sub-section:getValueLists_ret|text=|trigger=button}{sub-section}{sub-section:getValueLists_ret|trigger=none|class=sIndent}[JSValueList]\[] -- an array of JSValueList objects{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:getValueLists_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueLists_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:getValueLists_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueLists_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:getValueLists_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:getValueLists_sam|trigger=none}{code:language=javascript}
var valueLists = solutionModel.getValueLists();
	if (valueLists != null && valueLists.length != 0)
		for (var i in valueLists)
			application.output(valueLists[i].name);
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newCalculation-String_Number_String|class=node}{tr:id=name}{td}h6.newCalculation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSCalculation]{span}{span:id=iets|style=float: left; font-weight: bold;}newCalculation{span}{span:id=iets|style=float: left;}\(code, type, datasource){span}{td}{tr}{tr:id=des}{td}{sub-section:newCalculation-String_Number_String_des|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_Number_String_des|trigger=none|class=sIndent}Creates a new calculation for the given code and the type, if it builds on a column (name is a column name) then type will be ignored.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newCalculation-String_Number_String_snc|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_Number_String_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newCalculation-String_Number_String_prs|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_Number_String_prs|trigger=none|class=sIndent}\{[String]} code -- The code of the calculation, this must be a full function declaration.
\{[Number]} type -- The type of the calculation, one of the JSVariable types.
\{[String]} datasource -- The datasource this calculation belongs to.
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newCalculation-String_Number_String_ret|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_Number_String_ret|trigger=none|class=sIndent}[JSCalculation]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newCalculation-String_Number_String_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_Number_String_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newCalculation-String_Number_String_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_Number_String_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newCalculation-String_Number_String_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_Number_String_sam|trigger=none}{code:language=javascript}
var calc = solutionModel.newCalculation("function myCalculation() { return 123; }", JSVariable.INTEGER, "db:/example_data/customers");
var calc2 = solutionModel.newCalculation("function myCalculation2() { return '20'; }", "db:/example_data/customers");
var calc3 = solutionModel.newCalculation("function myCalculation3() { return 'Hello World!'; }",	JSVariable.TEXT, "db:/example_data/employees");

var c = solutionModel.getCalculation("myCalculation","db:/example_data/customers");
application.output("Name: " + c.getName() + ", Stored: " + c.isStored());

var allCalcs = solutionModel.getCalculations("db:/example_data/customers");
for (var i = 0; i < allCalcs.length; i++) {
	application.output(allCalcs[i]);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newCalculation-String_String|class=node}{tr:id=name}{td}h6.newCalculation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSCalculation]{span}{span:id=iets|style=float: left; font-weight: bold;}newCalculation{span}{span:id=iets|style=float: left;}\(code, datasource){span}{td}{tr}{tr:id=des}{td}{sub-section:newCalculation-String_String_des|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_String_des|trigger=none|class=sIndent}Creates a new calculation for the given code, the type will be the column where it could be build on (if name is a column name),
else it will default to JSVariable.TEXT;{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newCalculation-String_String_snc|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_String_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newCalculation-String_String_prs|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_String_prs|trigger=none|class=sIndent}\{[String]} code -- The code of the calculation, this must be a full function declaration.
\{[String]} datasource -- The datasource this calculation belongs to.
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newCalculation-String_String_ret|text=|trigger=button}{sub-section}{sub-section:newCalculation-String_String_ret|trigger=none|class=sIndent}[JSCalculation]{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newCalculation-String_String_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_String_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newCalculation-String_String_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_String_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newCalculation-String_String_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newCalculation-String_String_sam|trigger=none}{code:language=javascript}
var calc = solutionModel.newCalculation("function myCalculation() { return 123; }", JSVariable.INTEGER, "db:/example_data/customers");
var calc2 = solutionModel.newCalculation("function myCalculation2() { return '20'; }", "db:/example_data/customers");
var calc3 = solutionModel.newCalculation("function myCalculation3() { return 'Hello World!'; }",	JSVariable.TEXT, "db:/example_data/employees");

var c = solutionModel.getCalculation("myCalculation","db:/example_data/customers");
application.output("Name: " + c.getName() + ", Stored: " + c.isStored());

var allCalcs = solutionModel.getCalculations("db:/example_data/customers");
for (var i = 0; i < allCalcs.length; i++) {
	application.output(allCalcs[i]);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newForm-String_JSForm|class=node}{tr:id=name}{td}h6.newForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}newForm{span}{span:id=iets|style=float: left;}\(name, superForm){span}{td}{tr}{tr:id=des}{td}{sub-section:newForm-String_JSForm_des|text=|trigger=button}{sub-section}{sub-section:newForm-String_JSForm_des|trigger=none|class=sIndent}Creates a new form with the given JSForm as its super form.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newForm-String_JSForm_snc|text=|trigger=button}{sub-section}{sub-section:newForm-String_JSForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newForm-String_JSForm_prs|text=|trigger=button}{sub-section}{sub-section:newForm-String_JSForm_prs|trigger=none|class=sIndent}\{[String]} name -- The name of the new form
\{[JSForm]} superForm -- the super form that will extended from, see JSform.setExtendsForm();
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newForm-String_JSForm_ret|text=|trigger=button}{sub-section}{sub-section:newForm-String_JSForm_ret|trigger=none|class=sIndent}[JSForm] -- a new JSForm object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newForm-String_JSForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_JSForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newForm-String_JSForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_JSForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newForm-String_JSForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_JSForm_sam|trigger=none}{code:language=javascript}
//creates 2 forms with elements on them; shows the parent form, waits 2 seconds and shows the child form
var mySuperForm = solutionModel.newForm('mySuperForm', 'myServerName', 'myTableName', null, false, 800, 600);
var label1 = mySuperForm.newLabel('LabelName', 20, 20, 120, 30);
label1.text = 'DataProvider';
label1.background = 'red';
mySuperForm.newTextField('myDataProvider', 140, 20, 140,20);
forms['mySuperForm'].controller.show();
application.sleep(2000);
var mySubForm = solutionModel.newForm('mySubForm', mySuperForm);
var label2 = mySuperForm.newLabel('SubForm Label', 20, 120, 120, 30);
label2.background = 'green';
forms['mySuperForm'].controller.recreateUI();
forms['mySubForm'].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newForm-String_String_String_Boolean_Number_Number|class=node}{tr:id=name}{td}h6.newForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}newForm{span}{span:id=iets|style=float: left;}\(name, dataSource, styleName, show_in_menu, width, height){span}{td}{tr}{tr:id=des}{td}{sub-section:newForm-String_String_String_Boolean_Number_Number_des|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_Boolean_Number_Number_des|trigger=none|class=sIndent}Creates a new JSForm Object.

NOTE: See the JSForm node for more information about form objects that can be added to the new form.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_snc|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_Boolean_Number_Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_prs|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_Boolean_Number_Number_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the form
\{[String]} dataSource -- the specified name of the datasource for the specified table
\{[String]} styleName -- the specified style
\{[Boolean]} show_in_menu -- if true show the name of the new form in the menu; or false for not showing
\{[Number]} width -- the width of the form in pixels
\{[Number]} height -- the height of the form in pixels
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_ret|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_Boolean_Number_Number_ret|trigger=none|class=sIndent}[JSForm] -- a new JSForm object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_Boolean_Number_Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_Boolean_Number_Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newForm-String_String_String_Boolean_Number_Number_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_Boolean_Number_Number_sam|trigger=none}{code:language=javascript}
var myForm = solutionModel.newForm('newForm', 'myServer', 'myTable', 'myStyleName', false, 800, 600)
//now you can add stuff to the form (under JSForm node)
//add a label
myForm.newLabel('Name', 20, 20, 120, 30)
//add a "normal" text entry field
myForm.newTextField('dataProviderNameHere', 140, 20, 140,20)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newForm-String_String_String_String_Boolean_Number_Number|class=node}{tr:id=name}{td}h6.newForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}newForm{span}{span:id=iets|style=float: left;}\(name, serverName, tableName, styleName, show_in_menu, width, height){span}{td}{tr}{tr:id=des}{td}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_des|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_des|trigger=none|class=sIndent}Creates a new JSForm Object.

NOTE: See the JSForm node for more information about form objects that can be added to the new form.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_snc|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_prs|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the form
\{[String]} serverName -- the specified name of the server for the specified table
\{[String]} tableName -- the specified name of the table
\{[String]} styleName -- the specified style
\{[Boolean]} show_in_menu -- if true show the name of the new form in the menu; or false for not showing
\{[Number]} width -- the width of the form in pixels
\{[Number]} height -- the height of the form in pixels
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_ret|text=|trigger=button}{sub-section}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_ret|trigger=none|class=sIndent}[JSForm] -- a new JSForm object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newForm-String_String_String_String_Boolean_Number_Number_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newForm-String_String_String_String_Boolean_Number_Number_sam|trigger=none}{code:language=javascript}
var myForm = solutionModel.newForm('newForm', 'myServer', 'myTable', 'myStyleName', false, 800, 600)
//With only a datasource:
//var myForm = solutionModel.newForm('newForm', datasource, 'myStyleName', false, 800, 600)
//now you can add stuff to the form (under JSForm node)
//add a label
myForm.newLabel('Name', 20, 20, 120, 30)
//add a "normal" text entry field
myForm.newTextField('dataProviderNameHere', 140, 20, 140,20)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newGlobalMethod|class=node}{tr:id=name}{td}h6.newGlobalMethod{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMethod]{span}{span:id=iets|style=float: left; font-weight: bold;}newGlobalMethod{span}{span:id=iets|style=float: left;}\(code){span}{td}{tr}{tr:id=des}{td}{sub-section:newGlobalMethod_des|text=|trigger=button}{sub-section}{sub-section:newGlobalMethod_des|trigger=none|class=sIndent}Creates a new global method with the specified code.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newGlobalMethod_snc|text=|trigger=button}{sub-section}{sub-section:newGlobalMethod_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newGlobalMethod_prs|text=|trigger=button}{sub-section}{sub-section:newGlobalMethod_prs|trigger=none|class=sIndent}\{[String]} code -- the specified code for the global method
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newGlobalMethod_ret|text=|trigger=button}{sub-section}{sub-section:newGlobalMethod_ret|trigger=none|class=sIndent}[JSMethod] -- a JSMethod object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newGlobalMethod_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethod_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newGlobalMethod_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethod_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newGlobalMethod_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalMethod_sam|trigger=none}{code:language=javascript}
var method = solutionModel.newGlobalMethod('function myglobalmethod(){currentcontroller.newRecord()}')
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newGlobalVariable|class=node}{tr:id=name}{td}h6.newGlobalVariable{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSVariable]{span}{span:id=iets|style=float: left; font-weight: bold;}newGlobalVariable{span}{span:id=iets|style=float: left;}\(name, type){span}{td}{tr}{tr:id=des}{td}{sub-section:newGlobalVariable_des|text=|trigger=button}{sub-section}{sub-section:newGlobalVariable_des|trigger=none|class=sIndent}Creates a new global variable with the specified name and number type.

NOTE: The global variable number type is based on the value assigned from the SolutionModel\-JSVariable node; for example: JSVariable.INTEGER.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newGlobalVariable_snc|text=|trigger=button}{sub-section}{sub-section:newGlobalVariable_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newGlobalVariable_prs|text=|trigger=button}{sub-section}{sub-section:newGlobalVariable_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name for the global variable
\{[Number]} type -- the specified number type for the global variable
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newGlobalVariable_ret|text=|trigger=button}{sub-section}{sub-section:newGlobalVariable_ret|trigger=none|class=sIndent}[JSVariable] -- a JSVariable object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newGlobalVariable_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariable_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newGlobalVariable_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariable_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newGlobalVariable_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newGlobalVariable_sam|trigger=none}{code:language=javascript}
var myGlobalVariable = solutionModel.newGlobalVariable('newGlobalVariable',JSVariable.INTEGER); 
	myGlobalVariable.defaultValue = 12;
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newMedia|class=node}{tr:id=name}{td}h6.newMedia{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSMedia]{span}{span:id=iets|style=float: left; font-weight: bold;}newMedia{span}{span:id=iets|style=float: left;}\(name, bytes){span}{td}{tr}{tr:id=des}{td}{sub-section:newMedia_des|text=|trigger=button}{sub-section}{sub-section:newMedia_des|trigger=none|class=sIndent}Creates a new media object that can be assigned to a label or a button.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newMedia_snc|text=|trigger=button}{sub-section}{sub-section:newMedia_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newMedia_prs|text=|trigger=button}{sub-section}{sub-section:newMedia_prs|trigger=none|class=sIndent}\{[String]} name -- The name of the new media
\{byte[]} bytes -- The content
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newMedia_ret|text=|trigger=button}{sub-section}{sub-section:newMedia_ret|trigger=none|class=sIndent}[JSMedia] -- a JSMedia object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newMedia_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMedia_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newMedia_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMedia_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newMedia_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newMedia_sam|trigger=none}{code:language=javascript}
var myMedia = solutionModel.newMedia('button01.gif',bytes)
//now set the imageMedia property of your label or button
//myButton.imageMedia = myMedia
// OR
//myLabel.imageMedia = myMedia
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newRelation-String_String_String_Number|class=node}{tr:id=name}{td}h6.newRelation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelation]{span}{span:id=iets|style=float: left; font-weight: bold;}newRelation{span}{span:id=iets|style=float: left;}\(name, primaryDataSource, foreignDataSource, joinType){span}{td}{tr}{tr:id=des}{td}{sub-section:newRelation-String_String_String_Number_des|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_Number_des|trigger=none|class=sIndent}Creates a new JSRelation Object with a specified name; includes the primary datasource, foreign datasource and the type of join for the new relation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newRelation-String_String_String_Number_snc|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newRelation-String_String_String_Number_prs|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_Number_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the new relation
\{[String]} primaryDataSource -- the specified name of the primary datasource
\{[String]} foreignDataSource -- the specified name of the foreign datasource
\{[Number]} joinType -- the type of join for the new relation; JSRelation.INNER\_JOIN, JSRelation.LEFT\_OUTER\_JOIN
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newRelation-String_String_String_Number_ret|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_Number_ret|trigger=none|class=sIndent}[JSRelation] -- a JSRelation object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newRelation-String_String_String_Number_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newRelation-String_String_String_Number_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newRelation-String_String_String_Number_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_Number_sam|trigger=none}{code:language=javascript}
var rel = solutionModel.newRelation('myRelation','myPrimaryDataSource','myForeignDataSource',JSRelation.INNER_JOIN);
application.output(rel.getRelationItems());
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newRelation-String_String_String_String_String_Number|class=node}{tr:id=name}{td}h6.newRelation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelation]{span}{span:id=iets|style=float: left; font-weight: bold;}newRelation{span}{span:id=iets|style=float: left;}\(name, primaryServerName, primaryTableName, foreignServerName, foreignTableName, joinType){span}{td}{tr}{tr:id=des}{td}{sub-section:newRelation-String_String_String_String_String_Number_des|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_String_String_Number_des|trigger=none|class=sIndent}Creates a new JSRelation Object with a specified name; includes the primary server and table name, foreign server and table name, and the type of join for the new relation.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newRelation-String_String_String_String_String_Number_snc|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_String_String_Number_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newRelation-String_String_String_String_String_Number_prs|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_String_String_Number_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the new relation
\{[String]} primaryServerName -- the specified name of the primary server
\{[String]} primaryTableName -- the specified name of the primary table
\{[String]} foreignServerName -- the specified name of the foreign server
\{[String]} foreignTableName -- the specified name of the foreign table
\{[Number]} joinType -- the type of join for the new relation; JSRelation.INNER\_JOIN, JSRelation.LEFT\_OUTER\_JOIN
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newRelation-String_String_String_String_String_Number_ret|text=|trigger=button}{sub-section}{sub-section:newRelation-String_String_String_String_String_Number_ret|trigger=none|class=sIndent}[JSRelation] -- a JSRelation object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newRelation-String_String_String_String_String_Number_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_String_String_Number_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newRelation-String_String_String_String_String_Number_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_String_String_Number_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newRelation-String_String_String_String_String_Number_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelation-String_String_String_String_String_Number_sam|trigger=none}{code:language=javascript}
var rel = solutionModel.newRelation('myRelation','myPrimaryServerName','myPrimaryTableName','myForeignServerName','myForeignTableName',JSRelation.INNER_JOIN);
application.output(rel.getRelationItems());
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newStyle|class=node}{tr:id=name}{td}h6.newStyle{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSStyle]{span}{span:id=iets|style=float: left; font-weight: bold;}newStyle{span}{span:id=iets|style=float: left;}\(name, content){span}{td}{tr}{tr:id=des}{td}{sub-section:newStyle_des|text=|trigger=button}{sub-section}{sub-section:newStyle_des|trigger=none|class=sIndent}Creates a new style with the given css content string under the given name.

NOTE: Will throw an exception if a style with that name already exists.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newStyle_snc|text=|trigger=button}{sub-section}{sub-section:newStyle_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newStyle_prs|text=|trigger=button}{sub-section}{sub-section:newStyle_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the new style
\{[String]} content -- the css content of the new style
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newStyle_ret|text=|trigger=button}{sub-section}{sub-section:newStyle_ret|trigger=none|class=sIndent}[JSStyle] -- a JSStyle object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newStyle_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyle_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newStyle_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyle_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newStyle_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyle_sam|trigger=none}{code:language=javascript}
var form = solutionModel.newForm('myForm','myServer','myTable',null,true,1000,800);
	if (form.transparent == false)
	{
		var style = solutionModel.newStyle('myStyle','form { background-color: yellow; }');
		style.text = style.text + 'field { background-color: blue; }';
		form.styleName = 'myStyle';
	}
	var field = form.newField('columnTextDataProvider',JSField.TEXT_FIELD,100,100,100,50);
	forms['myForm'].controller.show();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newValueList|class=node}{tr:id=name}{td}h6.newValueList{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueList]{span}{span:id=iets|style=float: left; font-weight: bold;}newValueList{span}{span:id=iets|style=float: left;}\(name, type){span}{td}{tr}{tr:id=des}{td}{sub-section:newValueList_des|text=|trigger=button}{sub-section}{sub-section:newValueList_des|trigger=none|class=sIndent}Creates a new valuelist with the specified name and number type.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newValueList_snc|text=|trigger=button}{sub-section}{sub-section:newValueList_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newValueList_prs|text=|trigger=button}{sub-section}{sub-section:newValueList_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name for the valuelist
\{[Number]} type -- the specified number type for the valuelist; may be JSValueList.CUSTOM\_VALUES, JSValueList.DATABASE\_VALUES, JSValueList.EMPTY\_VALUE\_ALWAYS, JSValueList.EMPTY\_VALUE\_NEVER
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newValueList_ret|text=|trigger=button}{sub-section}{sub-section:newValueList_ret|trigger=none|class=sIndent}[JSValueList] -- a JSValueList object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newValueList_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueList_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newValueList_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueList_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newValueList_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueList_sam|trigger=none}{code:language=javascript}
var vl1 = solutionModel.newValueList("customText",JSValueList.CUSTOM_VALUES);
vl1.customValues = "customvalue1\ncustomvalue2";
var vl2 = solutionModel.newValueList("customid",JSValueList.CUSTOM_VALUES);
vl2.customValues = "customvalue1|1\ncustomvalue2|2";
var form = solutionModel.newForm("customValueListForm",controller.getDataSource(),null,true,300,300);
var combo1 = form.newComboBox("globals.text",10,10,120,20);
combo1.valuelist = vl1;
var combo2 = form.newComboBox("globals.id",10,60,120,20);
combo2.valuelist = vl2;
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeCalculation|class=node}{tr:id=name}{td}h6.removeCalculation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}removeCalculation{span}{span:id=iets|style=float: left;}\(name, datasource){span}{td}{tr}{tr:id=des}{td}{sub-section:removeCalculation_des|text=|trigger=button}{sub-section}{sub-section:removeCalculation_des|trigger=none|class=sIndent}Removes the calculation specified by name and datasource.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeCalculation_snc|text=|trigger=button}{sub-section}{sub-section:removeCalculation_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeCalculation_prs|text=|trigger=button}{sub-section}{sub-section:removeCalculation_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the calculation to be removed
\{[String]} datasource -- the datasource the calculation belongs to
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeCalculation_ret|text=|trigger=button}{sub-section}{sub-section:removeCalculation_ret|trigger=none|class=sIndent}[Boolean] -- true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeCalculation_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeCalculation_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeCalculation_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeCalculation_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeCalculation_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeCalculation_sam|trigger=none}{code:language=javascript}
var calc1 = solutionModel.newCalculation("function myCalculation1() { return 123; }", JSVariable.INTEGER, "db:/example_data/customers");
var calc2 = solutionModel.newCalculation("function myCalculation2() { return '20'; }", "db:/example_data/customers");

var c = solutionModel.getCalculation("myCalculation1", "db:/example_data/customers");
application.output("Name: " + c.getName() + ", Stored: " + c.isStored());

solutionModel.removeCalculation("myCalculation1", "db:/example_data/customers");
c = solutionModel.getCalculation("myCalculation1", "db:/example_data/customers");
if (c != null) {
		application.output("myCalculation could not be removed.");
}

var allCalcs = solutionModel.getCalculations("db:/example_data/customers");
for (var i = 0; i < allCalcs.length; i++) {
		application.output(allCalcs[i]);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeForm|class=node}{tr:id=name}{td}h6.removeForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}removeForm{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:removeForm_des|text=|trigger=button}{sub-section}{sub-section:removeForm_des|trigger=none|class=sIndent}Removes the specified form during the persistent connected client session.

NOTE: Make sure you call history.remove first in your Servoy method (script).{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeForm_snc|text=|trigger=button}{sub-section}{sub-section:removeForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeForm_prs|text=|trigger=button}{sub-section}{sub-section:removeForm_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the form to remove
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeForm_ret|text=|trigger=button}{sub-section}{sub-section:removeForm_ret|trigger=none|class=sIndent}[Boolean] -- true is form has been removed, false if form could not be removed{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeForm_sam|trigger=none}{code:language=javascript}
//first remove it from the current history, to destroy any active form instance
var success = history.removeForm('myForm')
//removes the named form from this session, please make sure you called history.remove() first
if(success)
{
	solutionModel.removeForm('myForm')
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeGlobalMethod|class=node}{tr:id=name}{td}h6.removeGlobalMethod{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}removeGlobalMethod{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:removeGlobalMethod_des|text=|trigger=button}{sub-section}{sub-section:removeGlobalMethod_des|trigger=none|class=sIndent}Removes the specified global method.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeGlobalMethod_snc|text=|trigger=button}{sub-section}{sub-section:removeGlobalMethod_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeGlobalMethod_prs|text=|trigger=button}{sub-section}{sub-section:removeGlobalMethod_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the global method to be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeGlobalMethod_ret|text=|trigger=button}{sub-section}{sub-section:removeGlobalMethod_ret|trigger=none|class=sIndent}[Boolean] -- true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeGlobalMethod_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalMethod_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeGlobalMethod_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalMethod_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeGlobalMethod_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalMethod_sam|trigger=none}{code:language=javascript}
var m1 = solutionModel.newGlobalMethod('function myglobalmethod1(){application.output("Global Method 1");}');
var m2 = solutionModel.newGlobalMethod('function myglobalmethod2(){application.output("Global Method 2");}');

var success = solutionModel.removeGlobalMethod("myglobalmethod1");
if (success == false) application.output("!!! myglobalmethod1 could not be removed !!!");

var list = solutionModel.getGlobalMethods();
for (var i = 0; i < list.length; i++) { 
		application.output(list[i].code);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeGlobalVariable|class=node}{tr:id=name}{td}h6.removeGlobalVariable{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}removeGlobalVariable{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:removeGlobalVariable_des|text=|trigger=button}{sub-section}{sub-section:removeGlobalVariable_des|trigger=none|class=sIndent}Removes the specified global variable.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeGlobalVariable_snc|text=|trigger=button}{sub-section}{sub-section:removeGlobalVariable_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeGlobalVariable_prs|text=|trigger=button}{sub-section}{sub-section:removeGlobalVariable_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the global variable to be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeGlobalVariable_ret|text=|trigger=button}{sub-section}{sub-section:removeGlobalVariable_ret|trigger=none|class=sIndent}[Boolean] -- true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeGlobalVariable_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalVariable_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeGlobalVariable_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalVariable_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeGlobalVariable_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeGlobalVariable_sam|trigger=none}{code:language=javascript}
var v1 = solutionModel.newGlobalVariable("globalVar1",JSVariable.INTEGER);
var v2 = solutionModel.newGlobalVariable("globalVar2",JSVariable.TEXT);

var success = solutionModel.removeGlobalVariable("globalVar1");
if (success == false) application.output("!!! globalVar1 could not be removed !!!");

var list = solutionModel.getGlobalVariables();
for (var i = 0; i < list.length; i++) {
		application.output(list[i].name + "[ " + list[i].variableType + "]: " + list[i].variableType);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeMedia|class=node}{tr:id=name}{td}h6.removeMedia{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[Boolean]{span}{span:id=iets|style=float: left; font-weight: bold;}removeMedia{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:removeMedia_des|text=|trigger=button}{sub-section}{sub-section:removeMedia_des|trigger=none|class=sIndent}Removes the media item specified by name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeMedia_snc|text=|trigger=button}{sub-section}{sub-section:removeMedia_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeMedia_prs|text=|trigger=button}{sub-section}{sub-section:removeMedia_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the media item to be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeMedia_ret|text=|trigger=button}{sub-section}{sub-section:removeMedia_ret|trigger=none|class=sIndent}[Boolean] -- true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeMedia_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeMedia_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeMedia_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeMedia_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeMedia_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeMedia_sam|trigger=none}{code:language=javascript}
var bytes1 = plugins.file.readFile('D:/Imgs/image1.png');
var image1 = solutionModel.newMedia('image1.png', bytes1);
var bytes2 = plugins.file.readFile('D:/Imgs/image2.jpg');
var image2 = solutionModel.newMedia('image2.jpg',bytes2);
var bytes3 = plugins.file.readFile('D:/Imgs/image3.jpg');
var image3 = solutionModel.newMedia('image3.jpg',bytes3);

var f = solutionModel.newForm("newForm",currentcontroller.getDataSource(),null,false,500,350);
var l = f.newLabel('', 20, 70, 300, 200);
l.imageMedia = image1;
l.borderType =  solutionModel.createLineBorder(4,'#ff0000');
forms["newForm"].controller.show();

var status = solutionModel.removeMedia('image1.jpg');
if (status) application.output("image1.png has been removed");
else application.output("image1.png has not been removed");

var mediaList = solutionModel.getMediaList();
for (var i = 0; i < mediaList.length; i++) {
		application.output(mediaList[i].getName() + ":" + mediaList[i].mimeType);
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newRelationremoveRelation|class=node}{tr:id=name}{td}h6.newRelationremoveRelation{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSRelationBoolean]{span}{span:id=iets|style=float: left; font-weight: bold;}newRelationremoveRelation{span}{span:id=iets|style=float: left;}\(name, primary_server_name|primary_data_source, \[primary_table_name\], foreign_server_name|foreign_data_source, \[foreign_table_name\], join_type){span}{td}{tr}{tr:id=des}{td}{sub-section:newRelationremoveRelation_des|text=|trigger=button}{sub-section}{sub-section:newRelationremoveRelation_des|trigger=none|class=sIndent}Creates a new JSRelation Object with a specified name; includesRemoves the primaryrelation datasource, optional table name, foreign datasource, optional foreign table name, and the type of join for the new relationspecified by name.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newRelationremoveRelation_snc|text=|trigger=button}{sub-section}{sub-section:newRelationremoveRelation_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newRelationremoveRelation_prs|text=|trigger=button}{sub-section}{sub-section:newRelationremoveRelation_prs|trigger=none|class=sIndent}name -- the specified name of the new relation
primary_server_name|primary_data_source -- the specified name of the primary server or datasource
\[primary\_table\_name\] -- the specified name of the primary table
foreign_server_name|foreign_data_source -- the specified name of the foreign server or datasource
\[foreign\_table\_name\] -- the specified name of the foreign table
join_type\{[String]} name -- the typename of join for the newrelation relation; JSRelation.INNER\_JOIN, JSRelation.LEFT\_OUTER\_JOINto be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newRelationremoveRelation_ret|text=|trigger=button}{sub-section}{sub-section:newRelationremoveRelation_ret|trigger=none|class=sIndent}[JSRelationBoolean] -- a JSRelation object true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newRelationremoveRelation_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelationremoveRelation_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newRelationremoveRelation_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelationremoveRelation_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newRelationremoveRelation_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newRelationremoveRelation_sam|trigger=none}{code:language=javascript}
var relsuccess = solutionModel.newRelationremoveRelation('myRelation','myPrimaryServerName','myPrimaryTableName','myForeignServerName','myForeignTableName',JSRelation.INNER_JOIN);
if (success) { application.output(rel.getRelationItems());"Relation has been removed");}
else {application.output("Relation could not be removed");}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newStyleremoveStyle|class=node}{tr:id=name}{td}h6.newStyleremoveStyle{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSStyleBoolean]{span}{span:id=iets|style=float: left; font-weight: bold;}newStyleremoveStyle{span}{span:id=iets|style=float: left;}\(name, content){span}{td}{tr}{tr:id=des}{td}{sub-section:newStyleremoveStyle_des|text=|trigger=button}{sub-section}{sub-section:newStyleremoveStyle_des|trigger=none|class=sIndent}Creates a new style with the given css content string under the given name.

NOTE: Will throw an exception if a style with that name already existsclass=sIndent}Removes the specified style.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newStyleremoveStyle_snc|text=|trigger=button}{sub-section}{sub-section:newStyleremoveStyle_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newStyleremoveStyle_prs|text=|trigger=button}{sub-section}{sub-section:newStyleremoveStyle_prs|trigger=none|class=sIndent}\{[String]} name -- the name of the new style \{[String]} content -- the css content of the new styleto be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newStyleremoveStyle_ret|text=|trigger=button}{sub-section}{sub-section:newStyleremoveStyle_ret|trigger=none|class=sIndent}[JSStyleBoolean] -- a JSStyle object true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newStyleremoveStyle_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyleremoveStyle_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newStyleremoveStyle_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyleremoveStyle_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newStyleremoveStyle_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newStyleremoveStyle_sam|trigger=none}{code:language=javascript}
var forms = solutionModel.newForm('myForm','myServer','myTable',null,true,1000,800);
	if (form.transparent == false)
	{
		var style = solutionModel.newStyle('myStyle'newStyle("smStyle1",'form { background-color: yellow; }');
		style.text = style.text + 'field { background-color: blue; }';
		form.styleName = 'myStyle';
	}
	var field = form.newField('columnTextDataProvider',JSField.TEXT_FIELD,100,100,100,50);
	forms['myForm'].controller.show(var status = solutionModel.removeStyle("smStyle1");
if (status == false) application.output("Could not remove style.");
else application.output("Style removed.");
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=newValueListremoveValueList|class=node}{tr:id=name}{td}h6.newValueListremoveValueList{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSValueListBoolean]{span}{span:id=iets|style=float: left; font-weight: bold;}newValueListremoveValueList{span}{span:id=iets|style=float: left;}\(name, type){span}{td}{tr}{tr:id=des}{td}{sub-section:newValueListremoveValueList_des|text=|trigger=button}{sub-section}{sub-section:newValueListremoveValueList_des|trigger=none|class=sIndent}Creates a new valuelist with Removes the specified name and number typevaluelist.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:newValueListremoveValueList_snc|text=|trigger=button}{sub-section}{sub-section:newValueListremoveValueList_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:newValueListremoveValueList_prs|text=|trigger=button}{sub-section}{sub-section:newValueListremoveValueList_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name forof the valuelist \{[Number]} type -- the specified number type for the valuelist; may be JSValueList.CUSTOM\_VALUES, JSValueList.DATABASE\_VALUES, JSValueList.EMPTY\_VALUE\_ALWAYS, JSValueList.EMPTY\_VALUE\_NEVER
to be removed
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:newValueListremoveValueList_ret|text=|trigger=button}{sub-section}{sub-section:newValueListremoveValueList_ret|trigger=none|class=sIndent}[JSValueListBoolean] -- a JSValueList object true if the removal was successful, false otherwise{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:newValueListremoveValueList_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueListremoveValueList_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:newValueListremoveValueList_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueListremoveValueList_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:newValueListremoveValueList_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:newValueListremoveValueList_sam|trigger=none}{code:language=javascript}
var vlName = "customValueList";
var vl1vl = solutionModel.newValueList("customText"vlName,JSValueList.CUSTOM_VALUES);
vl1vl.customValues = "customvalue1\ncustomvalue2";

var vl2status = solutionModel.newValueList("customid",JSValueList.CUSTOM_VALUES);
vl2.customValues = "customvalue1|1\ncustomvalue2|2";
var form.removeValueList(vlName);
if (status) application.output("Removal has been done.");
else application.output("ValueList not removed.");

var vls = solutionModel.newForm("customValueListForm",controller.getDataSource(),null,true,300,300);
var combo1 = form.newComboBox("globals.text",10,10,120,20);
combo1.valuelist = vl1;
var combo2 = form.newComboBox("globals.id",10,60,120,20);
combo2.valuelist = vl2;getValueLists();
if (vls != null) {
	for (var i = 0; i < vls.length; i++) {
		application.output(vls[i]);
	}
	application.output("");
}
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=removeFormrevertForm|class=node}{tr:id=name}{td}h6.removeFormrevertForm{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[BooleanJSForm]{span}{span:id=iets|style=float: left; font-weight: bold;}removeFormrevertForm{span}{span:id=iets|style=float: left;}\(name){span}{td}{tr}{tr:id=des}{td}{sub-section:removeFormrevertForm_des|text=|trigger=button}{sub-section}{sub-section:removeFormrevertForm_des|trigger=none|class=sIndent}RemovesReverts the specified form to the original (blueprint) version of the form during the persistent connected client session; will result in an exception error if the form is not an original form.

NOTE: Make sure you call history.remove first in your Servoy method (script) or call form.controller.recreateUI() before the script ends.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:removeFormrevertForm_snc|text=|trigger=button}{sub-section}{sub-section:removeFormrevertForm_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:removeFormrevertForm_prs|text=|trigger=button}{sub-section}{sub-section:removeFormrevertForm_prs|trigger=none|class=sIndent}\{[String]} name -- the specified name of the form to removerevert
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:removeFormrevertForm_ret|text=|trigger=button}{sub-section}{sub-section:removeFormrevertForm_ret|trigger=none|class=sIndent}[BooleanJSForm] -- truea is form has been removed, false if form could not be removedJSForm object{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:removeFormrevertForm_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeFormrevertForm_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:removeFormrevertForm_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeFormrevertForm_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:removeFormrevertForm_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:removeFormrevertForm_sam|trigger=none}{code:language=javascript}
//first revert removethe itform fromto the current history, to destroy any active form instance
var success = history.removeFormoriginal solution form, removing any changes done to it through the solution model.
 var revertedForm = solutionModel.revertForm('myForm')
 //removes the named form from this session, please add a label on a random place.
 revertedForm.newLabel("MyLabel",Math.random()*100,Math.random()*100,80,20);
 // make sure that the youui called history.remove() first
if(success)
{
	solutionModel.removeForm('myForm')
}is up to date.
 forms.myForm.controller.recreateUI();
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{tbody:id=revertFormwrapMethodWithArguments|class=node}{tr:id=name}{td}h6.revertFormwrapMethodWithArguments{td}{tr}{tr:id=sig}{td}{span:style=float: left; margin-right: 5px;}[JSFormJSMethod]{span}{span:id=iets|style=float: left; font-weight: bold;}revertFormwrapMethodWithArguments{span}{span:id=iets|style=float: left;}\(namemethod, args){span}{td}{tr}{tr:id=des}{td}{sub-section:revertFormwrapMethodWithArguments_des|text=|trigger=button}{sub-section}{sub-section:revertForm_des|trigger=none|class=sIndent}Reverts the specified form to the original (blueprint) version of the form; will result in an exception error if the form is not an original form.

NOTE: Make sure you call history.remove first in your Servoy method (script) or call form.controller.recreateUI() before the script endssection}{sub-section:wrapMethodWithArguments_des|trigger=none|class=sIndent}Get a JSMethod instance with arguments to be assigned to an event.{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=snc}{td}*Since*\\{sub-section:revertFormwrapMethodWithArguments_snc|text=|trigger=button}{sub-section}{sub-section:revertFormwrapMethodWithArguments_snc|trigger=none|class=sIndent} Replace with version info{sub-section}{td}{tr}{builder-show}{tr:id=prs}{td}*Parameters*\\{sub-section:revertFormwrapMethodWithArguments_prs|text=|trigger=button}{sub-section}{sub-section:revertFormwrapMethodWithArguments_prs|trigger=none|class=sIndent}\{[StringJSMethod]} namemethod -- the specified name of the form to revert JSMethod to be assigned to an event
\{[Object]\[]} args -- positional arguments
{sub-section}{td}{tr}{tr:id=ret}{td}*Returns*\\{sub-section:revertFormwrapMethodWithArguments_ret|text=|trigger=button}{sub-section}{sub-section:revertFormwrapMethodWithArguments_ret|trigger=none|class=sIndent}[JSFormJSMethod] -- a JSForm objectJSMethod{sub-section}{td}{tr}{builder-show:permission=edit}{tr:id=see}{td}*Also see*\\{sub-section:revertFormwrapMethodWithArguments_see|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:revertFormwrapMethodWithArguments_see|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{builder-show:permission=edit}{tr:id=link}{td}*External links*\\{sub-section:revertFormwrapMethodWithArguments_link|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:revertFormwrapMethodWithArguments_link|trigger=none}{sub-section}{div}{td}{tr}{builder-show}{tr:id=sam}{td}*Sample*\\{sub-section:revertFormwrapMethodWithArguments_sam|text=|trigger=button}{sub-section}{div:class=sIndent}{sub-section:revertFormwrapMethodWithArguments_sam|trigger=none}{code:language=javascript}
// revert the form to the original solution form, removing any changes done to it through the solution model.
 var revertedForm = solutionModel.revertForm('myForm')
 // add a label on a random place.
 revertedForm.newLabel("MyLabel",Math.random()*100,Math.random()*100,80,20);
 // make sure that the ui is up to date.
 forms.myForm.controller.recreateUI();:language=javascript}
var str = "John's Bookstore"
var form = solutionModel.getForm('orders')
var button = form.getButton('abutton')
var method = form.getFormMethod('doit') // has 4 arguments: event (fixed), boolean, number and string
// string arguments have to be quoted, they are interpreted before the method is called
var quotedString = "'"+utils.stringReplace(str, "'", "\\'")+"'"
// list all arguments the method has, use nulls for fixed arguments (like event)
button.onAction = solutionModel.wrapMethodWithArguments(method, null, true, 42, quotedString)
{code}{sub-section}{div}{td}{tr}{tr:class=lastDetailRow}{td}{td}{tr}{tbody}{table}