~1 in my foldernames

Anything VBScript-related, including Windows Script Host, WMI, ADSI, and more.
Forum rules
Do not post any licensing information in this forum.

Any code longer than three lines should be added as code using the 'Select Code' dropdown menu or attached as a file.
This topic is 16 years and 5 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked
User avatar
cpratt
Posts: 1
Last visit: Mon Oct 15, 2007 4:33 am

~1 in my foldernames

Post by cpratt »

Hi there,I'm having some trouble with a script I wrote to organize a bunch of files (like 300,000 or so) into folders based on the files last modified date. The script works great except one problem. It adds an invisible ~1 to the end of each folder name that it creates. You can only see the ~1 by doing "dir /x /a" from a dos shell. the problem with this is that you can't rename or delete the folders that the script created with the explorer. You have to rename them in the dos shell first. Here is a snippet of the code I used to create a folder. scrubdatestamp is created by pulling the files last modifed date and cleaning it down to mmddyyyy format.Set args = WScript.Argumentslocpath = args.Item(0)fpath = locpath & scrubdatestamp & ""objFSO.CreateFolder(fpath)Thanks
This topic is 16 years and 5 months old and has exceeded the time allowed for comments. Please begin a new topic or use the search feature to find a similar but newer topic.
Locked