Example:
var aspose = aspose || {};
aspose.diagram = require("aspose.diagram");
diagram = new aspose.diagram.Diagram("TextBoxes.vsdx");
// get page by name
page = diagram.getPages().getPage("Page-1");
// get shape by id
shape = page.getShapes().getShape(2);
// initialize user object
user = new aspose.diagram.User();
user.setName("UserDefineCell");
user.getValue().setVal("800");
// add user-defined cell
shape.getUsers().add(user);
diagram.save("out-CreateUserDefinedCellInShapeSheet.vsdx", aspose.diagram.SaveFileFormat.VSDX);
| Constructor Summary |
|---|
User()
Constructor. |
| Property Getters/Setters Summary | ||
|---|---|---|
method | getDel() | |
method | setDel(value) | |
| A flag indicating whether the element has been deleted locally. A value of 1 indicates that the element was deleted locally. The value of the property is BOOL integer constant. | ||
method | getID() | |
method | setID(value) | |
| The unique ID of the element within its parent element. | ||
method | getName() | |
method | setName(value) | |
| The name of the element. | ||
method | getNameU() | |
method | setNameU(value) | |
| The universal name of the element. | ||
method | getPrompt() | |
method | setPrompt(value) | |
| It specifies a descriptive prompt or comment for the user-defined element. | ||
method | getValue() | |
method | setValue(value) | |
| Contains solution-specific, well-formed XML data that is prefixed in an explicit namespace and is stored with a document. | ||
| Method Summary | ||
|---|---|---|
method | deepClone() | |
Creates deep copy of this instance.
|
||
Value getValue() / setValue(value)
String getName() / setName(value)
String getNameU() / setNameU(value)
int getID() / setID(value)
int getDel() / setDel(value)
Str2Value getPrompt() / setPrompt(value)