Thread: column copy
View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Curt Curt is offline
external usenet poster
 
Posts: 469
Default column copy

call AAAA
worksheet("Data").range.(A:A).copy
worksheet(announcer")range("A:A").paste
worksheet("Data").range.("D:D").copy
worksheet(announcer")range("D:D").paste
and so on right
Thanks


"Vergel Adriano" wrote:

Hi Curt,

I only used ActiveSheet as an example because I assumed you wanted to work
with the activesheet. But, you don't really have to activate your sheet. For
example, this will also work:

'Copy column A from sheet named "Sheet1" to a sheet named "Sheet2"
Sheets("Sheet1").Range("A:A").Copy Sheets("Sheet2").Range("A:A")



--
Hope that helps.

Vergel Adriano


"Curt" wrote:

As all ways one does not fully explain the problem. I am trying to do this in
vba code as a sub procedure. Not sure of codeing The procedure will be
acessed from an user form. You will not be on the active sheet. If I follow
data worksheet must be activated first and the run sub AAAA then
ActiveSheet.Range("A:A").Copy Sheets("Sheet2").Range("A:A")
ActiveSheet.Range("D:D").Copy Sheets("Sheet2").Range("D:D")
ActiveSheet.Range("E:E").Copy Sheets("Sheet2").Range("E:E")
ActiveSheet.Range("G:G").Copy Sheets("Sheet2").Range("G:G")
ActiveSheet.Range("L:L").Copy Sheets("Sheet2").Range("L:L")
correct
Thanks

"Vergel Adriano" wrote:

Curt,

As an example, to copy column A in the activesheet to column A of a sheet
named Sheet2:

ActiveSheet.Range("A:A").Copy Sheets("Sheet2").Range("A:A")


--
Hope that helps.

Vergel Adriano


"Curt" wrote:

I have code that sorts data worksheet sub (AAAA)
Need code in another procedure that will run sort code first (AAAA) Then
copy columns (A),(D),(E),(G),(L) to worksheet announcer. This builds the
worksheet to be used with a mail merge for printing announcer cards. Have not
tried to copy columns only cells
Help Greatly Appreciated
Thanks