Contenido principal

deleteDocumentAttribute

R2026b

Delete document attributes in spreadsheet in Safety Analysis Manager

Since R2023b

Description

deleteDocumentAttribute(spreadsheet,property) deletes the document attribute that has the property, property, from the spreadsheet in the Safety Analysis Manager, spreadsheet.

example

deleteDocumentAttribute(faultTreeDocument,property) deletes the document attribute from the Safety Analysis Manager fault tree document, faultTreeDocument. (since R2026b)

Examples

collapse all

Create a new spreadsheet in the Safety Analysis Manager.

mySpreadsheet = safetyAnalysisMgr.newSpreadsheet;

Add three document attributes to the spreadsheet by using the addDocumentAttribute function.

addDocumentAttribute(mySpreadsheet,property="myAttribute1",value="1")
addDocumentAttribute(mySpreadsheet,property="myAttribute2",value="2")
addDocumentAttribute(mySpreadsheet,property="myAttribute3",value="3")

Delete the attribute with the property, myAttribute1.

deleteDocumentAttribute(mySpreadsheet,"myAttribute1")

Since R2026b

Create a new fault tree document in the Safety Analysis Manager.

myFaultTreeDoc = safetyAnalysisMgr.newDocument("fault-tree");

Add three document attributes to the fault tree document by using the addDocumentAttribute function.

addDocumentAttribute(myFaultTreeDoc,property="myAttribute1",value="1")
addDocumentAttribute(myFaultTreeDoc,property="myAttribute2",value="2")
addDocumentAttribute(myFaultTreeDoc,property="myAttribute3",value="3")

Delete the attribute with the property, myAttribute1.

deleteDocumentAttribute(myFaultTreeDoc,"myAttribute1")

Input Arguments

collapse all

Spreadsheet in the Safety Analysis Manager, specified as a Spreadsheet object.

Fault tree document in the Safety Analysis Manager, specified as a FaultTreeDocument object.

Property of the document attribute, specified as a string scalar or character vector. The argument must be an exact match.

Data Types: char | string

Version History

Introduced in R2023b

expand all