| 1. |
Solve : Extracting data from Excel and creating folders and subfolders? |
|
Answer» I need to create a batch file that will extract data from an Excel spreadsheet to a .txt file and from there take the data and create folders and subfolders from it. Here's an example of what I need. Batch code cannot process Excel spreadsheets which have a proprietary organization. If you can save the spreadsheet as a comma separated values (CSV) file, this little snippet may work for you. And suppose a person had never used VBScript in an Office application before... Where might he find some info on how to perform the specific TASK he needs to?Technically if you write code for an Office Application within the application you use VBA. If you write code for an Office Application that runs EXTERNAL to the application you use VBScript or any other Windows Script language that can create automation objects. You can still do your original request in batch, but as mentioned batch code cannot read an Excel file directly. You can however save an Excel file as a CSV file by choosing Saveas from the File menu. When the dialog appears, give the file a name then choose CSV (comma delimited) from the save as type drop down box. The CSV file will be input to the script posted. Help with VBA and VBScript can be found all over the net. In addition each Office Application comes many pages of Help (F1). The Microsoft Script Center has a Office Section geared toward their Office products. There is a help file (script56.chm) found on most Windows installations that can help you learn all about VBScript and/or JScript. |
|