Check out my old thread, I made my addons by checking this forum, and by interrigating the MSDN Function Database to exploit whatever I Could.
https://forum.thegamecreators.com/thread/161497
Here is the code from the thread which was labled "
The Ultimate Windows DLL Include File"
StartDLLCommands: ` Load DLL's ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
GLOBAL DLL_User32 AS INTEGER : DLL_User32 = FIND FREE DLL() : LOAD DLL "User32.dll" ,DLL_User32
GLOBAL DLL_Kernel32 AS INTEGER : DLL_Kernel32 = FIND FREE DLL() : LOAD DLL "Kernel32.dll" ,DLL_Kernel32
GLOBAL DLL_WinLock AS INTEGER : DLL_WinLock = FIND FREE DLL() : LOAD DLL "WinLockDll.dll",DLL_WinLock
GLOBAL DLL_GDI32 AS INTEGER : DLL_GDI32 = FIND FREE DLL() : LOAD DLL "GDI32.dll" ,DLL_GDI32
GLOBAL ConsoleStdOut AS INTEGER
` Mouse Constant Commands ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
#CONSTANT MOUSE_LEFTDOWN ForceMouseClickEvent( 1)
#CONSTANT MOUSE_LEFTUP ForceMouseClickEvent( 2)
#CONSTANT MOUSE_LEFTCLICK ForceMouseClickEvent( 12)
#CONSTANT MOUSE_DOUBLECLICK ForceMouseClickEvent(1212)
#CONSTANT MOUSE_RIGHTDOWN ForceMouseClickEvent( 3)
#CONSTANT MOUSE_RIGHTUP ForceMouseClickEvent( 4)
#CONSTANT MOUSE_RIGHTCLICK ForceMouseClickEvent( 34)
#CONSTANT MOUSE_MIDDLEDOWN ForceMouseClickEvent( 5)
#CONSTANT MOUSE_MIDDLEUP ForceMouseClickEvent( 6)
#CONSTANT MOUSE_MIDDLECLICK ForceMouseClickEvent( 56)
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Return
` Getting a Handle / Setting Parent Handle ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION DesktopHandle() : ` Returns the Handle to the Desktop
Result = CALL DLL(DLL_User32,"GetDesktopWindow")
ENDFUNCTION Result
FUNCTION GetActiveWindow() : ` Get the Handle for the Active Window
hwnd = CALL DLL(DLL_User32,"GetActiveWindow")
ENDFUNCTION hwnd
FUNCTION GetForegroundWindow() : ` Get the Handle for the Active Window
hwnd = CALL DLL(DLL_User32,"GetForegroundWindow")
ENDFUNCTION hwnd
FUNCTION FindWindow(Title$) : ` Get a Handle for a Window Searching by Title
hwnd = CALL DLL(DLL_User32,"FindWindowA",0x0,Title$)
ENDFUNCTION hwnd
FUNCTION GetNextWindow(Handle) : ` Get the Next Window in zOrder
Result = CALL DLL(DLL_User32,"GetNextWindow",Handle,2)
ENDFUNCTION Result
FUNCTION GetPreviousWindow(Handle) : ` Get the Previous Window in zOrder
Result = CALL DLL(DLL_User32,"GetNextWindow",Handle,3)
ENDFUNCTION Result
FUNCTION WindowFromPoint(x,y) : ` Returns Handle to Window at x,y
Result = CALL DLL(DLL_USER32,"WindowFromPoint",x,y)
ENDFUNCTION Result
FUNCTION ChildWindowFromPoint(Handle,x,y) : ` Determines which, if any, of the child windows belonging to a parent window contains the specified point. The search is restricted to immediate child windows. Grandchildren, and deeper descendant windows are not searched
Result = CALL DLL(DLL_USER32,"ChildWindowFromPoint",Handle,x,y)
ENDFUNCTION Result
FUNCTION GetParent(Handle) : ` Get the Parent of an Item like a Window from the Handle
Result = CALL DLL(DLL_USER32,"GetParent",Handle)
ENDFUNCTION Result
FUNCTION SetParent(Handle,Parent) : ` Change the Items Parent
Temp = CALL DLL(DLL_User32,"SetParent",Handle,Parent)
ENDFUNCTION
` Size and Position Commands ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION DesktopWidth() : ` Returns Desktop Width
Result = CALL DLL(DLL_User32,"GetSystemMetrics",0)
ENDFUNCTION Result
FUNCTION DesktopHeight() : ` Returns Desktop Height
Result = CALL DLL(DLL_User32,"GetSystemMetrics",1)
ENDFUNCTION Result
FUNCTION GetHandleX(Handle) : ` Get the Items X Position
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,0)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION GetHandleY(Handle) : ` Get the Items Y Position
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,4)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION GetHandleWidth(Handle) : ` Get the Items Width
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,8)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION GetHandleHeight(Handle) : ` Get the Items Height
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,12)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION SetHandle(Handle,x,y,Width,Height) : ` Position and Resize the Item
Temp = CALL DLL(DLL_User32,"MoveWindow",Handle,x,y,Width,Height,1)
ENDFUNCTION
FUNCTION PositionHandle(Handle,x,y) : ` Move the Item
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Width = MEMBLOCK DWORD(Memblock, 8)
Height = MEMBLOCK DWORD(Memblock,12)
DELETE MEMBLOCK Memblock
Temp = CALL DLL(DLL_User32,"MoveWindow",Handle,x,y,Width,Height,1)
ENDFUNCTION
FUNCTION ResizeHandle(Handle,Width,Height) : ` Resize the Item
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
x = MEMBLOCK DWORD(Memblock,0)
y = MEMBLOCK DWORD(Memblock,4)
DELETE MEMBLOCK Memblock
Temp = CALL DLL(DLL_User32,"MoveWindow",Handle,x,y,Width,Height,1)
ENDFUNCTION
` Cursor and Mouse Commands ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION LoadCursor(File$) : ` Specifies the source of the file data to be used to create the cursor. The data in the file must be in either .CUR or .ANI format. If the function is successful, the return value is a handle to the new cursor.
RV = CALL DLL(DLL_USER32,"LoadCursorFromFile",File$)
ENDFUNCTION RV
FUNCTION SetCursor(Handle) : ` The SetCursor function sets the cursor shape.
RV = CALL DLL(DLL_USER32,"SetCursor",Handle)
ENDFUNCTION RV
FUNCTION DeleteCursor(Handle) : ` The DestroyCursor function destroys a cursor and frees any memory the cursor occupied. Do not use this function to destroy a shared cursor.
RV = CALL DLL(DLL_USER32,"DestroyCursor",Handle)
ENDFUNCTION RV
FUNCTION CursorX() : ` Get the X Position of the Cursor
Memblock = Find Free Memblock()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetCursorPos",GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,0)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION CursorY() : ` Get the Y Position of the Cursor
Memblock = Find Free Memblock()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetCursorPos",GET MEMBLOCK PTR(Memblock))
Result = MEMBLOCK DWORD(Memblock,4)
DELETE MEMBLOCK Memblock
ENDFUNCTION Result
FUNCTION CursorWidth() : ` The width of a cursor, in pixels. The system cannot create cursors of other sizes.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",13)
ENDFUNCTION rv
FUNCTION CursorHeight() : ` The Height of a cursor, in pixels. The system cannot create cursors of other sizes.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",14)
ENDFUNCTION rv
FUNCTION SetCursorPos(x,y) : ` Position the Mouse Cursor
CALL DLL DLL_User32,"SetCursorPos",x,y
ENDFUNCTION
FUNCTION ForceMouseClickEvent(Btn) : ` Force a Mouce Click Sequance
FOR n = 1 to LEN(STR$(Btn)) : v = VAL(MID$(STR$(Btn),n))
IF v = 1 THEN CALL DLL DLL_User32,"mouse_event",0x2 ,0,0,0,0
IF v = 2 THEN CALL DLL DLL_User32,"mouse_event",0x4 ,0,0,0,0
IF v = 3 THEN CALL DLL DLL_User32,"mouse_event",0x8 ,0,0,0,0
IF v = 4 THEN CALL DLL DLL_User32,"mouse_event",0x10,0,0,0,0
IF v = 5 THEN CALL DLL DLL_User32,"mouse_event",0x20,0,0,0,0
IF v = 6 THEN CALL DLL DLL_User32,"mouse_event",0x40,0,0,0,0
NEXT n
ENDFUNCTION
FUNCTION MouseButtonCount() : ` The number of buttons on a mouse, or zero if no mouse is installed.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",43)
ENDFUNCTION rv
FUNCTION IsHorizontalScrollWheelInstalled() : ` Nonzero if a mouse with a horizontal scroll wheel is installed; otherwise 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",91)
ENDFUNCTION rv
FUNCTION IsVerticalScrollWheelInstalled() : ` Nonzero if a mouse with a vertical scroll wheel is installed; otherwise 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",75)
ENDFUNCTION rv
FUNCTION IsMouseButtonsSwitched() : ` Nonzero if the meanings of the left and right mouse buttons are swapped; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",23)
ENDFUNCTION rv
` Font Commands ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION SetFont(Handle,FontHandle) : ` Set an Items Font
Result = CALL DLL(DLL_User32,"SendMessageA",Handle,0x0030,FontHandle,1)
ENDFUNCTION
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION Delete(Handle) : ` Delete an Item
CALL DLL DLL_User32,"DestroyWindow",Handle
ENDFUNCTION
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION BringWindowToFront(Handle) : ` Move Window to Foreground and Give Focus
Result = CALL DLL(DLL_User32,"BringWindowToTop",Handle)
ENDFUNCTION
FUNCTION AlwaysOnTop(Handle) : ` Set Window Always on Top
Result = CALL DLL(DLL_User32,"BringWindowToTop",Handle)
Result = CALL DLL(DLL_User32,"LockSetForegroundWindow",1)
ENDFUNCTION
FUNCTION RemoveAlwaysOnTop() : ` Undo AlwaysOnTop
Result = CALL DLL(DLL_User32,"LockSetForegroundWindow",2)
ENDFUNCTION
FUNCTION HideWindow(Handle) : ` Minimize a Window
Result = CALL DLL(DLL_User32,"CloseWindow",Handle)
ENDFUNCTION
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION IsWindow(Handle) : ` Returns 1 if the Item is a Window, Else Returns 0
Result = CALL DLL(DLL_User32,"IsWindow",Handle)
ENDFUNCTION Result
FUNCTION IsWindowVisible(Handle) : ` Returns 1 if the Item is Visible, Else Returns 0
Result = CALL DLL(DLL_User32,"IsWindowVisible",Handle)
ENDFUNCTION Result
FUNCTION IsWindowMaximized(Handle) : ` Returns 1 if the Window is Maximized, Else Returns 0
Result = CALL DLL(DLL_User32,"IsZoomed",Handle)
ENDFUNCTION Result
FUNCTION IsWindowMinimized(Handle) : ` Returns 1 if the Window is Minimised, Else Returns 0
Result = CALL DLL(DLL_User32,"ismin",Handle)
ENDFUNCTION Result
FUNCTION IsChild(Handle,Parent) : ` Tests whether a window is a child window or descendant window of a specified parent window. A child window is the direct descendant of a specified parent window if that parent window is in the chain of parent windows; the chain of parent windows leads from the original overlapped or pop-up window to the child window.
Result = CALL DLL(DLL_User32,"IsChild",Parent,Handle)
ENDFUNCTION Result
FUNCTION IsHung(Handle) : ` Indicates if a Window/App is not responding
Result = CALL DLL(DLL_User32,"IsHungAppWindow",Handle)
ENDFUNCTION Result
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION IsWindowEnabled(Handle) : ` Determines whether the specified window is enabled for mouse and keyboard input
Result = CALL DLL(DLL_User32,"IsWindowEnabled",Handle)
ENDFUNCTION Result
FUNCTION EnableWindow(Handle,Bool) : ` The EnableWindow function enables or disables mouse and keyboard input to the specified window or control. When input is disabled, the window does not receive input such as mouse clicks and key presses. When input is enabled, the window receives all input.
Result = CALL DLL(DLL_User32,"EnableWindow",Handle,Bool)
ENDFUNCTION
` ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
FUNCTION SetWindowText(Handle,Text$) : ` The SetWindowText function changes the text of the specified window's title bar (if it has one). If the specified window is a control, the text of the control is changed. However, SetWindowText cannot change the text of a control in another application
Result = CALL DLL(DLL_User32,"SetWindowText",Handle,Text$)
ENDFUNCTION Result
FUNCTION FlashWindow(Handle,Invert) : ` Flashes the specified window one time. It does not change the active state of the window.
Result = CALL DLL(DLL_User32,"FlashWindow",Handle,Invert)
ENDFUNCTION Result
` --------------------------------------------------------------------------------------------------------------------
FUNCTION Beep(Freq,Duration) : ` Does not return control to its caller until the sound finishes.
Result = CALL DLL(DLL_Kernal32,"Beep",Freq,Duration)
ENDFUNCTION Result
FUNCTION MessageBeep_Simple : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",-1)
ENDFUNCTION Result
FUNCTION MessageBeep_Asterisk() : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",0x00000040)
ENDFUNCTION Result
FUNCTION MessageBeep_Exclamation() : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",0x00000030)
ENDFUNCTION Result
FUNCTION MessageBeep_Hand() : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",0x00000010)
ENDFUNCTION Result
FUNCTION MessageBeep_Question() : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",0x00000020)
ENDFUNCTION Result
FUNCTION MessageBeep_OK() : ` The sound type is identified by an entry in the registry.
Result = CALL DLL(DLL_User32,"MessageBeep",0x00000000)
ENDFUNCTION Result
` --------------------------------------------------------------------------------------------------------------------
FUNCTION SetCtrlAltDelEnabled(Num) : ` USE THIS CODE WITH CAUSION - Enable or Disable CtrlAltDelete
CALL DLL DLL_WinLock,"CtrlAltDel_Enable_Disable",Num
ENDFUNCTION
FUNCTION SetAltTabEnabled(Num) : ` USE THIS CODE WITH CAUSION - Enable or Disable AltTab
CALL DLL DLL_WinLock,"AltTab2_Enable_Disable",0,Num
ENDFUNCTION
FUNCTION SetKeysEnabled(Num) : ` USE THIS CODE WITH CAUSION - Enable or Disable Keys
CALL DLL DLL_WinLock,"Keys_Enable_Disable",Num
ENDFUNCTION
FUNCTION SetTaskSwitchingEnabled(Num) : ` USE THIS CODE WITH CAUSION - Enable or Disable Task Switching
CALL DLL DLL_WinLock,"TaskSwitching_Enable_Disable",Num
ENDFUNCTION
` --------------------------------------------------------------------------------------------------------------------
FUNCTION Console_Start() : ` Opens a console window, Returns 0 if fail
Result = CALL DLL(DLL_Kernel32,"AllocConsole")
ConsoleStdOut = CALL DLL(DLL_Kernel32,"GetStdHandle",-11)
ENDFUNCTION Result
FUNCTION Console_Stop() : ` Closes the Console Window, Returns 0 if fail
Result = CALL DLL(DLL_Kernel32,"FreeConsole")
ENDFUNCTION RESULT
FUNCTION Console_WriteLine(Text$) : ` Writes the Text to a new line, returns 0 if fail
Result = CALL DLL(DLL_Kernel32,"WriteConsoleA",ConsoleStdOut,Text$+CHR$(10),LEN(Text$+CHR$(10)),0,0)
ENDFUNCTION RESULT
FUNCTION Console_Write(Text$) : ` Writes text to the console window, Returns 0 if fail
Result = CALL DLL(DLL_Kernel32,"WriteConsoleA",ConsoleStdOut,Text$,LEN(Text$),0,0)
ENDFUNCTION Result
FUNCTION Console_ForeColor(Color$,Bright) : ` Sets the Text Color, Returns 0 if fail
Color$ = UPPER$(Color$)
SELECT Color$
CASE "BLACK" : Col = 00 : ENDCASE
CASE "BLUE" : Col = 01 : ENDCASE
CASE "GREEN" : Col = 02 : ENDCASE
CASE "RED" : Col = 04 : ENDCASE
CASE "MAGENTA" : Col = 01 || 04 : ENDCASE
CASE "CYAN" : Col = 02 || 01 : ENDCASE
CASE "YELLOW" : Col = 04 || 02 : ENDCASE
CASE "WHITE" : Col = 04 || 02 || 01 : ENDCASE
ENDSELECT
IF Bright = 1 THEN Col = Col || 010
Result = CALL DLL(DLL_Kernel32,"SetConsoleTextAttribute",ConsoleStdOut,Col)
ENDFUNCTION Result
FUNCTION Console_Title(Title$) : ` Sets the Windows Title Text, returns 0 if fail
Result = CALL DLL(DLL_Kernel32,"SetConsoleTitleA",Title$)
ENDFUNCTION Result
` --------------------------------------------------------------------------------------------------------------------
FUNCTION GetPixel(X,Y)
hDsk = CALL DLL(DLL_User32,"GetDesktopWindow")
hDc = CALL DLL(DLL_User32,"GetWindowDC",hDsk)
Color = CALL DLL(DLL_GDI32,"GetPixel",hDc,xPos,yPos)
Color = RGB(RGBB(Color),RGBG(Color),RGBR(Color))
ENDFUNCTION Color
` --------------------------------------------------------------------------------------------------------------------
FUNCTION Snapshot()
hDsk = CALL DLL(DLL_User32,"GetDesktopWindow")
hDc = CALL DLL(DLL_User32,"GetWindowDC",hDsk)
Width = CALL DLL(DLL_User32,"GetSystemMetrics",0)
Height = CALL DLL(DLL_User32,"GetSystemMetrics",1)
Img = SnapshotWindowArea(hDc,0,0,Width,Height)
ENDFUNCTION Img
FUNCTION SnapshotArea(x,y,Width,Height)
hDsk = CALL DLL(DLL_User32,"GetDesktopWindow")
hDc = CALL DLL(DLL_User32,"GetWindowDC",hDsk)
Img = SnapshotWindowArea(hDc,x,y,Width,Height)
ENDFUNCTION Img
FUNCTION SnapshotWindow(Handle)
Memblock = FIND FREE MEMBLOCK()
MAKE MEMBLOCK Memblock,20
Temp = CALL DLL(DLL_User32,"GetWindowRect",Handle,GET MEMBLOCK PTR(Memblock))
Width = MEMBLOCK DWORD(Memblock,8)
Height = MEMBLOCK DWORD(Memblock,8)
DELETE MEMBLOCK Memblock
Img = SnapshotWindowArea(Handle,0,0,Width,Height)
ENDFUNCTION Img
FUNCTION SnapshotWindowArea(Handle,x,y,Width,Height)
Img = FIND FREE IMAGE()
Bmp = FIND FREE BITMAP()
OldBmp = CURRENT BITMAP()
CREATE BITMAP Bmp,Width,Height
SET CURRENT BITMAP Bmp
LOCK PIXELS
FOR yPos = y to Height
FOR xPos = x to Width
Color = CALL DLL(DLL_GDI32,"GetPixel",hDc,xPos,yPos)
INK RGB(RGBB(Color),RGBG(Color),RGBR(Color)),0
DOT xPos,yPos
NEXT xPos : NEXT yPos
UNLOCK PIXELS
GET IMAGE Img,xPos,yPos,Width,Height,1
SET CURRENT BITMAP OldBmp
DELETE BITMAP Bmp
ENDFUNCTION Img
FUNCTION SnapshotGadget(GadgetNumber)
Handle = GADGETHANDLE(GadgetNumber)
Width = GADGETWIDTH(GadgetNumber)
Height = GADGETHEIGHT(GadgetNumber)
Img = SnapshotWindowArea(Handle,0,0,Width,Height)
ENDFUNCTION Img
` Default Size Values --------------------------------------------------------------------------------------------------------------------
FUNCTION GetVerticalScrollbarWidth() : ` The width of a vertical scroll bar, in pixels.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",2)
ENDFUNCTION rv
FUNCTION GetHorizontalScrollbarHeight() : ` The height of a horizontal scroll bar, in pixels.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",3)
ENDFUNCTION rv
FUNCTION GetFullScreenClientWidth() : ` The width of the client area for a full-screen window on the primary display monitor, in pixels.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",16)
ENDFUNCTION rv
FUNCTION GetFullScreenClientHeight() : ` The height of the client area for a full-screen window on the primary display monitor, in pixels.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",17)
ENDFUNCTION rv
FUNCTION Get3DBorderWidth() : ` The width of a 3-D border, in pixels. This metric is the 3-D counterpart of SM_CXBORDER.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",45)
ENDFUNCTION rv
FUNCTION Get3DBorderHeight() : ` The height of a 3-D border, in pixels. This is the 3-D counterpart of SM_CYBORDER.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",46)
ENDFUNCTION rv
FUNCTION HowMinimizedWindowsArranged() : ` Specifys how the system arranges minimized windows
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",56)
ENDFUNCTION rv
FUNCTION GetMenubarHeight() : ` The height of a single-line menu bar, in pixels.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",15)
ENDFUNCTION rv
` --------------------------------------------------------------------------------------------------------------------
FUNCTION GetBootMode() : ` The value that specifies how the system is started.
` Return Values
` 0 Normal boot
` 1 Fail-safe boot
` 2 Fail-safe with network boot
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",67)
ENDFUNCTION rv
FUNCTION GetConnectedMonitorCount() : ` The number of display monitors on a desktop.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",80)
ENDFUNCTION rv
FUNCTION IsSlowProcessor() : ` Nonzero if the computer has a low-end (slow) processor; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",73)
ENDFUNCTION rv
FUNCTION IsRemotleyControlledByTerminal() : ` This system metric is used in a Terminal Services environment. Its value is nonzero if the current session is remotely controlled; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",0x2001)
ENDFUNCTION rv
FUNCTION IsPenExtensionsInstalled() : ` Nonzero if the Microsoft Windows for Pen computing extensions are installed; zero otherwise.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",41)
ENDFUNCTION rv
FUNCTION IsNetworkPresent() : ` The least significant bit is set if a network is present; otherwise, it is cleared. The other bits are reserved for future use.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",63)
ENDFUNCTION rv
FUNCTION IsEnabledForHebrewAndArabicLanguages() : ` Nonzero if the system is enabled for Hebrew and Arabic languages, 0 if not.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",74)
ENDFUNCTION rv
FUNCTION IsDBCSEnabled() : ` Nonzero if User32.dll supports DBCS; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",42)
ENDFUNCTION rv
FUNCTION IsUser32DebugVersion() : ` Nonzero if the debug version of User.exe is installed; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",22)
ENDFUNCTION rv
` --------------------------------------------------------------------------------------------------------------------
FUNCTION IsWindowsTabletEdition() : ` Nonzero if the current operating system is the Windows XP Tablet PC edition or if the current operating system is Windows Vista or Windows 7 and the Tablet PC Input service is started; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",86)
ENDFUNCTION rv
FUNCTION IsWindowsStarterEdition() : ` Nonzero if the current operating system is Windows 7 Starter Edition, Windows Vista Starter, or Windows XP Starter Edition; otherwise, 0.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",88)
ENDFUNCTION rv
FUNCTION IsWindowsMediaCenterEdition() : ` Nonzero if the current operating system is the Windows XP, Media Center Edition, 0 if not.
rv = CALL DLL(DLL_USER32,"GetSystemMetrics",87)
ENDFUNCTION rv
` --------------------------------------------------------------------------------------------------------------------
These weremade in a time of XP, many many years ago, but I assume they should work on modern windows aswell as they inherited many of the same functions.
Origionally MSon on this forum