[Previous] [Contents] [Index] [Next]

ApSaveDBaseFile()

Save a widget database as an external file

Synopsis:

#include <Ap.h>

int ApSaveDBaseFile( ApDBase_t const *db,
                     char const *path );

Description:

ApSaveDBaseFile() saves a widget database as an external file. Both internally bound widget databases and previously loaded external widget databases can be saved as external files.

Returns:

0
Successful completion
-1
Failure

Examples:

/* Open a PhAB picture database, delete my_icon, 
   and save the database again. */
ApDBase_t        *my_dbase;

my_dbase = ApOpenDBaseFile( "/home/me/mydbase.wgtp" );

ApDeleteWidget( my_dbase, "my_icon" );

ApSaveDBaseFile( my_dbase, "/home/me/mydbase.wgtp" );

Classification:

Photon

Safety:
Interrupt handler No
Signal handler No
Thread No

See also:

ApCloseDBase(), ApCopyWidget(), ApDeleteWidget(), ApOpenDBase(), ApOpenDBaseFile()

Accessing PhAB Modules from Code chapter of the Photon Programmer's Guide


[Previous] [Contents] [Index] [Next]