ASP.NET Tree_DB - Methods

Tree_DB; CField; FieldCollection;


Tree_DB

Name Description
propertyTestConnection() Tests if the connection to the database was set up correctly. Optional
Returns a string with the error message (if any), otherwise it returns "Connection is OK"
string sMessage = oTreeDB.TestConnection();
 
propertyExecuteEvent() Executes the selected action with the specified data, depending on this.EventType property
This method returns 1 if the operation was successful

Example:
string sResult = oTreeDB.ExecuteEvent();
 
propertyExecuteEvent(EventTypes eventtype) Executes the selected action with the specified data, depending on argument eventtype.
  1. Add node: EventTypes.Add
  2. Edit node: EventTypes.Edit
  3. Remove node: EventTypes.Remove
  4. Update level: EventTypes.UpdateLevel
  5. Move node: EventTypes.MoveNode
This method returns 1 if the operation was successful

Example:
string sResult = oTreeDB.ExecuteEvent(EventTypes.Add);
 

CField

Name Description
propertySetProperties(string dbFieldName, string dbFieldType) Set DbFieldName and DbFieldType property of additional data. Optional

Example:
oTreeDB.Fields["Address"].SetProperties("Address", "text");
oTreeDB.Fields[TreeDB.StandardFields.ID].SetProperties("NodeID", "numeric");
 

FieldCollection

Name Description
propertyAdd(string FieldName, string FieldType) Add additional data field. Optional

Example:
oTreeDB.Fields.Add(Address", "text");
 
propertyAdd(string FieldName, string FieldType, string Data) Add additional data field. Optional

Example:
oTreeDB.Fields.Add(Address", "text", address);