Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 06/23/2018 in all areas

  1. Thanks @Danyfirex. So as a solution I'll fork the download to another process ( that would download once a second ) and get the data via IPC, to free the main script from posible timeouts waiting for the data. [Solved]
    1 point
  2. #include <String.au3> $text = "<easyAudioPlayer>easy Audio Player what's new?</easyAudioPlayer><easyAudioPlayerUpdate>Update version 3.0.0</EasyAudioPlayerUpdate>" msgBox(0, "", StringBetween($text, "<easyAudioPlayer>", "</easyAudioPlayer>")) Func StringBetween($sString, $sStart, $sEnd) Local $sReturn $sReturn = _StringBetween($sString, $sStart, $sEnd) If @error Then Return '' Return $sReturn[0] EndFunc
    1 point
  3. Interesting to see host api is now more accessible with more c++ based api https://github.com/dotnet/docs/blob/master/docs/core/tutorials/netcore-hosting.md Not enough time to study in detail but maybe others have time
    1 point
  4. Of course basically you write a file with name format like 0xXXXXXXX in script directory because InetGet does not support pass a handle so you basically past string "0x000000" and the download work correctly but you are no able to get what you expect. Also check that InetGet internally do not use FILE_READ_ATTRIBUTES and you will be not able to get the file size CreateFileW ( "0x00000224", GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE, 0x04caf7ac, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL ) You dont get any result int _WinAPI_GetFileSizeEx because the handle you pass to inetget is never used InetGet never write to that file it write to the internal created one named like 0x000000. Saludos
    1 point
  5. Hello. maybe something like this: #include <Array.au3> Local $sString = "%D8%A3%D8%B0%D9%83%D8%A7%D8%B1%20%D9%88%D8%A3%D8%AF%D8%B9%D9%8A%D8%A9/%D8%A3%D8%B0%D9%83%D8%A7%D8%B1%20%D9%85%D9%86%D9%88%D8%B9%D8%A9/%D8%A3%D8%B0%D9%83%D8%A7%D8%B1%2003.mp3" MsgBox(0, "", _MakeReadable($sString)) Func _MakeReadable($sString) Local $aReg = StringRegExp($sString, '%[0-9a-fA-F]{2}|.', 3) Local $sChar = "" Local $sReadableString="" For $i = 0 To UBound($aReg) - 1 $sChar = StringReplace($aReg[$i], "%", "") If StringLen($sChar) = 2 Then $sReadableString &= Chr("0x" & $sChar) Else $sReadableString &= $sChar EndIf Next Return BinaryToString(StringToBinary($sReadableString), 4) EndFunc ;==>_MakeTeadable Saludos
    1 point
  6. Jos

    Controlsend

    Maybe a good start is where you left off in September?
    1 point
  7. In SMF I work with a single command-line switched executable / script. On first start the main process is called, which than runs the program again with certain switches to create worker-instances of itself. Communication is done with a combo of WM_COPYDATA, switches in the SQLite Database and shared memory buffers... additionally I remember seeing examples using mailslots or shared mapped files. So in my opinion there is no "best" solution, all have their pros and cons. Using WM_COPYDATA you can interrupt the current function in the target script, using SQLite gives you persistent memory and using shared memory buffers you can transfer huge amounts of data very fast. Choose the type of inter-script communication which best fits the task at hand.
    1 point
×
×
  • Create New...