Jump to content

d0n

Active Members
  • Posts

    346
  • Joined

  • Last visited

Profile Information

  • Location
    In a house

d0n's Achievements

Universalist

Universalist (7/7)

0

Reputation

  1. I downloaded a html file on my desktop, and i am trying to get the source of the file i was wondering which command i should be looking at to achieve this? _INetgetsource() doesnt seem to work "C:\...\...\...\...) or should i be using fileopen?
  2. Not sure why, but i had a script that runs quickly on my old win xp with core 2 duo cpu. Now with the new comp (i5-760, quad core) using win7 it runs extremely slow, for example sending a key to a gui is really slow are there some commands that is slower on win 7 than win xp?
  3. So i was wondering which one is faster if i want to do something like this: Check a bunch of string with StringRegExp, would it be faster to 1) Use for loop and loop till i get the correct string then exitloop OR 2) using Select Case to filter through to find the correct string For sure using the for loop will produce a much cleaner code, however i am interested in which one provides better speed thanks for help
  4. So i have this little app, what i want to do is: when i click start it will start a timer, and so on for different progressbars however I am not sure why the time will sometimes stop for 1-2 sec then continue another problem i am having is clicking multiple timers will tend to lag the previous timers, is there a better way to go about this? #include <Array.au3> #include <ProgressConstants.au3> #include <GUIConstantsEx.au3> $Form1_1 = GUICreate("Form1", 450, 150) Dim $Progress[7] $Progress[1] = GUICtrlCreateProgress(80, 10, 150, 16, $PBS_SMOOTH ) $Progress[2] = GUICtrlCreateProgress(80, 30, 150, 16, $PBS_SMOOTH ) $Progress[3] = GUICtrlCreateProgress(80, 50, 150, 16, $PBS_SMOOTH ) $Progress[4] = GUICtrlCreateProgress(80, 70, 150, 16, $PBS_SMOOTH ) $Progress[5] = GUICtrlCreateProgress(80, 90, 150, 16, $PBS_SMOOTH ) $Progress[6] = GUICtrlCreateProgress(80, 110, 150, 16, $PBS_SMOOTH ) Dim $Label[7] $Label[1] = GUICtrlCreateInput("", 8, 10, 60, 17) $Label[2] = GUICtrlCreateInput("", 8, 30, 60, 17) $Label[3] = GUICtrlCreateInput("", 8, 50, 60, 17) $Label[4] = GUICtrlCreateInput("", 8, 70, 60, 17) $Label[5] = GUICtrlCreateInput("", 8, 90, 60, 17) $Label[6] = GUICtrlCreateInput("", 8, 110, 60, 17) Dim $Button[7] $Button[1] = GUICtrlCreateButton("Start", 240, 10, 50, 17) $Button[2] = GUICtrlCreateButton("Start", 240, 30, 50, 17) $Button[3] = GUICtrlCreateButton("Start", 240, 50, 50, 17) $Button[4] = GUICtrlCreateButton("Start", 240, 70, 50, 17) $Button[5] = GUICtrlCreateButton("Start", 240, 90, 50, 17) $Button[6] = GUICtrlCreateButton("Start", 240, 110, 50, 17) Dim $Num[7] $Duration = 10 GUISetState(@SW_SHOW) $Check = False While 1 $msg = GUIGetMsg() $Add = 0 If $msg = $GUI_EVENT_CLOSE Then Exit For $a = 1 to UBound($Progress)-1 If $msg = $Button[$a] Then GUICtrlSetData($Progress[$a], 100) $Num[$a] = 100 $Change = TimerInit() EndIf Next If $Check = True Then $Change1 = TimerDiff($Change) For $a = 1 to UBound($Progress)-1 If GUICtrlRead($Progress[$a]) > 0 Then Sleep(1) $New = $Num[$a] - (($Change1/1000)/$Duration)*100 GUICtrlSetData($Progress[$a], $New) $Num[$a] = $New ConsoleWrite($Num[$a]&@LF) EndIf $Check = True Next $Change = TimerInit() WEnd
  5. I have an array like this that contains a string for StringRegExp function Dim $Array[1][5] $Array[1][0] = "(?i)\[[^]]*\] NAME(?:'s .*?)? ((?i)apple|orange)" however because of the | its splitting the array into the 2nd column how do i fix this problem?
  6. kinda off topic, but do you know any good proxy software that allows you to run a software behind a proxy?
  7. If a string has both " and ' in it, how do i quote it ?? ex. $String = Jim said "This is his' house" how do i quote it?
  8. the image is more than 9 pixels, i think each square is about 9 pixel itself then there is a black boarder around it, then some spacing between each square. The X and Y are zero based so from my example of 20 squares the red is located at X = 3 and Y = 1 zero X is the left hand column, increasing to the right , and zero Y is the bottom row increasing upwardly. the image is in JPG format
  9. So i have an image, it is formatted in a grid format like so [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] [] what i want to do is, depending on where the red part is extract only a 3x3 square of that specific image [] [] [] [] [] [] [] [] [] which function should i use to split the image into an X and Y coords (So the red in this example would be in X=3, Y=1)
  10. yes i guess you can call it a packet sniffer, is this possible with autoit? EDIT: Got it working with WinPcap, thank you!
  11. Its not that i can't recv, I can't even get a socket to the connection And the I am not hosting the server, just trying to read some packets sent between THEIR server, and MY client (i think kip's UDF only works with my server/ my client, correct me if i am wrong here, might of missed something in there)
  12. bump anyone help?
  13. Hi i have 2 listview and i was wondering what would be the best way to drag items from 1 listview to another?
  14. Hi Code that works if i start the client with autoit, i can receive the packets back TCPStartup() $socket = TCPConnect($ip, $port) ConsoleWrite("SOCKET: "&$socket&@LF) If $socket = -1 Then Exit While 1 $recv = TCPRecv ($socket, 5000) If $recv <> "" Then ConsoleWrite($recv&@CRLF) EndIf WEnd TCPShutdown() Code that doesn't work if the client is already started and talking to the server, can't get a socket TCPStartup() $socket = TCPListen($ip, $port, 100) ConsoleWrite("SOCKET: "&$socket&@LF) If $socket = -1 Then Exit While 1 $recv = TCPRecv ($socket, 5000) If $recv <> "" Then ConsoleWrite($recv&@CRLF) EndIf WEnd TCPShutdown()
×
×
  • Create New...