-
excel
Hi im really struggling with this and was wondring is anyone was able to help.
I have a form in VB6 the is able to open an excel file by selection. I need to copy parts of that file in to a new excel file that is to be created using vb. Only specific cells are to be inserted in to the new file. Does anyone know how to do this please?
Any help will be greatly appreciated.
Thanks
Faye
-
Thats a bit vague.
Are the 'bits' rows, columns, only certain sections?
Are the bits easily identifyable?
1) you need to select the file
2) open an excel application (other posts in these forums on how to do that)
3) open the file in the excel you opened
4) move to the right sheet or go through each sheet searching for the easily identifyable bit
5) process said bit and output to a new spreadsheet (you could open the new workbook/sheet as you open the user selected one)
6) save output sheet
7) close both files, then close excel
8) clear all references to objects used
In Excel, you can use tools>macros>record macro
to get a general gist of what you need to use via code.
Once you have some code, post up if you are having problems.
Vince