Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Which function to use to open an .asc file?
Hi
Im writing a vba program to take the info from an asc file into sheet2. I must use the xldelimited so the info goes into each column properly and not just everything in one column ( it uses the comma to determine the column). The intention of the program is, in sheet1, a command button is used to open a file window. The asc file is then selected bu the user, and the data is to placed into sheet2. The asc file is no longer needed. Calculations are made and shown in sheet1 using the data in sheet2. The problem is Im not sure what function to use. Im thinking this one: object.OpenAsTextStream([iomode, [format]]) but cant get the above to work, because not too familiar with vba and need help. The excel help example doesnt real show me. Is there a website that has simple examples? Thanks Carlos |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Which function to use to open an .asc file?
The Open and OpenText methods of the Workbooks object are probably what you
want. Both methods are described in Help, with examples. Another way to get the syntax is to turn on the macro recorder and open the file manually. Then stop the recorder and look at the macro code. On Fri, 30 Jul 2004 23:32:23 -0400, Real Name wrote: Hi Im writing a vba program to take the info from an asc file into sheet2. I must use the xldelimited so the info goes into each column properly and not just everything in one column ( it uses the comma to determine the column). The intention of the program is, in sheet1, a command button is used to open a file window. The asc file is then selected bu the user, and the data is to placed into sheet2. The asc file is no longer needed. Calculations are made and shown in sheet1 using the data in sheet2. The problem is Im not sure what function to use. Im thinking this one: object.OpenAsTextStream([iomode, [format]]) but cant get the above to work, because not too familiar with vba and need help. The excel help example doesnt real show me. Is there a website that has simple examples? Thanks Carlos |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Unable to open a 82 KB XLSM file due to "Too many different cellformats" & "Converter failed to open the file." errors. | Excel Discussion (Misc queries) | |||
DGET function can't update unless linked file is open | Excel Worksheet Functions | |||
todays's function, if I open file date changes | Excel Discussion (Misc queries) | |||
In Excel - Use Windows Explorer instead of File Open to open file | Excel Discussion (Misc queries) | |||
How to insert Open File action in the IF Function? | Excel Discussion (Misc queries) |