SciTE4AutoIt cannot be downloaded by Winget
-
Recently Browsing 0 members
No registered users viewing this page.
-
Similar Content
-
By Jemboy
Hi,
For an internal project I want to write internal script to mail some special request to an external party.
To make it a little bit universal I decided that the user should be able to write or edit the e-mail signature.
Because I wanted to put a logo into the e-mail, I decided to use RichEdit.
I I found the following code by @UEZ and adapted it a little to save and load.
When I start the script and edit the text only, I can save and load the signature.rtf.
However the moment I resize one of the images (with the mouse), the script wil only save the edited image.
Somehow resizing an image deletes the other content of the RichEdit object.
Does anyone know a solution for me?
P.s. you need to delete signature.rtf to reset the file.
#include <GDIPlus.au3> #include <GUIConstantsEx.au3> #include <GuiRichEdit.au3> #include <WindowsConstants.au3> Example() Func Example() Local $hGui, $iMsg, $idBtnExit, $hRichEdit $hGui = GUICreate("Example (" & StringTrimRight(@ScriptName, StringLen(".exe")) & ")", 520, 550, -1, -1) $hRichEdit = _GUICtrlRichEdit_Create($hGui, "", 10, 10, 500, 490, BitOR($ES_MULTILINE, $WS_VSCROLL, $ES_AUTOVSCROLL)) $idBtnExit = GUICtrlCreateButton("Exit", 10, 510, 40, 30) $GoodRead = False If FileExists(@ScriptDir & "\signature.rtf") Then $ResSFF = _GUICtrlRichEdit_StreamFromFile($hRichEdit, @ScriptDir & "\signature.rtf") If $ResSFF=true then $GoodRead = True EndIf If $GoodRead=False Then _GUICtrlRichEdit_InsertText($hRichEdit, "Inserting image..." & @LF & @LF) _GUICtrlRichEdit_InsertText($hRichEdit, @LF & "JPG image scaled:" & @LF & @LF) _GUICtrlRichEdit_InsertBitmap($hRichEdit, "c:\Program Files (x86)\AutoIt3\Examples\GUI\mslogo.jpg", "\qc", "\picw6747\pich1058\picwgoal6690\pichgoal1860\") ;\qc = centered _GUICtrlRichEdit_InsertText($hRichEdit, @LF & @LF & "PNG image:" & @LF & @LF) _GUICtrlRichEdit_InsertBitmap($hRichEdit, "c:\Program Files (x86)\AutoIt3\Examples\GUI\Torus.png") _GUICtrlRichEdit_InsertText($hRichEdit, @LF & @LF & "Done.") EndIf GUISetState(@SW_SHOW) While True Switch GUIGetMsg() Case $GUI_EVENT_CLOSE, $idBtnExit _GUICtrlRichEdit_StreamToFile($hRichEdit, @ScriptDir & "\signature.rtf") _GUICtrlRichEdit_Destroy($hRichEdit) ; needed unless script crashes GUIDelete() Exit EndSwitch WEnd EndFunc ;==>Example Func _GUICtrlRichEdit_InsertBitmap($hWnd, $sFile, $sFormatFunctions = "\", $sBitmapFunctions = "\", $iBgColor = Default) ;coded by UEZ build 2016-02-16 If Not FileExists($sFile) Then Return SetError(0, 0, 1) If Not _WinAPI_IsClassName($hWnd, $__g_sRTFClassName) Then Return SetError(0, 0, 2) _GDIPlus_Startup() Local $hImage = _GDIPlus_ImageLoadFromFile($sFile) If @error Then _GDIPlus_Shutdown() Return SetError(0, 0, 3) EndIf Local Const $aDim = _GDIPlus_ImageGetDimension($hImage) Local Const $hBitmap = _GDIPlus_BitmapCreateFromScan0($aDim[0], $aDim[1]), $hGfx = _GDIPlus_ImageGetGraphicsContext($hBitmap) If $iBgColor = Default Then $iBgColor = 0xFF000000 + _WinAPI_SwitchColor(_GUICtrlRichEdit_GetBkColor($hWnd)) EndIf _GDIPlus_GraphicsClear($hGfx, $iBgColor) _GDIPlus_GraphicsDrawImageRect($hGfx, $hImage, 0, 0, $aDim[0], $aDim[1]) _GDIPlus_GraphicsDispose($hGfx) Local $binStream = _GDIPlus_StreamImage2BinaryString($hBitmap, "BMP") If @error Then _GDIPlus_ImageDispose($hImage) _GDIPlus_ImageDispose($hBitmap) _GDIPlus_Shutdown() Return SetError(0, 0, 4) EndIf Local $binBmp = StringMid($binStream, 31) Local Const $binRtf = "{\rtf1\viewkind4" & $sFormatFunctions & " {\pict{\*\picprop}" & $sBitmapFunctions & "dibitmap " & $binBmp & "}\par}" ;check out http://www.biblioscape.com/rtf15_spec.htm _GUICtrlRichEdit_AppendText($hWnd, $binRtf) $binStream = 0 $binBmp = 0 _GDIPlus_ImageDispose($hImage) _GDIPlus_ImageDispose($hBitmap) _GDIPlus_Shutdown() Return 1 EndFunc ;==>_GUICtrlRichEdit_InsertBitmap Func _GDIPlus_StreamImage2BinaryString($hBitmap, $sFormat = "JPG", $iQuality = 80, $bSave = False, $sFileName = @ScriptDir & "\Converted.jpg") ;coded by UEZ 2013 build 2014-01-25 (based on the code by Andreik) Local $sImgCLSID, $tGUID, $tParams, $tData Switch $sFormat Case "JPG" $sImgCLSID = _GDIPlus_EncodersGetCLSID($sFormat) $tGUID = _WinAPI_GUIDFromString($sImgCLSID) $tData = DllStructCreate("int Quality") DllStructSetData($tData, "Quality", $iQuality) ;quality 0-100 Local $pData = DllStructGetPtr($tData) $tParams = _GDIPlus_ParamInit(1) _GDIPlus_ParamAdd($tParams, $GDIP_EPGQUALITY, 1, $GDIP_EPTLONG, $pData) Case "PNG", "BMP", "GIF", "TIF" $sImgCLSID = _GDIPlus_EncodersGetCLSID($sFormat) $tGUID = _WinAPI_GUIDFromString($sImgCLSID) Case Else Return SetError(1, 0, 0) EndSwitch Local $hStream = _WinAPI_CreateStreamOnHGlobal() ;http://msdn.microsoft.com/en-us/library/ms864401.aspx If @error Then Return SetError(2, 0, 0) _GDIPlus_ImageSaveToStream($hBitmap, $hStream, DllStructGetPtr($tGUID), DllStructGetPtr($tParams)) If @error Then Return SetError(3, 0, 0) Local $hMemory = _WinAPI_GetHGlobalFromStream($hStream) ;http://msdn.microsoft.com/en-us/library/aa911736.aspx If @error Then Return SetError(4, 0, 0) Local $iMemSize = _MemGlobalSize($hMemory) If Not $iMemSize Then Return SetError(5, 0, 0) Local $pMem = _MemGlobalLock($hMemory) $tData = DllStructCreate("byte[" & $iMemSize & "]", $pMem) Local $bData = DllStructGetData($tData, 1) _WinAPI_ReleaseStream($hStream) ;http://msdn.microsoft.com/en-us/library/windows/desktop/ms221473(v=vs.85).aspx _MemGlobalFree($hMemory) If $bSave Then Local $hFile = FileOpen($sFileName, 18) If @error Then Return SetError(6, 0, $bData) FileWrite($hFile, $bData) FileClose($hFile) EndIf Return $bData EndFunc ;==>_GDIPlus_StreamImage2BinaryString
-
By Professor_Bernd
PSPad4AutoIt3 v2.0.0 beta (2021-04-16)
All parts are freeware.
PSPad4AutoIt3 consists of the Editor PSPad and the Improvement Kit, and can be used as an portable editor IDE for AutoIt3.
The author of the PSPad Editor is Jan Fiala.
I (Professor Bernd) am only the author of the Improvement Kit.
Contact us:
This is the first fully portable version of PSPad4AutoIt3.
There are a lot of changes and new features, e.g.
- a separate AutoIt3 menu in the PSPad main menu,
- the shortcuts are SciTE-like,
- Tidy for Au3,
- in CallTipViewer a recognition for writing "(",
- a dialog for registering file extensions with Pau3,
- a nice about dialog in "90s style",
- the CodeExplorer can now be displayed together with the FavTools on the right side,
( so the panel on the left side can be completely hidden )
- and much more ...
See here for details
All in all a lot has been done and it is worth to have a look Praise, criticism, ideas, tips and hints on bugs are welcome. Have fun with the new features!
Thank you very much,
Professor Bernd.
Special thanks for the friendly support goes to:
Jan Fiala (Author of PSPad)
Jos van der Zande (Author of AutoIt3Wrapper, Tidy, ...)
alpines (suggestions, ideas, testing, design for syntax colors, develop routines)
argumentum (feedback, suggestions, ideas)
AspirinJunkie (RegExp pattern, ideas and code snippets)
Bitnugger (suggestions, ideas and code snippets)
BugFix (suggestions, ideas and code snippets)
Gun-Food (for making it possible to publish the project here)
LarsJ (VBScript<->AutoIt communication, …)
Musashi (suggestions and ideas)
Credits for many other contributors can be found in the Pau3 About dialog.
PSPad4AutoIt3 v2.1.0 beta - Update (2021-05-02)
See here for details v2.1.0 beta - Update
Download in the german forum PSPad4AutoIt3 (Editor IDE), end of post #1 -
By Mbee
Hi, @Jos and others!
I've been running SciTE4AutoIt3 under Windows 7 Pro then Windows 10 Pro for years with a dual-monitor setup. What an awesome set of tools! I'm using version 4.4.6, 32-bit - aka SciTE4AutoIt3 v21.316.1639.2
Until two days ago, when I double-clicked an au3 file, SciTE opened it's window on my secondary monitor, which is just where I wanted it. But now, all of a sudden, it always opens on the primary monitor, which is just where I don't want it! UltraEdit and Notepad++ always open on the monitor where the last window was opened, which is fine. But not SciTE4AutoIt3.
It's possible that this problem is related to a newly encountered issue wherein Windows apparently arbitrarily decided that the desktop on the secondary at the long-standing resolution of 1920x1080 should no longer fit the display. I booted up a few days ago to find that the taskbar was no longer visible and the other three edges wouldn't fit either. I was forced to change the resolution to 1680x1050. Perhaps SciTE4AutoIt3 will automatically choose the monitor with the highest resolution?
To try to solve this issue myself, I've examined all the Options files, but I can't find anything related to monitors. How can I get SciTE to open on my secondary monitor again?
Thanks!
-
By Jahar
I have an AutoIT script It monitors 2 websites for content that applys to me and the services that I provide. One site is : www.Freelancer.com The other: www.PeoplePerHour.com Both sites publish new jobs on their site hourly or so. My AutoIT app, will view those sites and present new jobs to me in a grid that pops up on my screen. Lately, the app has stopped showing me any jobs from PeoplePerHour.
For freelancer.com, Inetget is giving full html but for peopleperhour, now its not coming.
Func _CheckPPH()
Local Static $hTimer = 0
Local Static $hDownload = 0
Local $aTitlesandUrls = 0
Local Static $sTempFile = ""
If $hTimer = 0 Then $hTimer = TimerInit()
If $hDownload = 0 Then
$sTempFile = _WinAPI_GetTempFileName(@TempDir)
ConsoleWrite("Checking PPH..." & @CRLF)
ConsoleWrite(">Downloading..." & @CRLF)
;~ $hDownload = InetGet("http://www.peopleperhour.com/freelance-jobs", $sTempFile, $INET_FORCERELOAD, $INET_DOWNLOADBACKGROUND)
$hDownload = InetGet("http://www.peopleperhour.com/freelance-jobs", $sTempFile, $INET_FORCERELOAD)
;~ Return 0
EndIf
;~ Sleep(30)
;~ Local $isCompleted = InetGetInfo($hDownload, $INET_DOWNLOADCOMPLETE)
;~ Local $isError = InetGetInfo($hDownload, $INET_DOWNLOADERROR)
;~ Sleep(30)
;~ If TimerDiff($hTimer) > 3000 And $isError Then
;~ ConsoleWrite("!PPH Fail" & @CRLF)
;~ InetClose($hDownload)
;~ $hDownload = 0
;~ Return 0
;~ EndIf
;~ Sleep(30)
Local $Show = 0
;~ If TimerDiff($hTimer) > 3000 And $isCompleted Then
If $hDownload > 0 Then
ConsoleWrite("+Downloaded..." & @CRLF)
Local $sPPHHtml = FileRead($sTempFile)
$aTitlesandUrls = _StringBetween($sPPHHtml, '"title">' & @LF, 'time>')
;~ _ArrayDisplay($aTitlesandUrls)
Local $aPPH[0][4]
Local $sTitle = ""
Local $sUrl = ""
Local $sID = ""
Local $sDate = ""
Local $iRet=0
Sleep(30)
For $i = 0 To UBound($aTitlesandUrls) - 1
$sTitle = _StringBetween($aTitlesandUrls[$i], '<a title="', '" class')
$sUrl = _StringBetween($aTitlesandUrls[$i], 'href="', '">')
$sDate = _GetDate($aTitlesandUrls[$i])
If IsArray($sTitle) And IsArray($sUrl) Then
$sID = _GetID($sUrl[0])
;~ _ArrayAdd($aPPH, $sDate & "|" & $sTitle[0] & "|" & $sUrl[0] & "|" & $sID)
$iRet = _BuildPopupsPPH($sID, $sDate, "PPH: " & $sTitle[0], $sUrl[0])
If $iRet Then $Show+=1
EndIf
Next
Sleep(30)
;~ If $Show > 0 Then ShowLatestJobs()
;~ _ArrayDisplay($aPPH)
FileDelete($sTempFile)
InetClose($hDownload)
$hDownload = 0
$hTimer = 0
Return $Show
EndIf
Sleep(30)
EndFunc ;==>_CheckPPH
-
By singh54
Hello All,
I am new to auto It and coding. Have only tried few automated logging for different websites. The login pages of the websites which I have worked on were having form name with input type as text and it seems straight forward to automate their login using "_IEFormElementSetValue".
I have got a url, it does not have any form in the source page. On further analyzing I found that It does call some login page separately as below.
function showLogin(arg) {
Global.pollingDialogDoc = null;
var fresh = jQuery.isValidString(arg) && "fresh" == arg ? !0 : !1, appFrame = $("#appFrame");
if ($("#modalFrame").show(), $("iframe").hide(), fresh || !appFrame.attr('src').match("html/login.html")) appFrame.attr('src', baseURL + 'html/login.html'),
appFrame.on('load', function() {
setTimeout(function() {
$("#modalFrame").hide(), appFrame.show();
}, 1);
}); else try {
window.frames.appFrame.updatePageFromIndex();
} catch (e) {}
}
I can simply use "send" and "mouse click" Method to automate the login but that doesn't seems very reliable. Is there any separate way to fill the user ID and password to the respective fields by having reference by frames or something.
Appreciate if any one can point me to correct document or help in any way...!
-
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now