/build/static/layout/Breadcrumb_cap_w.png

Script to search file and retrieve it's size

Hi All,

I have difficulty to make a VBScript to search particular file and retrieve it's size.
I need to make a report for each computer, like this :

Computer A
asdf.dbx 100MB
qwertyu.dbx 200MB

Computer B
nvcvs.dbx 100MB
dsfdsf.dbx 150MB


Thanks

0 Comments   [ + ] Show comments

Answers (7)

Posted by: lindsamw 14 years ago
Orange Senior Belt
0
seeings how this is posted in the kbox area I will assume you have a 1000 series, why a VBScript?
Posted by: licht 14 years ago
Senior Yellow Belt
0
I need a special script (VBScript) then distribute that script by KBOX.
Because that script can't be made by scripting in KBOX.
Posted by: lindsamw 14 years ago
Orange Senior Belt
0
Sorry don't know VBScript. I could do it in AUTOIT or the KBOX though :)
Posted by: licht 14 years ago
Senior Yellow Belt
0
Hi lindsamw,
Can you kindly share to us, how to achive that using KBOX?
Thanks.
Posted by: lindsamw 14 years ago
Orange Senior Belt
0
From the manual

Template Log File Information Template This is a template that lists the values returned
from a 'Log File Information' action in a script.
Replace 'AccessedDate: ' with the actual attribute
that you returned.


You couldn't do this in the verify step, but you could do it in on success or remediation steps. I didn't readily see a list of attributes, but shouldn't be hard to do.

As an alternative, could just put it in a kbox batch file to run (do like a dir myfile.txt > c:\temp\data.txt ) and dump it to a text file or something that gets pulled in by the kbox (Look for task 'upload a file').

My preferred solution would be a Autoit script as I can control everything about the script. Autoit is free and its geared a lot more towards system administration.
Posted by: licht 14 years ago
Senior Yellow Belt
0
ORIGINAL: lindsamw

From the manual

Template Log File Information Template This is a template that lists the values returned
from a 'Log File Information' action in a script.
Replace 'AccessedDate: ' with the actual attribute
that you returned.


You couldn't do this in the verify step, but you could do it in on success or remediation steps. I didn't readily see a list of attributes, but shouldn't be hard to do.

As an alternative, could just put it in a kbox batch file to run (do like a dir myfile.txt > c:\temp\data.txt ) and dump it to a text file or something that gets pulled in by the kbox (Look for task 'upload a file').

My preferred solution would be a Autoit script as I can control everything about the script. Autoit is free and its geared a lot more towards system administration.


Thanks lindsamw
My problem is that file stored different in each machine, usually stored at :
C:\Documents and Settings\%username%\Local Settings\Application Data\Microsoft\Outlook Express\file.dbx
I need a script to search only .dbx file under that directory and retrieve it's size.
It' s good if the script can write in registry, so I can use custom inventory field to make report in KBOX reporting module.
Posted by: lindsamw 14 years ago
Orange Senior Belt
0
Sorry for the belated response, been insanely busy at work. Definitely suggest AUTOIT then :)
Rating comments in this legacy AppDeploy message board thread won't reorder them,
so that the conversation will remain readable.
 
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