troubleshooting Question

Filecopying using folder wildcards

Avatar of NewsInternationalLtd
NewsInternationalLtd asked on
Microsoft DOSWindows XPVB Script
9 Comments1 Solution375 ViewsLast Modified:
I need to copy a 'prefs.js' file down from the netlogon share at user logon, but the folder it needs to go into would seemingly have a random name with a '.default' at the end, eg

C:\Documents and Settings\username\Application Data\Mozilla\Firefox\Profiles\yhin11g0.default

How do I copy into this folder? It sounds such an easy problem (and maybe it is) but I've been tearing my hair out trying to do it. The usual wildcards such as * and ? only seem to work for files but not folders, eg, I am unable to use:
Copy "\\DC\NETLOGON\prefs.js" "C:\Documents and Settings\username\Application Data\Mozilla\Firefox\Profiles\*.default\"
I have also tried this with XCOPY, ROBOCOPY and VBScript to no avail. I've probably missed something obvious but if you can put me out of my misery it would be much appreciated!

Thank you
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 9 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 9 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros