02-10-2017 01:34 AM
Hi,
Isit possible to write a code that allows me to count the number of occurrence of a specific folder name in my User directory? For instance I would like to count the number of folder name "New folder" in my directory. Currently, I'm trying to modify the subfolder count codes but have failed to be able to count a specific folder name. Thanks in advance.
Regards,
Zamir
Solved! Go to Solution.
02-10-2017 10:37 AM
Hi Zamir,
Is this a question you want to solve with a DIAdem VBScript? Are you looking in one folder only, or are you also looking in all that folder's subfolders? Are you looking for a folder name that exactly equals "New folder", or are you looking for any folders that have a name starting with that text or have that text somewhere inside the folder name?
Brad Turpin
DIAdem Product Support Engineer
National Instruments
02-12-2017 08:49 PM
Hi Brad,
Apologies for the unclear question. Yes. I'm trying to solve this using a VBScript. So basically, Im trying to get the script to search for folders and subfolders on the desktop with the specific name. For instance, on my desktop i have 2 folders. Named "Folder 1" and "Folder 2". Within each folder there is a folder named "New Folder". So the script would specify the path to search on my desktop for the specific folder name "New Folder" and return the value.
Apologies if my english is rather poor. Hope its clearer and that you can post an approach for the solution.
Thank you.
Zamir
02-15-2017 03:17 PM
Hi Zamir,
This isn't a simple script, but it appears to do what you want. Let me know what you think and if you have any questions.
Brad Turpin
DIAdem Product Support Engineer
National Instruments
02-15-2017 10:54 PM
Hi Brad,
Thanks alot for all your help. Much appreciated. Will let you know of any issues.
Thanks again.
Regards,
Zamir