Re: $$Excel-Macros$$ prompting for files for data import

2011-10-06 Thread Seba
> >> mystring = myfolder & startname & i & endname > >> MsgBox mystring > >> With ActiveSheet.QueryTables.Add(**Connection:="TEXT;" _ > >> & mystring & ".csv", Destination:=Range("A1")) > > >> &#

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread Sam Mathai Chacko
To 3 >> mystring = myfolder & startname & i & endname >> MsgBox mystring >> With ActiveSheet.QueryTables.Add(**Connection:="TEXT;" _ >> & mystring & ".csv", Destination:=Range("A1")) >> >> 'your stuff >>

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread Sam Mathai Chacko
e.' >> for i= 1 to 3 >> Sheets("sourcesheet").**QueryTables.Add(Connection:= _ >> "TEXT;Path to my file" & I &".csv", Destination:= >> sheets("sourcesheet).range("**a1") >> 'etc >> copy range("

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread dguillett1
to other sheet next i end sub -Original Message- From: Seba Sent: Wednesday, October 05, 2011 10:51 AM To: MS EXCEL AND VBA MACROS Subject: Re: $$Excel-Macros$$ prompting for files for data import Thank you for your help, however, if I understand your suggestion correctly, this would s

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread Sam Mathai Chacko
t; "TEXT;Path to my file" & I &".csv", Destination:= > > sheets("sourcesheet).range("a1") > > 'etc > > copy range("a2:z4") sheets("destinationsheet").range("a1") > > > > next i > > &g

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread Seba
ot;sourcesheet").QueryTables.Add(Connection:= _ >   "TEXT;Path to my file" & I &".csv", Destination:= > sheets("sourcesheet).range("a1") > 'etc > copy range("a2:z4") sheets("destinationsheet").range("a1"

Re: $$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread dguillett1
urcesheet).range("a1") 'etc copy range("a2:z4") sheets("destinationsheet").range("a1") next i -Original Message- From: Seba Sent: Wednesday, October 05, 2011 4:37 AM To: MS EXCEL AND VBA MACROS Subject: $$Excel-Macros$$ prompting for files for da

$$Excel-Macros$$ prompting for files for data import

2011-10-05 Thread Seba
Hi all, I have to import data from 3 different files into 1 and format the data. Since everything is more or less fixed, I have recorded the macro below and removed the code for scrolling and such. The only problem for me is that each month the locations and filenames of the files to import are ch