Win32 Extensions
Perl for Win32
ActiveWare
NT - miscellaneous extensions for Win32.
For more information on Perl
for Win32:
- Win32mod - current set of modules for Perl for Win32
- Win32XS - issues specific to writing module extensions for Perl for Win32 (build 1xx)
DESCRIPTION
Go here for more information on dynaloaded extension modules. Because Perl for Win32 originated on the Windows NT platform, most modules extensions for Win32 exist under the NT hierarchy. The following extensions routines are available:
- Win32::GetLastError
- Returns the last error value generated by a call to a Win32 API function.
- Win32::OLELastError
- Returns the last error value generated by a call to a Win32 OLE API function.
- Win32::BuildNumber
- Returns the build number of Perl for Win32.
- Win32::LoginName
- Returns the username of the owner of the current perl process.
- Win32::NodeName
- Returns the Microsoft Network node-name of the current machine.
- Win32::DomainName
- Returns the name of the Microsoft Network domain that the owner of the current perl process is logged into.
- Win32::FsType
- Returns a string naming the filesystem type of the currently active drive.
- Win32::GetCwd
- Returns the current active drive and directory. This function does not return a UNC path, since the functionality required to required for such a feature is not available under Windwos 95.
- Win32::SetCwd NEWDIRECTORY
- Sets the current active drive and directory. This function does not work with UNC paths, since the functionality required to required for such a feature is not available under Windwos 95.
- Win32::GetOSVersion
- Returns the array ($string, $major,
$minor, $build, $id),
where the elements are, respectively; An arbitrary descriptive string, the major version number of the operating system, the minor version number, the build number, and a digit indicating the actual operating system. For $id, the values are 0 for Win32s, 1 for Windows 95 and 2 for Windows NT.
- Win32::FormatMessage ERRORCODE
- Converts the supplied Win32 error number (e.g. returned by Win32::GetLastError or Win32::OLELastError) to a descriptive string. Analogous to the
perror
standard-C library function.
- Win32::Spawn COMMAND, ARGS, PID
- Spawns a new process using the supplied
COMMAND
, passing in arguments in the string ARGS
. The pid of the new process is stored in PID
.
- Win32::LookupAccountName SYSTEM, ACCOUNT, DOMAIN, SID, SIDTYPE
- Looks up
ACCOUNT
on SYSTEM
and returns the domain name the SID and the SID type.
- Win32::LookupAccountSID SYSTEM, SID, ACCOUNT, DOMAIN, SIDTYPE
- Looks up
SID
on SYSTEM
and returns the account name, domain name, and the SID type.
- Win32::InitiateSystemShutdown
MACHINE, MESSAGE, TIMEOUT, FORCECLOSE, REBOOT
- Shutsdown the specified
MACHINE
, notifying users with the supplied MESSAGE
, within the specified TIMEOUT
interval. Forces closing of all documents without prompting the user if FORCECLOSE
is true, and reboots the machine if REBOOT
is true.
- Win32::AbortSystemShutdown MACHINE
- Aborts a shutdown on the specified
MACHINE
.
- Win32::GetTickCount
- Returns the Win32 tick count.
- Win32::IsWinNT
- Returns non zero if the Win32 subsystem is Windows NT.
- Win32::IsWin95
- Returns non zero if the Win32 subsystem is Windows 95.
- Win32::ExpandEnvironmentStrings STRING
- Takes the
STRING
and builds a return string that has environment-variable strings replaced with their defined values.
- Win32::GetShortPathName LONGPATHNAME
- Returns the short (8.3) path name of
LONGPATHNAME
.
- Win32::GetNextAvailDrive
- Returns a string in the form of "<d>:\" where <d> is the first available drive letter.
- Win32::RegisterServer LIBRARYNAME
- Loads the DLL
LIBRARYNAME
and calls the function DllRegisterServer.
- Win32::UnregisterServer LIBRARYNAME
- Loads the DLL
LIBRARYNAME
and calls the function DllUnregisterServer.
- Win32::Sleep TIME
- Pauses for
TIME
milliseconds.
Perl for Win32
ActiveWare