moving between multiple wokbooks

mszakalinski

New Member
Joined
Oct 29, 2013
Messages
3
hi,

im facing problem operating between two different unsaved workbooks, read a lot about possible solutions but still cant find good one. Macro should select and copy sheets to a new added workbook or opened from file workbook (both workbooks have sheet kennzahlen), switching between those workbooks is for me unclear, can anyone have a look why this code doesnt work? i set wwb1 and wwb2 as public to use them in other macros this module

Public wwb1 As Workbook
Public wwb2 As Workbook
Sub macro1()


Set wwb1 = ActiveWorkbook
wwb1.Activate
wwb1.Sheets("Kennzahlen").Select
ActiveSheet.Cells.Copy
Set wbb2 = Workbooks.Open(Filename:= _
"C:\Users\sds\Desktop\Moje dokumenty\1.xls")



wwb1.Sheets("Kennzahlen").Activate
wwb2.Sheets("Kennzahlen").Activate
wwb1.Sheets("Kennzahlen").Activate
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.

Forum statistics

Threads
1,223,236
Messages
6,170,912
Members
452,366
Latest member
TePunaBloke

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top