GetErrorMessage

GetErrorMessage returns any formated error string if available.
unsigned int GetErrorMessage (
	char16_t **message
);

Parameters

message An address of a pointer to receive the pointer to the error message.

Return Values

If the method succeeds, the return value is zero else see error codes for more details.

Remarks

  • ObjectDatabase++ deletes any memory used in this method, do not call delete [] after this method has been called.
Example Use
#define FIRST_TABLE 1
unsinged int error;
CODBPP database
char16_t *message;
if((error = database.OpenDatabase(TEXT("YourDatabase"))) == NO_ERROR
&& (error = database.BeginTransaction()) == NO_ERROR
&& (error = database.OpenTable(FIRST_TABLE)) == NO_ERROR
&& (error = database.NewObject(FIRST_TABLE)) == NO_ERROR//Adds an empty object into the table
&& (error = database.AddObject(FIRST_TABLE)) == NO_ERROR)
   error = database.CommitTransacion();
if(error && database.GetErrorMessage(&message) == NO_ERROR)
   MessageBox(message);
database.CloseDatabase();//will end transaction, close tables and release all memory

Also See

 

Contact Ekky Software

All around the world Ekky Software is contactable seven days of the week by submitting the following details.

Thank you for your time and interest.
Ekky Software Customer Support Team.

Ekky Software Product Range
Ekky Software Homepage Texas Business Software ObjectDatabase++ TScript Ekky Software Homepage Texas Business Software ObjectDatabase++ TScript