Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
How to create text file from selected excel data
Hi,
I'm trying to figure out how to create a plain text file based partly on data from a excel sheet. For this I beleive I must use a scripting language which can access Excel data and create a txt file. I'm working in a windows XP environment. So far, I've been wondering if vbs (VB scipt) is the solution. I'm not very familiar with VB, however, and am not sure how I should access Excel data. I'll try to explain what I wish to do with a sort of pseudo-code: BEGIN myExcelSource = new ExcelReader(c:\excelData.xls) destination = new textFile(c:\result.txt) FOR (amount_lines_in_excel_sheet) { destination.writeLine("INSERT INTO test_table (excel_data1, ....excel_dataX) VALUES (" || myExcelSource.col(X).row(Y) || ... ");") END FOR END Could anybody tell me if vbs is capable of doing this, or if I perhaps should look at another scripting language that is capable of this (or similar)? Regards, Per Magnus |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
searching a text file and importing selected data | Excel Discussion (Misc queries) | |||
Save a selected range to a new text file in excel | Excel Discussion (Misc queries) | |||
Create a new Excel file with selected cells | Excel Discussion (Misc queries) | |||
how to create a toolbar button to set selected cells to wrap text | Excel Discussion (Misc queries) | |||
How do I view a JPEG file from data selected in Excel | Excel Worksheet Functions |