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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by johnlopez2000

  1. johnlopez2000

    VBScript to extract LNK properties

    duh - THANKS - I'll try it out. ~(;-}} John Lopez Enterprise PDM Architect
  2. johnlopez2000

    VBScript to extract LNK properties

    Thanks - found this one before. I want to QUERY the info from an existing shortcut, not create a new one. Thanks John Lopez Enterprise PDM Architect
  3. johnlopez2000

    VBScript to extract LNK properties

    I have been looking on the MSDN website for a wscript code frag to extract the WshShell Shortcut target path from an existing shortcut. does anyone know how to do this? MSDN is a dead end. thanks! John Lopez Enterprise PDM Architect
  4. johnlopez2000

    nested variable expansion in namespace

    Bong - thanks. However, the idea is that b=2, and therefore the represented constructive name of the variable a2 is contructed from the char 'a' + the variable expansion of 'b' which equals 2. therefore a$b = variable name a2, and then, and expansion of a2 would yield the intermediate namespace...
  5. johnlopez2000

    nested variable expansion in namespace

    Ulis -thanks again. Please note the following: % set a2 "ns" ns % set b "2" 2 % set varname ::ns1::$a$b::var can't read "a": no such variable % set x [set $varname] can't read "varname": no such variable % John Lopez Enterprise PDM Architect
  6. johnlopez2000

    nested variable expansion in namespace

    Ulis - thanks, looks helpful. However, I was thinking more of something like the following pseudo-code: set a2 "ns" set b "2" set ::ns1::ns2::var 1 set x ${::ns1::${a${b}}::var} where: b is expanded first to replace the variable with "2" then, a2 is expanded to replace the variable with...
  7. johnlopez2000

    nested variable expansion in namespace

    Ulis - thanks. that does work. foreach x [namespace children ::xComputer] { puts [set ${x}::HomeLAN] } note that x contains the fully qualified path from xComputer through & including the sub namespace (only mod), as reported by namespace children. However, is there no way to nest or...
  8. johnlopez2000

    nested variable expansion in namespace

    I am creating a nested namespace to create structures for varied computer information. The base namespace is xComputer, then inside it is ::xComputer::${x} where x=the COMPUTERNAME. Please see code below: % namespace eval xComputer { } % set x LOCALHOST LOCALHOST % namespace eval...
  9. johnlopez2000

    Active Directory Query from VBS - get user status

    ... indeed I retract ... my statement was more from ignorance than anything ... just a beggar looking for new bread ~(;-}} Again - many thanks John Lopez Enterprise PDM Architect
  10. johnlopez2000

    Active Directory Query from VBS - get user status

    Guys - tried this out and it works great. Just did a seperate LDAP query per the above in a seperage function def and returns the info needed. Again, thanks. function GetUserAcctActivationStatus (distinguishedName) Set objUser = GetObject ("LDAP://"&distinguishedName)...
  11. johnlopez2000

    Active Directory Query from VBS - get user status

    Colleagues, thanks for the information. However, did I not 'bind' it to the user via: "(sAMAccountName="&UserName&"));" as passed to the code frag above? Should not the recordset contain the queried information? Thanks again. Your help is most appreciated particularly since I am new to AD...
  12. johnlopez2000

    Help on a script?

    try creating a VBS file, like bkup.vbs and include the following: function copyfile(xfile, yfile) Set fso = CreateObject("Scripting.FileSystemObject") fso.CopyFile xfile, yfile,TRUE set fso = Nothing end function then call it to copy the files in the main() part of your code...
  13. johnlopez2000

    Active Directory Query from VBS - get user status

    Colleagues, I have written the following function to extract users data from AD: function GetUserInformation (UserName) dim objConnection, objCommand, objRecordSet CheckUserResult = CheckUser(UserName) if CheckUserResult = "True" then Set objConnection =...
  14. johnlopez2000

    VBScript - how to load one script as a library into another

    Guys - thanks very much. Will try both methods! Appreciate your help. John John Lopez Enterprise PDM Architect john.l.lopez@goodrich.com
  15. johnlopez2000

    VBScript - how to load one script as a library into another

    Colleagues, this may be a dumb questions, but I am a relative newbie to VBScript. In TCL/TK I can load a "library" script into another script via source or other commands. How can I do the same with VBScript, where one script may only contain function calls that I want to commonize to a whole...

Part and Inventory Search

Back
Top