Macro Help

[Closed]
Report
-
Posts
1862
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
July 30, 2015
-
Hello,

I need help with a macro. Mine works ok ... but I'd like more userflexibility.

Let's say I have 4 .xls workbooks in a folder. I'd like to compile three cells worth of data from each folder into a new workbook. Specifically, I'd like the data to paste in a single row (row A of the new workbook) ...

Here's where I am having trouble, I can specify the source range [e.g. SourceRng:="AF2:AG2"], but I'd like the end user to be able to type this into a pop-up or select it. It works by modifying the source directly.

And how can I get it to paste left to right as opposed to down a column (down a column is pretty easy).

Thanks for the help,
MP

1 reply

Posts
1862
Registration date
Sunday June 14, 2009
Status
Contributor
Last seen
July 30, 2015
800
quote
And how can I get it to paste left to right as opposed to down a column (down a column is pretty easy).
unquoe
use in the macro something linke this
pastespecial transpose:=true

see help "pastespecial in vba help ..
open vb editor (alt+F11) and click the help and type the word "pastespecial" and click search

Subscribe To Our Newsletter!

The Best of CCM in Your Inbox

Subscribe To Our Newsletter!