cancelSaveDefect

Unlocks a defect record locked by editDefect or editDefectByRecordID. Does not need to be called if saveDefect is successful. A SOAP error envelope is returned if the operation fails.

Parameters

Parameter Type Description
cookie long Session cookie returned by projectLogon.
recordID long Unique defect record ID.

Return value

Value Type Notes
result int 0 indicates success. Check the return value in case of an error.

Example

CDefect def = ttsdk.editDefect(cookie, 0, "Defect summary", false);

 

try

{

def.enteredby = "User, Invalid";

 

// The following line throws an exception because enteredby is not set as a valid user string.

ttsdk.saveDefect(cookie, def);

}

catch (Exception e)

{

ttsdk.cancelSaveDefect(cookie, def.recordid);

}