I need to create 3 new Items, during my script work, and additional question is how to set required fields, if they are exist on my default submit transition???
Accepted AnswerMichaelOffline0Should be fairly straight forward:
Set scrRec = Ext.CreateAppRecord(Ext.tableID("Your Primary Table name here"))
'set PROJECT DEFAULTS
Call scrRec.SetFieldValue("OWNER", projectDefaultOwner)
' set ALL MANDATORY FIELDS
Call scrRec.SetFieldValue("MANDATORY1", someValidValue)
' if you need to internal id for that new item
returnSCR = scrRec.GetID()
' In my script I have also the following lines
the trickier part is to determine VALID default values for the required fields depending on the project you want to submit into, you can read the ts_properties table for that
' Build an App Record To the Properties table, And search it to find the default value for
' the Field we are searching for, for the given Project we are currently In
' make sure transition id = 0
' Field id can be retrieved from ts_fields
Set apprecord = Ext.CreateAppRecord(Ext.TableID("TS_PROPERTIES"))
whereclause = "TS_FLDID = " & fieldID & " And TS_PROJECTID = " & dest_project & " And TS_TRANSID = 0"
If apprecord.ReadWithWhere(whereclause) Then
' for fields that are of base type integer (all internal ids, etc.)
Call apprecord.GetFieldValue("INTVAL", defValue)
you may want to refer to the data dictionary sbm_schema_doc.pdf for further information.
Accepted AnswerSmith SmithOffline-1Title and Description copied from Widget Change Request • Item Type to Task • Task Owner to the Asse.. ... Submit Date to now ... in the Assessors multi-user ' field and create a new Task item in the Issues table the assessor. Mount the volume once, then open System Preferences->Accounts->Login Items and drag ... Send iMessages from the Finder · Quick Look with a three-finger tap ... visit college paper writing service