Jump to content

hannes08

Active Members
  • Posts

    940
  • Joined

  • Last visited

  • Days Won

    2

hannes08 last won the day on September 26 2012

hannes08 had the most liked content!

Profile Information

  • Member Title
    my oh my
  • Location
    Germany

Recent Profile Visitors

599 profile views

hannes08's Achievements

Universalist

Universalist (7/7)

40

Reputation

  1. What you are looking for are associative arrays. Check the UDF by Nutster: '?do=embed' frameborder='0' data-embedContent>>
  2. Hello Melba, maybe this is a bit off-topic, but you may want to consider to add a "Cancel Script" button to that GUI. So you don't need to cancel the script via the task-bar buttons in case of debugging. Regards, Hannes
  3. Hello Mirus, all you suggested is possible, but I would not use Excel as a "temporary" storage to hold data and even look for the data. You could instead either use the tools JLogan mentioned or an internal 2-dimensional array (if you're not planing on storing the data longer than your program runs). After you've finished entering all of your data you can use the internal _ExcelWrite* functions to fill a new Excel sheet or workbook.
  4. You cannot listen to the global IP as it belongs to your local router. You also need to create a port forwarding on that device in order to make this working. Or a third party server in the middle where both PCs can connect to to receive the commands.
  5. Well, I never really understood why you'll need a function to create a new empty file. :-D
  6. Hello Hyflex, you can use a WMI query to the Win32_OperatingSystem class to get the value for lastbootuptime. From there you can find out for how long the PC has been running.
  7. Hello Fred, if you use FileOpen("<yourfile>", 9) it automatically creates your directories and the file if it doesn't exist. This information can be found in the helpfile under FileOpen() as well. Take your time and look at the description of the parameters in the helpfile it is really usefull.
  8. Hi, did you try using the _IE*() functions?
  9. Hi enaiman, in version 1.6.2 you added the feature that the script exits on an occured error. Yet in the function _ShowSNMPReceived you are using a Return SetError(1) after throwing the error. Maybe this is by design in version 1.7.4. ;-) I would prefer that the pachet yout be output to any place set by user and that the _ThrowError function did not exit the whole script.
  10. Thanks guys, I will try both of your solutions and report what I found.
  11. Hi Folks, I have a small GUI application that writes to a text file. This is basically the part of the script: $fh = FileOpen("Test.txt", 9) ;Append at the end of the File and create the dir structure if it doesn't exist FilewriteLine($fh, "Bli bla blubb...") ;Write 1 - many lines to the file FileClose($fh) So ... sometimes while that application is running, there is another file that does something like this: $fh = FileOpen("Test.txt", 2) ;Open file, erase the contents FileClose($fh) Okay, so basically that is bad, because it results in the first script writing several "NULL"s to the file, so if I try to read that file with another script and _FileReadToArray() it basically exits with RC 2 (Unable to split the file). So the question is: Can I detect that the first file is already opened by an application? Maybe I need to mention that the files is stored on a network drive. Any comments are welcome.
  12. Maybe the OP should start reading the Tutorial / Helpfile first.
  13. So, did you try the As a result you get a 2D Array (zero based) and two variables that give you the amount of columns and rows. Now it's a simple fact of looping... Example: For $i = 0 To $iRows For $j = 0 To $iColumns MsgBox(0,"Row, Col", $i & ", " & $j) Next Next Oh and by the way there is no problem using this in queries with multiple tables!
  14. The OP doesn't state what kind of sql DB he uses - would be interesting to know. I just assumed he uses a MS SQL (Express) server...
  15. Hello Sardinha, try using the #RequireAdmin keyword on top of your script.
×
×
  • Create New...