Click to open or copy the files for the Admndemo sample.
This sample has the following parts:
File | Description |
Admndemo.c | Contains the main interface modules for SATOOL, including the MDI client support. |
Child.h | Defines the CHILDINFO type, which is the main data structure for a connection window. |
Dialogs.c | Contains the dialog procedures which are used to display catalog function arguments and display the results. Note that the best way to determine the size of the arguments would be to use SQLGetInfo; however, to simplify the coding, the values are hard-coded as constants. |
Dialogs.h | Contains all of the constant definitions for the dialog boxes used for the lists. |
Errcheck.c | Contains common error checking functions. |
Execute.c | Contains the code to execute SQL statements and display them. This file is dependent on the SA Tool data structures and the independent module RESULTS. |
Execute.h | Contains the prototypes and defines for executing SQL statements and displaying their results. |
Info.c | Contains the functions which handle the Info menu items. This module relies on RESULTS and EXECUTE. This file contains the actual code to execute SQL statements and display them. This file is dependent on the SA Tool data structures and the independent module RESULTS. |
Info.h | Contains the functions which handle the Info menu items. |
Ini.c | Contains the functions which work with SAtool.ini. |
Menu.c | Takes care of enabling and disabling menus. |
Menu.h | Contains menu IDs. |
Results.c | Contains functions that allow you to view results via an owner-drawn list box. The list box functionality makes it easy to implement pipes, but it has some serious drawbacks with record limits, storage methods, etc. If you need a great way to paint data in a grid, see the C++ or Cursor Demo samples that came with this SDK. |
Standard.c | Contains standard functions, which can be used by many different tools. The DumpDebugInfo function, when enabled, will cause all memory requests and frees to be written to a comma-separated file. You can then query this file via the sample Text ODBC Driver to find memory problems. |
Standard.h | Contains standard includes that are required by many modules. This include file is not specific for any tool. If using this file for a DLL, #define STANDARD_DLL, otherwise it is assumed that it is being used for a Windows application. |
Strings.h | Contains the defines for the string table error and information messages. Load these strings using the GetidsString function. |
This sample uses the following keywords:
_based; _fmemset; _fstrcat; _fstrchr; _fstrstr; _lclose; _llseek; _lopen; _lread; _lwrite; _segname; _vsnprintf; aboutwndproc; abs; addresultsinfonode; addrowdata; allocaterowdata; atoi; beginpaint; bintochar; bit32_item; bitclear; bitflip; bitget; bitset; busy; catalogwndproc; centerdialog; checkdisplaymode; checkdlgbutton; checkforresults; checkradiobutton; childwndproc; chknull; choosefont; cleanup; connect; convertsqltypetochar; createfontindirect; createresultsfont; createresultsset; createresultswindow; createwindow; dcseg; debugaddr; debuggetmemory; debugmsg; debugreleasememory; defframeproc; defmdichildproc; deleteobject; destroyresultswindow; destroywindow; dex32_item; dialogboxparam; disconnect; dispatchmessage; displayabout; displayerrors; displaygetinfo; displayodbcdatasources; displayodbcdatatypes; displayodbcfunctions; docatalogfunction; doclosedown; docommitrollback; doconnect; dodisconnect; dofileopen; dofilesave; dofilesaveas; dogetmemory; dolist; domain; dopipe; dopipebyvalue; dopipewndproc; doposterror; doreleasememory; drawcolumntitles; drawfocusrect; drawrow; drawrowdata; dumpdebuginfo; editpipe; editpipewndproc; enablemenuitem; enablewindow; enddialog; endpaint; executecmds; executefile; executefilewndproc; exttextout; fetchallrecordstoresults; fillrect; findrightcol; findterminator; freeconnectwindowresults; freeresultsset; freerowdata; get_wm_command_id; getactivewindow; getbitval; getcipointer; getclientrect; getconndex; getconnectwindowresultsnode; getdc; getdefaultfont; getdefaultrgb; getdlgitem; getdlgitemtext; geteditwindow; getfocus; getfontstyle; getidsstring; getindexval; getmemory; getmenunum; getmessage; getnewdirectory; getnumresultscols; getopenfilename; getparent; getpipenames; getprivateprofileint; getprivateprofilestring; getradiovalue; getrwpointer; getsavefilename; getscrollpos; getsqlstate; getstockobject; getsubmenu; getsyscolor; getsystemmetrics; gettext; gettextextentpoint; gettextmetrics; gettypename; getwindow; getwindowlong; getwindowrect; getwindowsdirectory; getwindowtext; globalallocptr; globalfreeptr; globalptrhandle; globalsize; handlehscroll; handlepipe; handlevirtualhscroll; iloadstring; info_value_row; inforow; int16_item; int32_item; internaldestroyresultswindow; invalidaterect; isclipboardformatavailable; isdlgbuttonchecked; isradiobuttonon; isvalidparms; iszoomed; lineto; loadaccelerators; loadcursor; loadicon; loadmenu; loadstring; localtime; lpatoi; lstrcat; lstrcmp; lstrcmpi; lstrcpy; lstrlen; makeintresource; makelong; makelparam; max; memcpy; memmove; memset; messagebox; min; minrequiredints; moveto; movetoex; movewindow; newpipe; newpipewndproc; notinquote; numitems; openfile; outputdebugstring; parsecommandline; parseoptionsvalues; posterror; postquitmessage; prepareparmlist; printaffectedrows; printerrors; printerrorshwnd; promptforfontname; rc_notsuccessful; rc_successful; rectangle; refreshlist; refreshpipelist; registerclass; releasedc; releasememory; removecrlf; resetmenu; resolveinifile; resultswndproc; rgb; selectobject; sendmessage; setbkcolor; setbkmode; setcipointer; setcolumndata; setcursor; setdefaultfont; setdefaultrgb; setdlgitemtext; setfocus; setfontstyle; setmetadatacolumn; setmetadatafromsql; setrwpointer; setscrollpos; setscrollrange; settextalign; settextcolor; setup; setwindowlong; setwindowtext; showcatalogresults; showcursor; showwindow; sprintf; sqlallochandle; sqlbindparameter; sqlcolumnprivileges; sqlcolumns; sqldatasources; sqldescribecol; sqldisconnect; sqldriverconnect; sqlendtran; sqlexecdirect; sqlexecute; sqlfetch; sqlforeignkeys; sqlfreehandle; sqlfreestmt; sqlgetdata; sqlgetdiagrec; sqlgetfunctions; sqlgetinfo; sqlgettypeinfo; sqlmanagedatasources; sqlmoreresults; sqlnumresultcols; sqlparamdata; sqlprepare; sqlprimarykeys; sqlprocedurecolumns; sqlprocedures; sqlputdata; sqlrowcount; sqlsetconnectattr; sqlsetenvattr; sqlspecialcolumns; sqlstatistics; sqltableprivileges; sqltables; strchr; strcmp; strncmp; strng_item; strstr; strtok; strtoul; switch; szmessagebox; szwrite; time; translateaccelerator; translatemdisysaccel; translatemessage; updatewindow; va_end; va_start; validname; validsqlstmt; winassert; winassertreal; winhelp; wndproc; writeprivateprofilestring; wsprintf