VWriteMenutreeFile
Name
VWriteMenutreeFile - writes the command tree structure to TREEINFO.COM file.
Synopsis
VWriteMenutreeFile(treeinfo, num_of_treeinfo)
TreeInfo *treeinfo;
short num_of_treeinfo;
Description
VWriteMenutreeFile writes the command tree structure to TREEINFO.COM file.
Structures
typedef struct {
char cmd[30]; /*the current command selected*/
char function[30]; /*the current function selected*/
char process[30]; /*the current process being executed*/
char filetype[100]; /*the types of files to be read*/
short father; /*the father fo the current process*/
short sibling; /*the first sibling of the current process*/
short son; /*the first child of the current process*/
short x,y; /*the top-left cood of the current command*/
short terminal_leaf_node;/*terminal node(1) or not(0)*/
} TreeInfo;
Return Value
0 - work successfully.
3 - write error.
4 - file open error.
Parameters
treeinfo - the array that contains the command tree structure.
num_of_treeinfo - the number of elements in treeinfo.
Side Effects
None.
Entry Conditions
If treeinfo is NULL, VWriteMenutreeFile prints an error message to the
standard error stream, produces a core dump file and exits from the
current process.
Related Functions
None.