Need VBScript code to Delete Multiple Files at once.
Posted on 2007-04-05
Through VBScript I need to delete multiple files using wildcards as the files that need to be deleted are numbered or called something different dependent upon the type of data contained in the file. The one common value is the Id. I can delete a single file no problem - but have not found a way within VBScript to delete files based on a wildcard. I could have a file, RID123.xml and a file CID123Drill.xml and a file called RID123Drill1.xml, RID123Drill2.xml.. What I don't know is the RID123Drill1 or Drill2 as these # are random - I don't know them. So what I am hoping to do is DELETE(RID123Drill*.XML) or something similar.