Zachlr
Active Members-
Posts
66 -
Joined
-
Last visited
Zachlr's Achievements
Wayfarer (2/7)
2
Reputation
-
AlienStar reacted to a post in a topic:
Sort a List View alphabetically when column header is clicked?
-
amin84 reacted to a post in a topic:
Sort a List View alphabetically when column header is clicked?
-
_BlockInputEx()
-
For a key that presses two keys, try something like this. HotKeySet("3", "OneAndTwo") Func OneAndTwo() Send("12") ;presses the 1 key, followed by the 2 key EndFunc For spamming the macro, you could do something like For $i = 0 To 100 OneAndTwo() Next Just read a little of the help file about the functions mentioned, and it should be easy to make a script to do this.
-
_FF_GetAllURLs() doesn't seem to return anything. The tab add-on I have installed (Tab Kit) might be causing problems with it. Can you think of any way around this, or any other way of doing it? Thanks, Zach
-
Is there any way to make a list of URLs (and possibly titles) of all open tabs using this UDF? Or any other way?
-
I believe this is because Windows acts upon a window on its own, such as closing or minimizing, as well as sending the message. Basically, what you're doing with the Case $GUI_EVENT_CLOSE Exit is telling the script to terminate when the window is closed. If you didn't, windows would close the window (due to default Windows behavior), but the process would continue to run. Ending the process is only an optional command, but it is usually included in many examples and complete scripts for proper operation of the program. The reason additional code is used, is that no action is really taken by the script when a window is minimized. It's just minimized, and the script continues normally. On the contrary, when the user presses close, he or she expects the program to terminate, so additional code is required for that. Please take a look at the Opt function, specifically "GUIEventOptions". It allows you to suppress Windows' actions when close or minimize is clicked, an just send the message. This is useful if you would like a window to "minimize to the tray" on minimize and/or close. I hope this helps you, Zach
-
Success! Thank you!
-
Thanks for the link. I think I'll be able to implement that into my script one way or another. EDIT: I'm going to look into the thread mentioned above, but I'm still opened to solutions. So, if you have anything, please tell me about it. EDIT: I'm under the impression that the method mentioned above will only work in a "per character" telnet session, not "per line". I'm not sure if it will work for my particular script. Thanks again, Zach
-
As you may know, many telnet servers only work if you do not press the backspace key throughout the entire sequence. This is because the backspace key is sent as a character, rather than actually backspacing the input. It gets frustrating when you have to type a command all over again because you pressed "S" instead of "D". Well, I'm trying to develop a function that will convert the backspace character (ascii 8) into a proper string. Here is what I have so far. $text = "hi my name is zach" & Chr(8)& Chr(8)& Chr(8)& Chr(8) ;we'll say someone meant to delete the last four characters. MsgBox(0, "", $text) ;show the original text. MsgBox(0, "", BS($text)) ;show the fixed text Func BS($String) If StringLen($String) < 2 Then Return 0 $String = StringSplit($String, "") For $i = 1 To $String[0] If $String[$i] = Chr(8) Then ;check each character for the backspace character $String[$i-1] = "" ; if it is the BS char, then erase the previous character. For $n = $i To $String[0] -1 ;- $i ; shift all of the contents left to eliminate the space $String[$n] = $String[$n+1] Next EndIf Next Return $String ;return the fixed string. EndFunc Somehow this code seems to turn $string into "" by the end of the function. If you can help me fix it, or you know of another way to accomplish this, please post a reply. Thanks, Zach
-
Seems to encounter a runtime array error when (logging in) the user enters a string that does not contain a space. This causes StringSplit($Clients[$hSocket][2], " ") to fail, and later an array element is accessed that doesn't exist. It's an easy fix though. I found that adding these four lines fixed the problem. See below. Add the below lines AFTER line 109 (line109: $Clients[$hSocket][2] = StringReplace($Clients[$hSocket][2], @CRLF, "") ) If not StringInStr($Clients[$hSocket][2], " ") Then ;if there isn't a space, get the heck out, because stringsplit will fail and will cause a runtime array error _TCP_Send($hSocket, "- Invalid login string. Remember to separate username and password by one space." & @CRLF) Return 1 EndIf Aside from that, it seems like a really good script. No other errors that I could find. It seems to work quite nicely.
-
Embed MS Explorer pane in AutoIt GUI
Zachlr replied to Zachlr's topic in AutoIt GUI Help and Support
Ah, my mistake. -
Embed MS Explorer pane in AutoIt GUI
Zachlr replied to Zachlr's topic in AutoIt GUI Help and Support
Yeah, I understand. I'm glad you're continuing to work on it though . It's a great script. I'll just have to use the full embedded window for now, but I'll keep my eye out for the finished product, if you do decide to release it in the example forum. The script you posted above didn't seem to fix the problem. Are you saying that the window must be shown in order for it to correctly redraw the AutoIt GUI? Thanks, Zach -
Embed MS Explorer pane in AutoIt GUI
Zachlr replied to Zachlr's topic in AutoIt GUI Help and Support
Hi, I really like this script. I like how it shows just the list view, but it doesn't have a path field. I suppose you could use a separate control, such as a combo box or input, as a path field, but I wouldn't know how to send that information to the list view. Additionally, the lack of a context menu isn't really a problem, and being able to make a custom context menu would be great. Unfortunately, when I ran that script, I noticed some problems. The Get Selected button seems to display 0, regardless of the selection. Moreover, the Get Selection button causes the GUI to "freak out;" rapidly activating and deactivating the window. In addition, once a folder is double clicked, it disappears, and seems to cause other items to disappear when moused-over. Again, thanks for providing this code. I really like the concept, but like I said, it has some bugs, and I wouldn't know how to fix them. I hope you can get everything working. Thanks, Zach -
Embed MS Explorer pane in AutoIt GUI
Zachlr replied to Zachlr's topic in AutoIt GUI Help and Support
Thank you very much for the example. It'll work just fine for my program. I didn't know the explorer pane could be treated as a regular ListViews. -
Embed MS Explorer pane in AutoIt GUI
Zachlr replied to Zachlr's topic in AutoIt GUI Help and Support
Thanks for the example, Mat. In fact, no resizing/moving works in my favor for this project. The problem is, I can't see any direct way of getting the selected file. Moving it to the listbox would work, but I'd really like to be able to get the selected file(s) location when a toolbar button is clicked, for example. If you could help me out with this, I'd really appreciate it. Thanks, Zach -
I'm looking to embed an MS explorer (or similar) pane in a GUI, with which the script can interact (get file paths of selected items). FileOpenDialogue() would be a cheap shortcut, and making my own embedded file explorer would be a project in itself. I hope someone can point me in the right direction. Thanks, Zach