Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- SoftC Database Library v2.1 Guide - usage http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
USAGE
   int scdwrget(
           int handle,
           long recno,
           char **data );

PROTOTYPE IN
   sc_base.h

DESCRIPTION
   scdwrget reads the desired record recno from the memo file
   specified by handle. A buffer large enough to hold the text will be
   allocated, the address of which is returned in data.

RETURN VALUES
  SC_SUCCESS   memo record read successfully
  SC_RDFAIL    file read failure
  SC_MEMERR    memory allocation error
  SC_SKFAIL    file pointer reposition failed
  SC_BADHNDL   invalid handle number
  SC_NULLPARM  parameter address NULL

EXAMPLE
   #include <stdio.h>
   #include <softc.h>
   #include <sc_base.h>

   void main()
   {
     int fpt;
     char *data;

     scdinit(20,0);
     if (scdwopenx(&fpt,"TOC.FPT",SC_SHARED) == SC_SUCCESS) {
       scdwrget(fpt,1L,&data);
       puts(data);
       free(data);
       scddclose(fpt);
     }
     scdterm();
   }

See Also: scdwrget

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson