home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Network Support Encyclopedia 96-1
/
novell-nsepro-1996-1-cd2.iso
/
download
/
netware
/
xset1.exe
/
SCAN_SET.C
next >
Wrap
C/C++ Source or Header
|
1995-08-28
|
4KB
|
148 lines
/**************************************************************************
** File: scan_set.c
**
** Desc: Scan all setable parameters on the system.
**
** <Detailed description>
**
**
** DISCLAIMER
**
** Novell, Inc. makes no representations or warranties with respect to
** any NetWare software, and specifically disclaims any express or
** implied warranties of merchantability, title, or fitness for a
** particular purpose.
**
** Distribution of any NetWare software is forbidden without the
** express written consent of Novell, Inc. Further, Novell reserves
** the right to discontinue distribution of any NetWare software.
**
** Novell is not responsible for lost profits or revenue, loss of use
** of the software, loss of data, costs of re-creating lost data, the
** cost of any substitute equipment or program, or claims by any party
** other than you. Novell strongly recommends a backup be made before
** any software is installed. Technical support for this software
** may be provided at the discretion of Novell.
**
**
** Programmers:
**
** Ini Who Firm
** ---------------------------------------------------------------------
** DWH Dirk W. Howard Novell Developer Support
**
**
** History:
**
** When Who What
** ---------------------------------------------------------------------
** 12-1-1994 DWH First code.
**
*/
/**************************************************************************
** Include headers and macro definitions
*/
/*------------------------------------------------
** ANSI
*/
#include <stdio.h>
#include <string.h>
/*------------------------------------------------
** NetWare
*/
#include <advanced.h>
#include <conio.h>
/*------------------------------------------------
** Macros
*/
#define ALL_CATEGORIES -1
#define SELECTED_CATEGORY 0
void main()
{
LONG scanCategory = ALL_CATEGORIES;
LONG scanSequence = 0;
BYTE rParameterName[256];
LONG rType;
LONG rFlags;
LONG rCategory;
BYTE parameterDescription[1024];
BYTE currentValue[256];
LONG rLowerLimit;
LONG rUpperLimit;
LONG lcode = 0;
LONG lnCnt = 0;
BYTE szCategory[256];
while ( lcode != -1 )
{
lcode = ScanSetableParameters(
scanCategory,
&scanSequence,
rParameterName,
&rType,
&rFlags,
&rCategory,
parameterDescription,
currentValue,
&rLowerLimit,
&rUpperLimit
);
if ( lcode == 0 )
{
switch ( rCategory )
{
case 0:
strcpy( szCategory, "COMMUNICATIONS" );
break;
case 1:
strcpy( szCategory, "MEMORY " );
break;
case 2:
strcpy( szCategory, "FILE CACHE " );
break;
case 3:
strcpy( szCategory, "DIR CACHE " );
break;
case 4:
strcpy( szCategory, "FILE SYSTEM " );
break;
case 5:
strcpy( szCategory, "LOCKING " );
break;
case 6:
strcpy( szCategory, "TTS " );
break;
case 7:
strcpy( szCategory, "DISK " );
break;
case 8:
strcpy( szCategory, "TIME " );
break;
case 9:
strcpy( szCategory, "NCP " );
break;
case 10:
strcpy( szCategory, "MISCELLANEOUS " );
break;
case 11:
strcpy( szCategory, "ERROR HANDLING" );
break;
}
printf( "%s: %s\n", szCategory, rParameterName );
lnCnt++;
if ( (lnCnt % 20) == 0 )
{
getch();
printf( "\r" );
}
}
}
return;
}