-
Posts
37 -
Joined
-
Last visited
Profile Information
-
Location
Dallas, TX
Max Kipness's Achievements

Seeker (1/7)
0
Reputation
-
_GUICtrlRichEdit and button focus
Max Kipness replied to Max Kipness's topic in AutoIt General Help and Support
That worked beautifully. Thanks. -
Hi, In an app I've created I recently I switched from GUICtrlCreateEdit to _GUICtrlRichEdit_Create so I could create bolding, italics on only certain characters in the edit screen. My problem is that I have a B and I button for bold and italic that steal focus. Previously with the standard edit control, when i hit the bold or italic buttons, the focus stayed on the edit control without me having to do anything. But now with _GUICtrlRichEdit_Create, when I click on the bold or italic buttons, those buttons steal the focus. Each of those buttons runs a separate function, but I can't figure out how to return the focus via the functions as GUICtrlSetState($edit,$GUI_FOCUS) doesn't seem to work for this control. Anyone have any ideas of how to fix this? Is there some type of set state command for richedit that I'm missing? Thanks in advance. Max
-
Save clipboard image to jpg file
Max Kipness replied to Max Kipness's topic in AutoIt General Help and Support
Thanks Malkey, your second snippet of code included the function that works. I'm not interested in getting screenshots, but rather wanted to get ANY image that might be in the clipboard. So it worked. Thanks again. -
Hi, Been searching around the forums and found a couple of snippets that other's claim works, but it doesn't seem to be working for me. I'm basically wanting to be able to copy and image to clipboard, or via the snipping tool in Windows 7 and then click a button that saves this to a file so I could do some further processing with it. Here is what I have.\ #include <GUIConstantsEx.au3> #Include <GDIPlus.au3> #include <ClipBoard.au3> #include <ScreenCapture.au3> _Main() Func _Main() Local $hBmp ; Capture full screen $hBmp = _ClipBoard_GetDataEx ($CF_BITMAP ) ; Save bitmap to file _ScreenCapture_SaveImage (@MyDocumentsDir & "\Image.jpg", $hBmp) EndFunc ;==>_Main Can someone please point me in the right direction. Thanks, Max
-
I've got a program that needs to download an xml file from http://rss.cnn.com/services/podcasting/newscast/rss.xml. I'm using inetget in this fashion: $dl_success1 = InetGet("http://rss.cnn.com/services/podcasting/newscast/rss.xml",@ScriptDir & "\" & "test" & ".xml",1) It seems like it used to work, but now I'm getting the same file over and over from 6/11/08. If I download this file manually using PHP and wget it shows the correct file from today 6/16/08. If I use IE 7 directly, I get the correct file from today, 6/16/08. But if I run the AutoIT script with the above command, the file has contents pointing to 6/11/08. Is this being cached somehow? If so, where? Does adding the 1 possibly not work and it's not trying to get a new version? I've tried rebooting, deleting temp files/cache from IE, etc. Any help would be appreciated. Thanks, Max
-
Hi - Does anybody happen to have this UnixTime.zip file. I need to convert a unix time/date stamp to a string date. The link that was posted in 2006 doesn't seem to work anymore. Thanks, Max
-
You know what, as I was watching you and the other guy go back an forth I never noticed your little snippet of code. I will try it and hopefully it will work for what I need. Thanks, Max
-
Cool, thanks. That makes it much easier to read. So, again this is the results from the PHP xml to array function. Works on any xml code you can throw at it. My opinion is that it's easiest to work with the data once it's in this format as it's easy to loop through the data. Max Array ( [make] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Toyota ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => MR2 ) [year] => Array ( [0] => Array ( [@attributes] => Array ( [start] => 1991 [end] => 1995 [filename] => SWF\TOYOTA_MR2_1991-1995.swf ) ) [1] => Array ( [@attributes] => Array ( [start] => 1999 [end] => 2007 ) ) ) ) [1] => Array ( [@attributes] => Array ( [name] => Supra ) ) ) ) [1] => Array ( [@attributes] => Array ( [name] => Ford ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Mustang ) [year] => Array ( [@attributes] => Array ( [start] => 2006 [end] => 2009 [filename] => SWF\FORD_MUSTANG_2006-2009.swf ) ) ) [1] => Array ( [@attributes] => Array ( [name] => GT ) ) ) ) [2] => Array ( [@attributes] => Array ( [name] => Chevrolet ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Corvette ) ) [1] => Array ( [@attributes] => Array ( [name] => Cobalt ) ) ) ) ) )
-
The XML code posted by Weaponx is a good starting point. I'm just looking for something that works on any generic xml code. As I stated I use something similar in PHP. Just throw any PHP code to it, and it creates an array. Here are the results from running Weaponx's code through my PHP parser. Sorry, but unfortunately when you post here, it flattens out all the tab spacing, so everything is left justified and hard to read. I've now played around with the XML UDF a bit and was able to extract some of the data, but it just seems like this type of approach is easier?? Array ( [make] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Toyota ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => MR2 ) [year] => Array ( [0] => Array ( [@attributes] => Array ( [start] => 1991 [end] => 1995 [filename] => SWF\TOYOTA_MR2_1991-1995.swf ) ) [1] => Array ( [@attributes] => Array ( [start] => 1999 [end] => 2007 ) ) ) ) [1] => Array ( [@attributes] => Array ( [name] => Supra ) ) ) ) [1] => Array ( [@attributes] => Array ( [name] => Ford ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Mustang ) [year] => Array ( [@attributes] => Array ( [start] => 2006 [end] => 2009 [filename] => SWF\FORD_MUSTANG_2006-2009.swf ) ) ) [1] => Array ( [@attributes] => Array ( [name] => GT ) ) ) ) [2] => Array ( [@attributes] => Array ( [name] => Chevrolet ) [model] => Array ( [0] => Array ( [@attributes] => Array ( [name] => Corvette ) ) [1] => Array ( [@attributes] => Array ( [name] => Cobalt ) ) ) ) ) )
-
Hello, does anyone know of a simple XML to Array function? I know there is an XML UDF out there and I've looked at it, but it appears to be very complex. I really just want to pull all data out into an associative array like the many XML2Array PHP scripts out there. Or is there an easy way to do this with the XML udf? Thanks, Max
-
Optimize Compiled Script
Max Kipness replied to Max Kipness's topic in AutoIt General Help and Support
Update: Just removed all the lines and comments as I had a space after almost every line and comment everyting (I'm a neat coder). This knocked off 200k roughly as the size is now 508k. Anything else I can do? Max -
Hello - I've been looking through old posts about optimizing code, and have seen some mention of programs like cleanscript and some pre-processor. These appear to clean up comments, remove functions, etc. I basically have a small script, really a wrapper for another executable which has NO includes and totals about 20 lines of code. Really very simple, no file includes, etc. Yet, when compiled, the size is 766kb. Are there any tricks to reduce this in size? Uncompiled the size is 1kb. Thanks, Max
-
Problem with socket connect to AIX
Max Kipness replied to Max Kipness's topic in AutoIt General Help and Support
Anybody have any info on this? After doing some more experimenting, it almost seems like the TCP socket support in AutoIT is not really robust. What I'm basically needing to do is telnet to aix to issue commands based on commands received. As I described below, I can't even get to the command prompt with AIX. Max -
I'm having an issue when trying to connect via port 23 (Telnet) to an AIX system. When connecting to a linux server or a Cisco router, it seems to work fine sending back a login prompt, but when connecting to an AIX server, I get only the following back "ÿþ%ÿý" and nothing else. Sending extra data does nothing, and I've tried issuing both a carriage return and line feed. If I simply drop to a command prompt in XP and type telnet 192.168.0.5, it also works fine returning the AIX server identification, asking for login, etc. Here is the basic code (generic) that I'm using to test. TCPStartup() $socket = TCPConnect("192.168.0.5",23) If $socket = -1 Then msgbox(16,"Error","Could not connect to Telnet Server") Exit Endif While 1 $recv = TCPRecv($socket,2048) TCPSend($socket,@LF) TCPSend($socket,@CR) ConsoleWrite("Received: " & $recv & @LF) sleep(1000) Wend Again, this is just test code to see what I might possibly send to the AIX server to get it to send the proper login prompt string back. When run and allowed to loop several times I get: Received: Received: ÿþ%ÿý Received: Received: Received: Received: But from the XP command prompt I get: telnet (xxx_Corp) telnetd: failed to write to /var/adm/wtmp: A file or directory in the path name does not exist. AIX Version 5 © Copyrights by IBM and by others 1982, 2005. login: As a side note, I'm able to get PHP's fsock commands working with the AIX server just fine, but I need this connection to be made from AutoIT in this case. I will need to actually login to the server, issue command, etc. I think I can handle all of this if I could get past this one issue. Could this be a terminal type problem? I don't see any other options for connecting to the socket or send data to the socket. Is there any way I can get this working? Thanks, Max
-
listview scrolling to right?
Max Kipness replied to Max Kipness's topic in AutoIt GUI Help and Support
Thanks. I was just noticing that in the help file. But now in report style, I have to figure out how to get the column widths wide enough for the text in this field. Padding with spaces only works to a certain width. I guess there is a UDF control for width. Thanks again. Max