home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Network Support Encyclopedia 96-1
/
novell-nsepro-1996-1-cd2.iso
/
download
/
netware
/
nwatt.exe
/
NWATTACH.C
< prev
next >
Wrap
C/C++ Source or Header
|
1994-09-29
|
2KB
|
51 lines
/****************************************************************************
** 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.
****************************************************************************
#include <stdio.h>
#include <string.h>
#include <alloc.h>
#include <nwcalls.h>
void main (int argc, char *argv[])
{
NWCONN_HANDLE connHandle;
NWCCODE ccode;
if (argc != 2)
{
printf ("Usage: ATTACH <server name>");
return;
}
ccode = NWCallsInit (NULL,NULL);
if (ccode) return;
strupr (argv[1]);
ccode = NWAttachToFileServer (argv[1], 0, &connHandle);
if (ccode)
{
printf ("NWAttachToFileServer returned error %04X\n", ccode);
return;
}
printf ("You are attached to server %s\n", argv[1]);
}