Jump to content

Recommended Posts

Posted

Correct results on XP, Vista and W7.

All 32 bit OSs though and I don't feel like setting up a VM to test 64 bit.

George

Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.

Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.***

The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number.

Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else.

"Old age and treachery will always overcome youth and skill!"

  • Administrators
Posted

3.3.7.8 (2nd June, 2011) (Beta)

Thanks to trancexx for the COM help - would have taken me weeks (if at all) to work it out.

AutoIt:

- Fixed #1908: ObjName() returns empty string for HTMLDocument with IE9.

UDFs:

- Fixed: #1859: Bug in _WeekNumberISO?

Posted

Tried to compile SMF with the Beta and the VC10 compilation clearly gives it a performance kick :huh2:... (sadly Free-AV detects AutoItSC.bin as a dropper again (heuristic?)). Thanks for the time you put into it!

Posted

I concur performance and size have been greatly improved. AutoIt now feels like a solid application with the bug tracker looking less congested :huh2:

UDF List:

 
_AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_ArrayFilter/_ArrayReduce_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_ConvertLHWebColor()/_ConvertSHWebColor()_DesktopDimensions()_DisplayPassword()_DotNet_Load()/_DotNet_Unload()_Fibonacci()_FileCompare()_FileCompareContents()_FileNameByHandle()_FilePrefix/SRE()_FindInFile()_GetBackgroundColor()/_SetBackgroundColor()_GetConrolID()_GetCtrlClass()_GetDirectoryFormat()_GetDriveMediaType()_GetFilename()/_GetFilenameExt()_GetHardwareID()_GetIP()_GetIP_Country()_GetOSLanguage()_GetSavedSource()_GetStringSize()_GetSystemPaths()_GetURLImage()_GIFImage()_GoogleWeather()_GUICtrlCreateGroup()_GUICtrlListBox_CreateArray()_GUICtrlListView_CreateArray()_GUICtrlListView_SaveCSV()_GUICtrlListView_SaveHTML()_GUICtrlListView_SaveTxt()_GUICtrlListView_SaveXML()_GUICtrlMenu_Recent()_GUICtrlMenu_SetItemImage()_GUICtrlTreeView_CreateArray()_GUIDisable()_GUIImageList_SetIconFromHandle()_GUIRegisterMsg()_GUISetIcon()_Icon_Clear()/_Icon_Set()_IdleTime()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsSystemDrive()_IsUPX()_IsValidType()_IsWebColor()_Language()_Log()_MicrosoftInternetConnectivity()_MSDNDataType()_PathFull/GetRelative/Split()_PathSplitEx()_PrintFromArray()_ProgressSetMarquee()_ReDim()_RockPaperScissors()/_RockPaperScissorsLizardSpock()_ScrollingCredits_SelfDelete()_SelfRename()_SelfUpdate()_SendTo()_ShellAll()_ShellFile()_ShellFolder()_SingletonHWID()_SingletonPID()_Startup()_StringCompact()_StringIsValid()_StringRegExpMetaCharacters()_StringReplaceWholeWord()_StringStripChars()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_Create_CTL_CODE()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()Au3 script parsingAutoIt SearchAutoIt3 PortableAutoIt3WrapperToPragmaAutoItWinGetTitle()/AutoItWinSetTitle()CodingDirToHTML5FileInstallrFileReadLastChars()GeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIEventsGUIGetBkColor()Int_Parse() & Int_TryParse()IsISBN()LockFile()Mapping CtrlIDsOOP in AutoItParseHeadersToSciTE()PasswordValidPasteBinPosts Per DayPreExpandProtect GlobalsQueue()Resource UpdateResourcesExSciTE JumpSettings INISHELLHOOKShunting-YardSignature CreatorStack()Stopwatch()StringAddLF()/StringStripLF()StringEOLToCRLF()VSCROLLWM_COPYDATAMore Examples...

Updated: 22/04/2018

Posted

SplashTextOn - Intended behavior?

You know, you should really articulate whatever point it is you are trying to get across in case others don't see it for any number of potential reasons. For example, I have no idea what you could possibly be referring to.

Posted (edited)

Jon updated IE.au3 to accomodate the change to ObjName that resulted in the "Disp" prefix disappearing from many of the HTML objects. Oddly, there is one object that retained the prefix and there is therefore one line that needs to be reverted in IE.au3.

Lines 3699:3700 are currently:

Case "elementcollection"
    If ($s_Name = "HTMLElementCollection") Then $objectOK = True

and needs to be:

Case "elementcollection"
    If ($s_Name = "DispHTMLElementCollection") Then $objectOK = True

I would have updated the ticket, but it is already closed.

Thanks,

Dale

P.S. Here is the code used to test:

#include <IE.au3>

$oIE = _IE_Example("form")
$oIE2 = _IE_Example("table")

$oTable = _IETableGetCollection($oIE, 0)
$oForm = _IEFormGetCollection($oIE, 0)
$oElem = _IEFormElementGetCollection($oForm, 0)
$oSelect = _IETagnameGetCollection($oIE, "select",0)
$oTA = _IETagnameGetCollection($oIE, "textarea",0)
$oAll = _IETagNameAllGetCollection($oIE)

ConsoleWrite(ObjName($oIE) & @CRLF)
ConsoleWrite(ObjName($oIE.document.parentWindow) & @CRLF)
ConsoleWrite(ObjName($oIE.document) & @CRLF)
ConsoleWrite(ObjName($oTable) & @CRLF)
ConsoleWrite(ObjName($oForm) & @CRLF)
ConsoleWrite(ObjName($oElem) & @CRLF)
ConsoleWrite(ObjName($oSelect) & @CRLF)
ConsoleWrite(ObjName($oTA) & @CRLF)
ConsoleWrite(ObjName($oAll) & @CRLF)


_IEQuit($oIE)
_IEQuit($oIE2)

Output:

IWebBrowser2
HTMLWindow2
HTMLDocument
HTMLTable
HTMLFormElement
HTMLInputElement
DispHTMLElementCollection
HTMLSelectElement
HTMLTextAreaElement
Edited by DaleHohm

Free Internet Tools: DebugBar, AutoIt IE Builder, HTTP UDF, MODIV2, IE Developer Toolbar, IEDocMon, Fiddler, HTML Validator, WGet, curl

MSDN docs: InternetExplorer Object, Document Object, Overviews and Tutorials, DHTML Objects, DHTML Events, WinHttpRequest, XmlHttpRequest, Cross-Frame Scripting, Office object model

Automate input type=file (Related)

Alternative to _IECreateEmbedded? better: _IECreatePseudoEmbedded  Better Better?

IE.au3 issues with Vista - Workarounds

SciTe Debug mode - it's magic: #AutoIt3Wrapper_run_debug_mode=Y

Doesn't work needs to be ripped out of the troubleshooting lexicon. It means that what you tried did not produce the results you expected. It begs the questions 1) what did you try?, 2) what did you expect? and 3) what happened instead?

Reproducer: a small (the smallest?) piece of stand-alone code that demonstrates your trouble

Posted (edited)

Here a test script I wrote where you can see the FPS counter. Best performance I get is when running it with x64 and Beta!

;coded by UEZ Build 2011-06-09
#AutoIt3Wrapper_Run_Obfuscator=y
#Obfuscator_Parameters=/sf /sv /om /cs=0 /cn=0
#AutoIt3Wrapper_Compile_both=y
;~ #AutoIt3Wrapper_UseX64=n
#AutoIt3Wrapper_UseUpx=n
#AutoIt3Wrapper_UPX_Parameters=--ultra-brute --crp-ms=999999 --all-methods --all-filters
#AutoIt3Wrapper_Run_After=del /f /q "%scriptdir%\%scriptfile%_Obfuscated.au3"
;~ #AutoIt3Wrapper_Run_After=upx.exe --ultra-brute --crp-ms=999999 --all-methods --all-filters "%out%"

#include <GDIPlus.au3>
#include <GUIConstantsEx.au3>
#include <Timers.au3>
#include <WindowsConstants.au3>

Opt("GUIOnEventMode", 1)
Opt("MustDeclareVars", 1)

_GDIPlus_Startup()

Global Const $iW = @DesktopWidth
Global Const $iW2 = $iW / 2
Global Const $iH = @DesktopHeight
Global Const $iH2 = $iH / 2

Global Const $hFullScreen = WinGetHandle("Program Manager")
Global Const $aFullScreen = WinGetPos($hFullScreen)
Global Const $main_screen_x = Abs($aFullScreen[0])

Global Const $hGUI = GUICreate("GDI+ Simple 3D Star Scrolling by UEZ", $aFullScreen[2], $aFullScreen[3], $aFullScreen[0], $aFullScreen[1], $WS_POPUP, $WS_EX_TOPMOST)
GUISetBkColor(0x000000, $hGUI)
GUISetState()

Global Const $hBitmap = _WinAPI_CreateDIB($iW, $iH)
Global Const $hDC = _WinAPI_GetWindowDC($hGUI)
Global Const $hDC_backbuffer = _WinAPI_CreateCompatibleDC($hDC)
Global Const $DC_obj = _WinAPI_SelectObject($hDC_backbuffer, $hBitmap)
Global Const $hGraphic = _GDIPlus_GraphicsCreateFromHDC($hDC_backbuffer)

Global Const $hPen = _GDIPlus_PenCreate(0, 1)
Global Const $hBrush = _GDIPlus_BrushCreateSolid(0xE0000000)
Global Const $hBrush_Text = _GDIPlus_BrushCreateSolid(0xFFF0F0F0)
Global Const $hFormat = _GDIPlus_StringFormatCreate ()
Global Const $hFamily = _GDIPlus_FontFamilyCreate ("Arial")
Global Const $hFont = _GDIPlus_FontCreate ($hFamily, 12)
Global Const $tLayout = _GDIPlus_RectFCreate ($iW - 32, 0, 0, 0)

Global Const $maxStars = 300
Global Const $speed = 50
Global Const $r = (($iW + $iH) / 2) / 0x300

Global $aStars[$maxStars][3], $j
For $j = 0 To $maxStars - 1
     NewStars($j)
Next

Global Const $om = MouseGetCursor()
Global $idle_o, $idle_n, $fps = 0
Global $fps2 = 0

GUISetOnEvent($GUI_EVENT_CLOSE , "_Exit")

OnAutoItExitRegister("_Exit")
AdlibRegister("FPS", 1000)

While Sleep(10)
    Draw_Stars()
WEnd

Func FPS()
    $fps = $fps2
    $fps2 = 0
EndFunc

Func Draw_Stars()
    $idle_n = _Timer_GetIdleTime()
    If $idle_n < $idle_o Then _Exit()
    $idle_o = $idle_n

    Local $newx, $newy, $i, $c
    GUISetCursor(16, 1, $hGUI)
    _GDIPlus_GraphicsFillRect($hGraphic, 0, 0, $iW, $iH, $hBrush)
    While $i < $maxStars
        $aStars[$i][0] += $aStars[$i][0]  / $speed
        $aStars[$i][1] += $aStars[$i][1]  / $speed
        $aStars[$i][2] += $r
        $newx = $aStars[$i][0] + $iW2
        $newy = $aStars[$i][1] + $iH2
        $c = Hex(Min($aStars[$i][2], 0xFF), 2)
        _GDIPlus_PenSetColor($hPen, "0xFF" & $c & $c & $c)
        _GDIPlus_GraphicsDrawEllipse($hGraphic, $newx, $newy, 1, 1, $hPen)
;~      If $newx < 0 Or $newx > $iW Or $newy < 0 Or $newy > $iH Then NewStars($i, $iW2 * Random(0.75, 1.25), $iH2 * Random(0.75, 1.25), $iW2 * Random(0.75, 1.25), $iH2 * Random(0.75, 1.25))
        If $newx < 0 Or $newx > $iW Or $newy < 0 Or $newy > $iH Then NewStars($i, $iW2 * _Random(0.75, 1.25, 0.95, 1.05), $iH2 * _Random(0.75, 1.25, 0.95, 1.05), $iW2 * _Random(0.75, 1.25, 0.95, 1.05), $iH2 * _Random(0.75, 1.25, 0.95, 1.05))
        $i += 1
    WEnd
    _GDIPlus_GraphicsDrawStringEx($hGraphic, $fps, $hFont, $tLayout, $hFormat, $hBrush_Text)
    _WinAPI_BitBlt($hDC, $main_screen_x , 0, $iW, $iH, $hDC_backbuffer, 0, 0, $SRCCOPY)
     $fps2 += 1
EndFunc

Func NewStars($i, $sx = 0, $sy = 0, $ex = $iW, $ey = $iH)
    $aStars[$i][0] = Random($sx, $ex, 1) - $iW2
    $aStars[$i][1] = Random($sy, $ey, 1) - $iH2
    $aStars[$i][2] = 0x00
    Return 1
EndFunc

Func Min($a, $b)
    If $a < $b Then Return $a
    Return $b
EndFunc

Func _Random($min, $max, $emin, $emax, $int = 0) ;exludes from emin to emax
    Local $r1 = Random($min, $emin, $int)
    Local $r2 = Random($emax, $max, $int)
    If Random(0, 1, 1) Then Return $r1
    Return $r2
EndFunc

Func _WinAPI_CreateDIB($iWidth, $iHeight, $iBitsPerPel = 32) ;taken from WinAPIEx.au3 by Yashied
    Local $tBIHDR, $hBitmap, $pBits
    Local Const $BI_RGB = 0, $DIB_RGB_COLORS = 0
    Local Const $tagBITMAPINFOHEADER = 'dword biSize;long biWidth;long biHeight;ushort biPlanes;ushort biBitCount;dword biCompression;dword biSizeImage;long biXPelsPerMeter;long biYPelsPerMeter;dword biClrUsed;dword biClrImportant'
    $tBIHDR = DllStructCreate($tagBITMAPINFOHEADER)
    DllStructSetData($tBIHDR, 'biSize', DllStructGetSize($tBIHDR))
    DllStructSetData($tBIHDR, 'biWidth', $iWidth)
    DllStructSetData($tBIHDR, 'biHeight', $iHeight)
    DllStructSetData($tBIHDR, 'biPlanes', 1)
    DllStructSetData($tBIHDR, 'biBitCount', $iBitsPerPel)
    DllStructSetData($tBIHDR, 'biCompression', $BI_RGB)
    $hBitmap = _WinAPI_CreateDIBSection(0, $tBIHDR, $DIB_RGB_COLORS, $pBits)
    If @error Then Return SetError(1, 0, 0)
    Return $hBitmap
EndFunc   ;==>_WinAPI_CreateDIB

Func _WinAPI_CreateDIBSection($hDC, ByRef $tBITMAPINFO, $iUsage, ByRef $pBits, $hSection = 0, $iOffset = 0) ;taken from WinAPIEx.au3 by Yashied
    $pBits = 0
    Local $Ret = DllCall('gdi32.dll', 'ptr', 'CreateDIBSection', 'hwnd', $hDC, 'ptr', DllStructGetPtr($tBITMAPINFO), 'uint', $iUsage, 'ptr*', 0, 'ptr', $hSection, 'dword', $iOffset)
    If @error Or (Not $Ret[0]) Then Return SetError(1, 0, 0)
    $pBits = $Ret[4]
    Return $Ret[0]
EndFunc   ;==>_WinAPI_CreateDIBSection

Func _Exit()
    AdlibUnRegister("FPS")
    GUISetCursor($om, 1, $hGUI)
    _GDIPlus_FontDispose ($hFont)
    _GDIPlus_FontFamilyDispose ($hFamily)
    _GDIPlus_StringFormatDispose ($hFormat)
    _GDIPlus_PenDispose($hPen)
    _GDIPlus_BrushDispose($hBrush)
    _GDIPlus_BrushDispose($hBrush_Text)

    _GDIPlus_GraphicsDispose($hGraphic)
    _WinAPI_SelectObject($hDC, $DC_obj)
    _WinAPI_DeleteObject($hBitmap)
    _WinAPI_ReleaseDC($hGUI, $hDC)

    _GDIPlus_Shutdown()
    GUIDelete($hGUI)
    Exit
EndFunc

Win7 X64, i5 540M@2400 MHz, 1680x1050

Compiled with 3.3.6.1:

x86: ~23 fps

x64: ~25 fps

Compiled with 3.3.7.9:

x86: ~24 fps

x64: ~25 fps

Not so much difference between old and new version for this particular example.

Br,

UEZ

Edited by UEZ

Please don't send me any personal message and ask for support! I will not reply!

Selection of finest graphical examples at Codepen.io

The own fart smells best!
Her 'sikim hıyar' diyene bir avuç tuz alıp koşma!
¯\_(ツ)_/¯  ٩(●̮̮̃•̃)۶ ٩(-̮̮̃-̃)۶ૐ

  • Administrators
Posted

You know, you should really articulate whatever point it is you are trying to get across in case others don't see it for any number of potential reasons. For example, I have no idea what you could possibly be referring to.

Yeah, I'm no clearer either. I fixed a bug in there but can't think of any functionality change it would have caused.
Posted

No. Just lost now that school is out.

Then you should have plenty of time on your hands to actually articulate things instead of posting incredibly cryptic messages that make no sense to anyone outside yourself.
  • Administrators
Posted

3.3.7.9 (6th June, 2011) (Beta)

A couple of COM issues fixed and a lot of internal COM changes. Thanks to trancexx for the extensive help.

- Fixed #1658: COM / OLE object access causes error code 80020003 - member not found.

- Fixed #1410: Using Pointer type with COM-object throws error. (thanks trancexx)

Guest
This topic is now closed to further replies.
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...