This section provides examples for the HTTP Client for ActiveX using Visual Basic.
The following shows the main dialog of the sampleVBXML TaminoX executable on initial execution. All operations are checked for error and if an error is detected the corresponding error message is displayed.
The command buttons on the dialog perform the following operations:
Command | Description |
---|---|
Sets the Tamino database URL and collection (e.g.
http://localhost/tamino/mydb/ino:etc). This is used to set the
property csDatabaseURL .
|
|
Hex Big Chars | Option that, if selected, causes response XML documents that have non-printing characters to be output as hex values. |
Clears the results text box. | |
Performs a
TaminoX.GetVersion() operation and displays the
result.
|
|
Performs a
TaminoX.Ping() operation and displays the
result.
|
|
Performs a
TaminoX.Echo() operation and displays the
result.
|
|
Performs a
TaminoX.StartSession() operation and displays the
result. Note that StartSession calls may not be
nested – try it and see the error!
|
|
Performs a
TaminoX.Commit() operation and displays the result.
Note that a previous StartSession is required – try
it and see the error!
|
|
Performs a
TaminoX.Rollback() operation and displays the result.
Note that a previous StartSession is required – try
it and see the error!
|
|
Performs a
TaminoX.EndSession() operation and displays the
result. Note that a previous StartSession is
required – try it and see the error!
|
|
Performs a
TaminoX.PutDocument() operation and displays the
resulting HTTP headers (see GetDocument below).
Inserts a document into the database.
|
|
Performs a
TaminoX.GetDocument() operation and displays the
result. Gets a document from the database. The document type and name should
correspond to the preceding PutDocument (or a known
document in the database). This means that the ino:id (@n ) should
match a preceding PutDocument X-INO-id HTTP header
value.
|
|
Performs a
TaminoX.DoQuery( ) operation followed by a
ReturnNodes operation and displays the node
values.
|
|
Performs a
TaminoX.XQuery() operation and displays the node
values.
|
The following shows the main dialog of the sampleVBNonXML TaminoNonXml
executable on initial execution. All operations are checked for error and if an
error is detected the corresponding error message is displayed. Note that to be
able to use the BIN/BIN
collection/doctype the programmer must
first define the schema given in bin-schema.tsd.
The command buttons on the dialog perform the following operations:
Command | Description |
---|---|
Tamino base Url and | Sets the Tamino database base URL (e.g. http://localhost/tamino/mydb). This is combined with the relative URL to produce an absolute URL to specify the non-XML document to be used.Use the | button when changing the base URL.
Tamino relative Url | Relative URL combined with the base URL to fully specify the non-XML document to be used. |
Uploads the user specified document to “base URL/relative URL”. The user specified document is obtained via a file browsing dialog. | |
Downloads "base URL/relative URL" to the user specified document. The user specified document is obtained via a file browsing dialog. | |
Starts a transactional session. | |
Commits all processed commands. | |
Rolls back all processed commands. | |
Ends a transactional session. |