home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Power-Programmierung
/
CD1.mdf
/
pascal
/
library
/
dos
/
netz
/
netware
/
readme.doc
< prev
next >
Wrap
Text File
|
1992-03-02
|
3KB
|
98 lines
Turbo Pascal API's for Novell Netware
Written by Tony Covelli (c) 1991
Welcome to Turbo Pascal API's for Novell Netware (TPAPI). Please forgive for
me for the quality of the documentation. This will improve over time, but for
those of you who can't wait you can buy Novell's 'C' Interface for DOS or their
Systems Calls for DOS.
TPAPI is an object oriented library of Netware function calls. It does not
incorporate all of the available calls as of now, but I will continue to add
existing and new calls.
The NetwareOBJ is the lowest object and contains all the low level routines
that talk to the network shells. All other objects are ancestors of this
object.
The following information is provided for those who wish to add any of their
own API's.
Example functions :
FUNCTION BinderyOBJ.ChangeBinderyObjectPassword (BinderyObjectName : ObjectNameType; BinderyObjectType : OT_BinderyType;
OldPassword, NewPassword : PasswordType) : WORD;
BEGIN
InitRequestBuffer;
InitReceiveBuffer;
BinderyObjectName := UpperCaseNW (BinderyObjectName);
OldPassword := UpperCaseNW (OldPassword);
NewPassword := UpperCaseNW (NewPassword);
AddByte (64);
AddWordSwap (BinderyObjectType);
AddString (BinderyObjectName, 0);
AddString (OldPassword, 0);
AddString (NewPassword, 0);
AddTotal (Request);
SetTotal (Receive, 2);
AddTotal (Receive);
ChangeBinderyObjectPassword := ShellRequest (227, nwRequestBuffer, nwReceiveBuffer);
END; {BinderyOBJ.ChangeBinderyObjectPassword}
FUNCTION BinderyOBJ.ScanBinderyObject (SearchObjectName : ObjectNameType; SearchObjectType : OT_BinderyType;
VAR ObjectID : OT_BinderyID; VAR BinderyObjectName : ObjectNameType;
VAR BinderyObjectType : OT_BinderyType;
VAR ObjectHasProperties, ObjectFlags, ObjectSecurity : BYTE) : WORD;
BEGIN
InitRequestBuffer;
InitReceiveBuffer;
SearchObjectName := UpperCaseNW (SearchObjectName);
AddByte (55);
AddLongSwap (ObjectID);
AddWordSwap (SearchObjectType);
AddString (SearchObjectName, 0);
AddTotal (Request);
SetTotal (Receive, 59);
AddTotal (Receive);
ScanBinderyObject := ShellRequest (227, nwRequestBuffer, nwReceiveBuffer);
GetString (BinderyObjectName, 8, 48);
GetLongSwap (ObjectID, 2);
GetWordSwap (BinderyObjectType, 6);
GetByte (ObjectHasProperties, 58);
GetByte (ObjectFlags, 56);
GetByte (ObjectSecurity, 57);
END; {BinderyOBJ.ScanBinderyObject}
Each function must call InitRequestBuffer and InitReceiveBuffer first. This
clears out the internal buffers and resets the offset variables.
You must also call AddTotal twice, firstly with (Request) and once again after
calling SetTotal (Receive, amount of data to return), but passing in Receive.
Please enjoy. Any comments or suggestions are welcome.
Tony Covelli
23 Sefton House
Grosvenor Road
Aldershot
Hants
GU11 3DW
England
CIS #100015, 3611
CIX MSL
Coming soon :-
* Windows version under development
* Loads more API's
* The use of encrypted password on Netware 386