Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. Geates

    Label Not Defined ERROR

    I'm a huge proponent of SELECT CASE. The main advantage is speed. In a SELECT, the condition is evaluated once, then jumps to the appropriate case whereas with an ELSEIF, each condition is evaluated! Take your code for example (sorry, I don't do line numbers :) and thus almost never use GOSUB...
  2. Geates

    Label Not Defined ERROR

    You mean GOSUB and GOTO. There isn't a sub named 300. I'm post-line numbers so, I might be wrong.
  3. Geates

    MapEdit

    A couple decades too late and architecturally obsolete. -Geates
  4. Geates

    Access to QLB variables.

    This is the QBasic forum, right? And what does the Absolute Value have to do with anything? I wanted to access the screen clipping variables within the DirectQB library but I came up with alternate solution.
  5. Geates

    Access to QLB variables.

    Is there a way to access variables in a QuickLibrary? Maybe with CALL ABSOLUTE?
  6. Geates

    Why are static variables not printed

    this: class Test { public $A; public $B; public static $C; } $test = new Test(); print_r($test); var_dump($test); yields: Test Object ( [A] => [B] => ) object(Test)#1 (2) { ["A"]=> NULL ["B"]=> NULL } Where is the static var C?
  7. Geates

    Need help inserting array info into a table

    Can't say for sure, but I have a negative premonition. Notice that $ext, $secret, $macaddress, and $templatename are now all arrays, containing multiple values, but you are only running one query. Modify your code to execute three queries, one for each set of values. for (var $i = 0; i++; i...
  8. Geates

    Need help inserting array info into a table

    Where is $phone and $TName defined? It appears they are blank. Binding a blank values may produce a valid query but not one that you intend to execute. Also, bind_param() is not a PDOStatement method and results in a fatal error upon execution. That being said, I would venture the bet that...
  9. Geates

    Need help inserting array info into a table

    what is the output of $_POST?
  10. Geates

    Need help inserting array info into a table

    Quick and Dirty: Inside the while loop, assign the values of 'extension' and 'secret' to hidden inputs where the name is an array. <input type="hidden" name="extensions[]" value="<? echo $row['extension']; ?>"> <input type="hidden" name="secrets[]" value="<? echo $row['secret']; ?>">...
  11. Geates

    Static variables and functions

    Vacunita, that is an awesome answer to a question I could not articulate! -Geates
  12. Geates

    Static variables and functions

    I am under the impression that defining something as static is to define the var or function in a global scope. One of the first things I learned in programming is not too define things in a global scope (of course, that was back when qbasic was widely used). I was thinking about it last night...
  13. Geates

    Static variables and functions

    I'm hesitant about using static variables and functions in classes. It seems as though they are becoming commonplace for simplicity sake - but there are always two sides to a coin. What is your argument and why? -Geates
  14. Geates

    Count occurrences with regex

    Thanks, feherke. I like the cleanliness of you first solution but my complexity is configurable so I'll implement the second solution. -Geates
  15. Geates

    Count occurrences with regex

    Currently, I am using a foreach() loop to count the occurrences of numbers in a string...and to count uppercase letters...and to count lowercase letter...and to count special chars. I feel like there is a "simpler" to do it with regex. Is there? $n = 0; $string_as_array =...
  16. Geates

    Run command line in the background using vbs

    the window that opens is the "RunsAs" command called by oShell.Run. According to RunAs /?, there is no "hide" option. It appears child processes are hidden but you can try to run the oShell.Run in a hidden state. oShell.run ("RunAs /noprofile /user:%computername%\postgres " & Chr(34) & "cmd...
  17. Geates

    Delete Lines from Text File that DO NOT contain...

    I'm not sure if this the correct way to go about it but it works: .Pattern = "(.+,){3}(?![AR|BR]{2}).*?(\r\n|$)|(\r\n)(\r\n)" http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm
  18. Geates

    Delete Lines from Text File that DO NOT contain...

    .Pattern = "(.+,){3}[AR|BR]{2}.*?(\r\n|$)|(\r\n)(\r\n)" -Geates http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm
  19. Geates

    Delete Lines from Text File that DO NOT contain...

    oops. bad regex pattern. strongm can correct it if this wrong but try: objRegEx.pattern = "^[R|T|C|U|F|V|H]" -Geates http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm
  20. Geates

    Delete Lines from Text File that DO NOT contain...

    take out the "not" -Geates http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm

Part and Inventory Search

Back
Top