Jump to content

LarryDalooza

Active Members
  • Posts

    939
  • Joined

  • Last visited

  • Days Won

    1

Reputation Activity

  1. Like
    LarryDalooza got a reaction from pixelsearch in [SOLVED] Finding Default System Fonts   
    I am not very good at DLLStructCreate... and I have not much time... but this is some SystemParametersInfo stuff from microsoft that is supposed to return the info you want... somone else might fix it.

    #cs typedef struct tagNONCLIENTMETRICS { UINT cbSize; int iBorderWidth; int iScrollWidth; int iScrollHeight; int iCaptionWidth; int iCaptionHeight; LOGFONT lfCaptionFont; int iSmCaptionWidth; int iSmCaptionHeight; LOGFONT lfSmCaptionFont; int iMenuWidth; int iMenuHeight; LOGFONT lfMenuFont; LOGFONT lfStatusFont; LOGFONT lfMessageFont; #if (WINVER >= 0x0600) int iPaddedBorderWidth; #endif } NONCLIENTMETRICS, *LPNONCLIENTMETRICS; typedef struct tagLOGFONT { LONG lfHeight; LONG lfWidth; LONG lfEscapement; LONG lfOrientation; LONG lfWeight; BYTE lfItalic; BYTE lfUnderline; BYTE lfStrikeOut; BYTE lfCharSet; BYTE lfOutPrecision; BYTE lfClipPrecision; BYTE lfQuality; BYTE lfPitchAndFamily; TCHAR lfFaceName[LF_FACESIZE]; } LOGFONT, *PLOGFONT; #ce $nonclientmetrics = DllStructCreate("uint;int;int;int;int;int;byte[60];int;int;byte[60];int;int;byte[60];byte[60];byte[60]") DLLStructSetData($nonclientmetrics,1,DllStructGetSize($nonclientmetrics)) Global Const $SPI_GETNONCLIENTMETRICS = 41 $a = DLLCall("user32.dll","int","SystemParametersInfo","int",41, _ "int",DllStructGetSize($nonclientmetrics), _ "ptr",DllStructGetPtr($nonclientmetrics),"int",0) $b = DLLCall("kernel32.dll","int","GetLastError") MsgBox(4096,$b[0],$a[0]) $logfont1 = DllStructCreate("long;long;long;long;long;byte;byte;byte;byte;byte;byte;byte;byte;char[32]",DLLStructGetPtr($nonclientmetrics,7)) $logfont2 = DllStructCreate("long;long;long;long;long;byte;byte;byte;byte;byte;byte;byte;byte;char[32]",DLLStructGetPtr($nonclientmetrics,10)) $logfont3 = DllStructCreate("long;long;long;long;long;byte;byte;byte;byte;byte;byte;byte;byte;char[32]",DLLStructGetPtr($nonclientmetrics,13)) $logfont4 = DllStructCreate("long;long;long;long;long;byte;byte;byte;byte;byte;byte;byte;byte;char[32]",DLLStructGetPtr($nonclientmetrics,14)) $logfont5 = DllStructCreate("long;long;long;long;long;byte;byte;byte;byte;byte;byte;byte;byte;char[32]",DLLStructGetPtr($nonclientmetrics,15)) MsgBox(4096,"",DllStructGetData($logfont1,14) & @LF & _ DllStructGetData($logfont2,14) & @LF & _ DllStructGetData($logfont3,14) & @LF & _ DllStructGetData($logfont4,14) & @LF & _ DllStructGetData($logfont5,14)) Lar.
  2. Like
    LarryDalooza got a reaction from Michiel in How to check if current user has blank password in Windows   
    To check credentials use RunAs() to run a CMD at @SW_HIDE ... if it fails with blank password credentials then there must be a password...

    $err = RunAs(@UserName,@LogonDomain,"",2,"cmd /c","",@SW_HIDE)
    MsgBox(4096,"",$err & @LF & @error)
  3. Like
    LarryDalooza got a reaction from Xandy in wait for image search (help please)   
    You on the other hand are a Snarky Mole Rat
  4. Like
    LarryDalooza got a reaction from JohnOne in Something new every day   
    type 'cmd' and hit enter

    Lar.
  5. Like
    LarryDalooza got a reaction from James in Autoit Future   
    I imagine a soda machine in your basement full of "Monster" or "Amp".

    Lar.
  6. Like
    LarryDalooza got a reaction from coffeeturtle in Thank you to AutoIt Developers   
    You are welcome.

    Over the years I have introduced AutoIt into four different corporate environments. I noticed that in the less restrictive Dev/QA environments that the role of AutoIt flourishes gloriously, and in the giant restrictive bureaucratic Dev/QA environments the role of AutoIt flourishes secretly.

    Lar.
×
×
  • Create New...