Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 01/20/2015 in all areas

  1. DaleHohm

    LibrariesIE.au3

    File Name: IE.au3 File Submitter: DaleHohm File Submitted: 27 Mar 2013 File Category: Libraries Title: Internet Explorer Automation UDF Library for AutoIt3 Filename: IE.au3 Description: A collection of functions for creating, attaching to, reading from and manipulating Internet Explorer Author: DaleHohm Version: T3.0-0 Last Update: 9/3/12 Requirements: AutoIt3 3.3.9 or higher This version is checked into the development stream for the next AutoIt beta release, but will work with the most recently released V3.3.9.x beta. I am releasing it here so that it can get some testing now and help some people with some of the issues it fixes in the realm of COM error handling (and "the WEND error"). This file will be removed when it is included in a public beta release. Dale
    1 point
  2. UPDATED - see first post. (v1.4) More items added to right-click context menu entry. [1] Go to web page - executes the URL in default browser. [2] Copy URL to clipboard. [3] Selected Entry Detail (text only) - renamed slightly and now includes Summary on the dialog. [4] Selected Entry Detail (image + text) - GUI version with embedded IE and Image data with text. [5] Add a comment - a user comment can now be added for each ebook. [6] Get missing summary - Summary is now part of ADD, but for earlier added ebooks use this to update. [7] Get missing image data - obtaining image data is now part of ADD, but for previous ebooks without it, use this option to update. NOTES - For all ebooks added in this version, obtaining image data is attempted. It could fail, as I have done very little testing so far. However, it is important to note, that for every successful scan, a DAT file is created using the ISBN as filename and stored in a program sub-folder called Image Data. If you don't want this, just edit the INI file, and set the 'store=1' value to 4 etc. A quick way to later re-enable this option, is to simply use the 'Get missing image data' menu entry. Roughly about 25kb's is used per ebook for the DAT file, from which an image (book cover) can be seen in a browser or the program GUI (once standard HTML tags are added). The web (html) page text read, now uses a reduction factor of 4 (quarter) not 3 (third), so that Book Detail (Summary) can be read. Reduction is at start and end of a full read. As an aid to issues with the HTML read, when adding an ebook via URL, the 'reduction' text value (number of characters) is now written to the 'Settings.ini' file. Adding an ebook does not fail, when only Summary or Image Data fail to be gleaned. Any user created comment is added to the beginning of Date information and shown in the Comments field. It can also be seen in both Selected Entry Detail options. INTERESTING - The Image Data feature came about, after I discovered that the book cover image existed, when it was just a text only html file (no companion _files folder or image file). I realized it must be a text version (JavaScript, etc) of the original image. I wondered how I could utilize that, to give a nifty addition to my program. That lead me to the browser, which lead me to embedding an instance of IE. HELPFUL - In the end with this version, I had to create some INI entries that can be manually added to, as I found myself going back and forwards between my net PC and my programming one. I found a difference between the Firefox browsers on each, when it came to html tags and odd characters. These tags and characters caused issues when it came to get a Summary, and I keep coming across new ones (mostly odd characters), so hence the INI entries for each. Just add to them as you need to, by paying close attention to how the existing ones are. Basically, a pipe character separates the tags and the characters. They are further split by the colon character ':', into tags and characters on left and replacement (if any) on right. Here's some other recent ones I discovered, that you can add to the INI entry for characters (Html Replace section). P.S. Sometimes you have to laugh at yourself. After the last version, except for one thing I thought would be great, I had no real intention to do much to this program for a while, and in fact, didn't think there were many more good features to add. As usual, I was wrong. I even learnt about embedding IE and some differences with newer html tags, etc. One example of this is the old <br> tag is seen now as <BR />.
    1 point
  3. Another way: StringLower(StringLeft($sString, 1)) & StringTrimLeft($sString, 1) And another: StringRegExpReplace($sString, "(.)(.*?)$", StringLower(StringLeft($sString, 1)) & "$2") And another: StringLower(StringSplit($sString, "", 2)[0]) & StringTrimLeft($sString, 1) I could probably do this all day.
    1 point
  4. Got a working proof of concept working for tab controls. Very basic, can't move or resize the control. I'm thinking about making it so that tab items can be added to a tab control by right clicking the control and choosing to add a tab item. I got even just this far by studying '?do=embed' frameborder='0' data-embedContent>>. attachment=46008:GUIBuilder.zip dl: 22
    1 point
  5. It does not work for _IECreate, I tested earlier. Great UDF though by the way gentlemen.
    1 point
  6. TheSaint, This demonstrates using the latest version of AutoIt, what we have been talking about. You might want a Global variable when you have a filehandle open, but then people could argue even this can be done without a global variable, which they would be right in saying. #include <File.au3> #include <StringConstants.au3> Global $g_sSomeBigString = "" ; As this is only used in the Example function, why is it declared here? Global $g_hFile = FileOpen(_TempFile(), BitOR($FO_READ, $FO_OVERWRITE)) ; This is okay, as it's referenced in more than one place. OnAutoItExitRegister(OnClose) ; Register a function to call on AutoIt exit. Example() Write() ReadAndReplace() Func Example() ; $g_sSomeBigString should be called $sSomeBigString and declared using Local. For $i = 0 To 100 $g_sSomeBigString &= String($i) Next ConsoleWrite($g_sSomeBigString & @CRLF) ; Since this is only used here. Return Null ; Like void. EndFunc ;==>Example Func OnClose() FileClose($g_hFile) ; Tidy resources on exit. Return Null ; Like void. EndFunc ;==>OnClose Func ReadAndReplace() FileSetPos($g_hFile, 0, $FILE_BEGIN) Local $sFileRead = FileRead($g_hFile) ; Assign to a local variable. FileSetPos($g_hFile, 0, $FILE_BEGIN) $sFileRead = StringReplace($sFileRead, "1", "", 0, $STR_NOCASESENSE) ; Manipulate the data in the variable. ConsoleWrite($sFileRead & @CRLF) $sFileRead = "" ; Pointless as this will be destroyed once this function is returned from. Return Null ; Like void. EndFunc ;==>ReadAndReplace Func Write() FileSetPos($g_hFile, 0, $FILE_BEGIN) For $i = 0 To 1000 FileWrite($g_hFile, $i & @CRLF) Next FileSetPos($g_hFile, 0, $FILE_BEGIN) EndFunc ;==>Write Does anyone have a valid example?
    1 point
  7. TheSaint

    Web Pad (update)

    Hi folks, this is a simple little program I whipped up, due to losing two postings in 24 hours some days ago. Normally, like many of you, when I know I'm gonna write more than a few lines, for safety, I do my writing in Notepad, and then paste into a post. Same scenario for Facebook, etc. Sometimes, I forget or I end up writing far more than I initially foresaw ... or like those two incidents, I was pretty tired as well. I also had an issue where my Netbook was giving my Mouse lag from time to time, so that when I thought I was only clicking on a Firefox tab, it moved at the last millisecond and I clicked on a button, that took me to another site. Once upon a time, when not tired, and with a big red STOP button in the browser, I could react quick enough not to lose everything ... unfortunately that is no longer the case. Anyway, enough dribble. Here is a little simple basic Text Editor program/window, that has several advantages over Notepad for Forum posting, etc. No doubt it could be improved by clever enterprising minds, but it has enough nifty features to suit me, and possibly be useful to others. Source is included in zip, but be aware, it was crafted with AutoIt v3.3.0.0 so will need updating if you want to modify and not use my exe. Also be aware, that UPX was used to reduce the size of the EXE for here. The program has Autosave and remembers it's size and position, plus a floating button for quick access. Text is exported to clipboard or an active field with a few clicks. See Info menu. WARNING! WebPad uses the clipboard, to achieve elements like Case Change, Quotes, Code, Link & Tab insertion or surround. This is to speed up the process and look less clunky than using SEND. This could potentially interfere with any fancy multi-entry Clipboard program you may actively use. This issue could be coded around. NOTE - v1.3 has two more buttons (TAB and COPY), one each side of the ON TOP one. Floating restore button. Web Pad v1.3.zip 318.98 kB (76 + 422 downloads previously) NEWER VERSION (v2.5) also available - See below. See Post #14 for update detail. NOTE - If you want to keep things simple, then probably stick to the version of the program above, though there are some important bugfixes. Later versions increase in complexity, and are more targeted to my requirements. WARNING - Created and updated with AutoIt v3.3.0.0, so the script may have issues running or compiling with later versions of AutoIt. Web Pad v2.5 downloads (open the re-direction html page with your browser, don't save) Web Pad v2.5.zip Web Pad.au3 Details here. Later Screenshots (v2.0) (v2.5) Latest
    1 point
×
×
  • Create New...