home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 18 REXX
/
18-REXX.zip
/
msnwrexx.zip
/
msnwrexx.doc
< prev
next >
Wrap
Text File
|
1996-02-07
|
4KB
|
114 lines
MSNWREXX Version 1.1
** This program is compatible with all 2.x and 3.x versions of OS/2 **
** This program is compatible with all 3.x versions of Netware **
** This program is believed compatible with all 4.x versions of Netware in bindery mode **
Copyright (c) 1996 Moore Stephens - All Rights Reserved.
MSNWREXX - An OS/2 DLL to permit REXX programs to call basic Netware functions
─────────────────────────────────────────────────────────────────────────────
1. INSTALLATION OF MSNWREXX
The only requirement for the installation of MSNWREXX is to place the DLL
(msnwrexx.dll) in a directory that is on the LIBPATH of the PC.
2. REGISTRATION OF THE MSNWREXX ROUTINES
Before the MSNWREXX routines can be used, they must be registered to REXX
using the following code:
CALL RxFuncAdd 'MSNWLoadFuncs', 'msnwfunc', 'MSNWLoadFuncs'
CALL MSNWLoadFuncs
3. CALLING THE MSNWREXX ROUTINES
Most routines can be called either as functions or with the CALL keyword. Each
routine provides a return code that indicates any problem conditions that have
occurred in interfacing to Netware. A few routines return a value which is the
purpose of calling them. The possible return codes are listed below.
3.1. return=MSNWDefaultName()
There are no parameters for this routine, which returns the name of the default
server.
3.2. return=MSNWCheckUser(Server,UserName,Password)
You must already have an attachment to the server specified in order for this
routine to work. Provided that condition is satisfied, the parameters are checked
on the specified server to see whether the UserName and Password combination
provided are legitimate. If they are, the return code will be zero.
3.3. return=MSNWAttach(Server,UserName,Password)
This routine will attempt to achieve an attachment to the specified server, using
the UserName and Password combination provided. If successful, the return code
will be zero. If the password is expired, but there are still grace logins, the
attachment will succeed, but the return code will be (100+number of grace logins
remaining). If the user is already attached, no action will be taken (i.e. there is
no logout and re-attach) and a zero return code will be given.
3.4. return=MSNWMap(Server, Volume, Drive, Path)
There must already be an attachment for the server specified. Provided that is the
case, then a mapping will be attempted. The server volume name must be specified
as the second parameter. The drive to be mapped is the third parameter and is
specified simply as a drive letter with no additional punctuation as shown in the
example. The final parameter may be null, or may specify a legal path on the
volume to be mapped. If a path is specified, then a root mapping will be
attempted. An example of a call is:
return=MSNWMap('MYSERVER', 'SYS', 'F', '')
3.5. serverlist=MSNWSListServers()
You can obtain a list of currently visible servers by calling the function MSNWSList
which requires no parameters. The result is a space separated list of server names.
It is equivalent to the information obtained from the SLIST utility.
3.6. connection=getconnctn()
This routine returns the Netware connection number for the default server, provided
there is an attachment to a server.
3.7. segment=
The network number of the attached segment is returned.
4. ERROR RETURN CODES
Where an error occurs, the return code will indicate which of the Netware routines
provided in the standard Netware SDK gave an error return. The key to error codes is:
1. init_calls 2. get_attach 3. get_status
4. do_login 5. do_logout 6. read_property
7. get_dconn 8. check_user 9. write_property
10. get_handle 11. get_pconn 12. GetDriveStatus
13. Drive in use 14. ParsePath 15. SetDriveBase
16. ChangeObjectPassword 17. GetConnectionInformation 18. GetInternetAddress
5. DEBUGGING
After the parameters specified above, it is possible to code one additional parameter.
If the additional parameter is coded and has the value 'X' then the function will
operate in debug mode, and any error messages will be shown on the screen.