Page 1 of 1

PostPosted: Fri Jan 02, 2004 6:30 pm
by Eli
In the documentation there is a reference to a FaddItem function used to append single elements to a list.

"FaddItem(int Id, string item) { FaddList(Id,1,&item); }"

When i try entering the function is does not recognize the command as a valid command. I am using the latest version of the libraries. What am i missing?

Thanks




Eli

PostPosted: Fri Jan 02, 2004 6:44 pm
by jstadolnik
<blockquote id="quote"><font size="1" face="Verdana, Arial, Helvetica" id="quote">quote:<hr height="1" noshade id="quote">
"FaddItem(int Id, string item) { FaddList(Id,1,&item); }"

When i try entering the function is does not recognize the command as a valid command. I am using the latest version of the libraries. What am i missing?
<hr height="1" noshade id="quote"></blockquote id="quote"></font id="quote">

FaddItem is not a PToolbox function, but rather a user defined function which uses the FaddList() PToolbox call.

If you want to use the FaddItem() function as listed in the documention, you have to define the function in your code, by adding the following:

int FaddItem(int Id, string item) {
FaddList(Id,1,&item);
}

OR for short:

FaddItem(int Id, string item) { FaddList(Id,1,&item); }


Note the above are function definitions. The initial int is optional.

Joe



The PToolboxLib guy.
http://www.geocities.com/retro_01775/PToolboxLib.htm

PostPosted: Fri Jan 02, 2004 6:49 pm
by Eli
Of course. Sorry i missed that completely.

Thanks a mill

Eli