/build/static/layout/Breadcrumb_cap_w.png

Scripting Question


Need a variable to access the ALLUSERSPROFILE

05/17/2013 4589 views

I have a second script that needs to verify the extraction of a zip file of another script. However the verify fails using $(KACE_DEPENDENCY_DIR) because it references the current script path.

So I need to have this script find a directory that exists in the path of another script... but for XP and Win7.  If it were just one arch, no problem, just put the explicit path.


Any 'pointers' would be appreciated! (pun intended)

0 Comments   [ + ] Show comments

Comments



Community Chosen Answer

2

Looks like $(KACE_DATA_DIR) is the ticket!


Thanks for the lead SDNBTP!

Answered 05/20/2013 by: worzie
Third Degree Brown Belt

All Answers

1

%AllUsersProfile%

Answered 05/17/2013 by: areiner
4th Degree Black Belt

  • As in "Verify that the directory “%AllUsersProfile%\Dell\KACE\kbots_cache\packages\kbots\735\WorkflowManager†exists."?
  • minus the screwed up quotations that got garbled
  • Directory does not exist: %AllUsersProfile%\Dell\KACE\kbots_cache\packages\kbots\735\WorkflowManager

    but it does
  • This content is currently hidden from public view.
    Reason: Removed by member request For more information, visit our FAQ's.
1

Are you doing this directory verify from the Kace scripting page? If so, Kace doesn't know what %AllUsersProfile% variable is. Try this instead: $(KACE_INSTALL)\kbots_cache\packages\kbots\735\WorkflowManager

If you do want to use %AllUsersProfile%, use a batch script. IF EXIST %AllUsersProfile%\Dell\KACE\kbots_cache\packages\kbots\735\WorkflowManager yourcommands or IF NOT EXIST.

Answered 05/17/2013 by: SDNBTP
Third Degree Blue Belt

  • Wish that was it. That equals: C:\Program Files\Dell\KACE\\kbots_cache\packages\kbots\735\WorkflowManager
  • I know it says it too:
    Installation directory for executables, scripts, packages, etc.
    All are synonymous. Preferred: $(KACE_INSTALL)
    5.2+ Win7/Vista C:\ProgramData\Dell\KACE
    5.2+ XP C:\Documents and Settings\All Users\Dell\KACE
    5.2+ Mac OS X /Library/Application Support/Dell/KACE/bin
    5.2+ Linux /opt/dell/kace
    5.1 Windows c:\Program Files\KACE\KBOX

    However it looked in Program Files :-/
  • What version is your kbox? For Windows these two variables are supposidly the same.

    $(KACE_INSTALL)
    5.2+ Win7/Vista C:\ProgramData\Dell\KACE
    5.2+ XP C:\Documents and Settings\All Users\Dell\KACE
    5.1 Windows c:\Program Files\KACE\KBOX

    $(KACE_DATA_DIR)
    5.2+ Win7/Vista C:\ProgramData\Dell\KACE
    5.2+ XP C:\Documents and Settings\All Users\Dell\KACE
    5.1 $(KACE_INSTALL)
    • Cough... still a bit behind: 5.3.53053
      • So I presume I'll have to fix my scripts after upgrading. Argh!
 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ