Kitap icinden birkac sayfayi farkli kaydetmek

Katılım
28 Haziran 2007
Mesajlar
246
Excel Vers. ve Dili
Excel 2003 Tr
arkadaslar iyi aksamlar,

zamanınız varsa soyle bir macroya ihtiyacim var.

calisma kitabimdan (45 sayfalik) 4 adet sayfayi bicimlerdirmelerini ve sayfa ozelliklerini koruyarak , formullu hucrelerden de formulleri kaldirip sadece degerlerini yazarak masaustune kaydedecek bir macroya ihtiyacim var.

1-Dosya adini "Giris" sayfasi G2 ve G3 teki degerleri birlestirip sonuna YMM Icın Dosya ekleyerek verecek. Ornek "X A.S. Temmuz 2007 YMM Icin Dosya"
2-Kaydedilecek sayfalarimin adlari onemli degil YMM1 YMM2 YMM3 YMM4 tur
3-Kaydedilecek sayfalarin dordu de 3. satirdan itibaren veri iceriyor. hepsinin ilk uc satirinda diger sayfalara kopruler ve botunlar var, onlari yeni dosyaya kaydetmemesi daha uygun olur.
4-PC'nin kullanici adi yuzunden dosya'nin masaustune kaydedilmesinde problem olur derseniz. D:\ olarak degistirebilirim.

hepinize tesekkur eder tekrar iyi aksamlar dilerim.
 
Katılım
28 Haziran 2007
Mesajlar
246
Excel Vers. ve Dili
Excel 2003 Tr
iyi geceler, bu konuda yardimci olabilecek kimse var mi arkadaslar
 
Katılım
28 Haziran 2007
Mesajlar
246
Excel Vers. ve Dili
Excel 2003 Tr
Arkadaslar soruma alamayınca; problemimi macro kaydederek cozmeye calistim ve basarili oldum (en azindan isimi goruyor) . macroda bir suru gereksiz satir oldu ancak gereksiz oldugunu dusundugum satirlari silince de problem yaratiyor

kodlari inceleyek,
1- gereksiz satirlari silmem konusunda yardim ederseniz cok sevinirim.
2- Kopyalanan sayfalar icin yol olarak masaustunu gosterip standart bir dosya ismi olarak belirledim. ancak dosya ismini ve kaydedilecek yeri sormasi daha uygun olur.
3- Islemden sonra verileriniz "............... konumuna ..... adiyla kaydedildi" gibi bir mesaj gelirse de hos olur diye dusunuyorum.

cumleye "soruma cevap alamayinca ... " diye baslamis olmam her sorduguma kesinlikle cevap gelmeli dusuncesinde oldugum anlamina gelmiyor. o konuda yanlis anlasilmak istemem.

Sub YMM_Raporu()
Sheets(Array("YurtdisiOz", "YurtdisiKir", "Ihr", "KdvList")).Select
Sheets("KdvList").Activate
Sheets(Array("YurtdisiOz", "YurtdisiKir", "Ihr", "KdvList")).Copy
ActiveSheet.Shapes("Button 2").Select
ActiveSheet.Shapes.Range(Array("Button 2", "Button 3")).Select
ActiveSheet.Shapes.Range(Array("Button 2", "Button 3", "Button 4")).Select
ActiveSheet.Shapes.Range(Array("Button 2", "Button 3", "Button 4", "Button 1")) _
.Select
ActiveSheet.Shapes.Range(Array("Button 2", "Button 3", "Button 4", "Button 1" _
, "Button 5")).Select
Selection.Delete
Rows("1:2").Select
Selection.Delete Shift:=xlUp
Range("A1:J15").Select
ActiveWindow.SmallScroll Down:=69
Range("A1:J216").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("A6").Select
ActiveSheet.Next.Select
Range("A8").Select
ActiveSheet.Shapes("Button 2").Select
Range("A8,A1:K2").Select
Range("A1").Activate
ActiveSheet.Shapes("Button 2").Select
Range("A8,A1:K2,A1:K2").Select
Range("A1").Activate
ActiveSheet.Shapes("Button 4").Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 3")).Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 3", "Button 2")).Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 3", "Button 2", "Button 1")) _
.Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 3", "Button 2", "Button 1" _
, "Button 5")).Select
Application.CutCopyMode = False
Selection.Delete
Rows("1:2").Select
Range("L1").Activate
Selection.Delete Shift:=xlUp
Range("A1:J15").Select
ActiveWindow.SmallScroll Down:=72
Range("A1:K275").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("A6").Select
ActiveSheet.Next.Select
ActiveSheet.Shapes("Button 2").Select
Range("A8,A1:M2").Select
Range("A1").Activate
ActiveSheet.Shapes("Button 3").Select
ActiveSheet.Shapes.Range(Array("Button 3", "Button 4")).Select
ActiveSheet.Shapes.Range(Array("Button 3", "Button 4", "Button 1")).Select
ActiveSheet.Shapes.Range(Array("Button 3", "Button 4", "Button 1", "Button 5")) _
.Select
Application.CutCopyMode = False
Selection.Delete
Range("A8").Select
ActiveSheet.Shapes("Button 2").Select
Selection.Delete
Rows("1:2").Select
Range("N1").Activate
Selection.Delete Shift:=xlUp
Range("A1:M1").Select
ActiveWindow.SmallScroll Down:=195
Range("A1:M542").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("A6").Select
ActiveSheet.Next.Select
Range("A8").Select
ActiveSheet.Shapes("Button 2").Select
ActiveSheet.Shapes.Range(Array("Button 2", "Button 3")).Select
Range("A8,A1:L2").Select
Range("A1").Activate
ActiveSheet.Shapes("Button 4").Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 1")).Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 1", "Button 5")).Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 1", "Button 5", "Button 3")) _
.Select
ActiveSheet.Shapes.Range(Array("Button 4", "Button 1", "Button 5", "Button 3" _
, "Button 2")).Select
Application.CutCopyMode = False
Selection.Delete
Rows("1:2").Select
Selection.Delete Shift:=xlUp
Range("A1:L1").Select
ActiveWindow.SmallScroll Down:=144
ActiveWindow.ScrollRow = 181
ActiveWindow.ScrollRow = 186
ActiveWindow.ScrollRow = 201
ActiveWindow.ScrollRow = 206
ActiveWindow.ScrollRow = 219
ActiveWindow.ScrollRow = 225
ActiveWindow.ScrollRow = 237
ActiveWindow.ScrollRow = 252
ActiveWindow.ScrollRow = 256
ActiveWindow.ScrollRow = 272
ActiveWindow.ScrollRow = 277
ActiveWindow.ScrollRow = 290
ActiveWindow.ScrollRow = 296
ActiveWindow.ScrollRow = 308
ActiveWindow.ScrollRow = 323
ActiveWindow.ScrollRow = 327
ActiveWindow.ScrollRow = 338
ActiveWindow.ScrollRow = 341
ActiveWindow.ScrollRow = 352
ActiveWindow.ScrollRow = 356
ActiveWindow.ScrollRow = 365
ActiveWindow.ScrollRow = 370
ActiveWindow.ScrollRow = 372
ActiveWindow.ScrollRow = 374
ActiveWindow.ScrollRow = 381
ActiveWindow.ScrollRow = 385
ActiveWindow.ScrollRow = 394
ActiveWindow.ScrollRow = 400
ActiveWindow.ScrollRow = 411
ActiveWindow.ScrollRow = 412
ActiveWindow.ScrollRow = 421
ActiveWindow.ScrollRow = 431
ActiveWindow.ScrollRow = 436
ActiveWindow.ScrollRow = 443
ActiveWindow.ScrollRow = 445
ActiveWindow.ScrollRow = 452
ActiveWindow.ScrollRow = 454
ActiveWindow.ScrollRow = 462
ActiveWindow.ScrollRow = 467
ActiveWindow.ScrollRow = 469
ActiveWindow.ScrollRow = 476
ActiveWindow.ScrollRow = 480
ActiveWindow.ScrollRow = 487
ActiveWindow.ScrollRow = 493
ActiveWindow.ScrollRow = 496
ActiveWindow.ScrollRow = 502
ActiveWindow.ScrollRow = 505
ActiveWindow.ScrollRow = 509
ActiveWindow.ScrollRow = 511
ActiveWindow.ScrollRow = 513
ActiveWindow.ScrollRow = 514
ActiveWindow.ScrollRow = 516
ActiveWindow.ScrollRow = 514
ActiveWindow.ScrollRow = 513
ActiveWindow.ScrollRow = 509
ActiveWindow.ScrollRow = 505
ActiveWindow.ScrollRow = 503
ActiveWindow.ScrollRow = 502
ActiveWindow.ScrollRow = 496
ActiveWindow.ScrollRow = 494
ActiveWindow.ScrollRow = 489
ActiveWindow.ScrollRow = 487
ActiveWindow.ScrollRow = 483
ActiveWindow.ScrollRow = 482
ActiveWindow.ScrollRow = 480
ActiveWindow.ScrollRow = 478
ActiveWindow.ScrollRow = 474
ActiveWindow.ScrollRow = 472
ActiveWindow.ScrollRow = 471
ActiveWindow.ScrollRow = 469
ActiveWindow.ScrollRow = 467
ActiveWindow.ScrollRow = 465
ActiveWindow.ScrollRow = 463
ActiveWindow.ScrollRow = 462
ActiveWindow.ScrollRow = 460
ActiveWindow.ScrollRow = 458
ActiveWindow.ScrollRow = 456
ActiveWindow.ScrollRow = 454
ActiveWindow.ScrollRow = 452
ActiveWindow.ScrollRow = 451
ActiveWindow.ScrollRow = 449
ActiveWindow.ScrollRow = 447
ActiveWindow.ScrollRow = 443
ActiveWindow.ScrollRow = 441
ActiveWindow.ScrollRow = 440
ActiveWindow.ScrollRow = 438
ActiveWindow.ScrollRow = 436
ActiveWindow.ScrollRow = 434
ActiveWindow.ScrollRow = 432
ActiveWindow.ScrollRow = 431
ActiveWindow.ScrollRow = 429
ActiveWindow.ScrollRow = 427
ActiveWindow.ScrollRow = 425
ActiveWindow.ScrollRow = 423
ActiveWindow.ScrollRow = 421
ActiveWindow.ScrollRow = 420
ActiveWindow.ScrollRow = 418
ActiveWindow.ScrollRow = 416
ActiveWindow.ScrollRow = 414
ActiveWindow.ScrollRow = 412
ActiveWindow.ScrollRow = 411
ActiveWindow.ScrollRow = 409
ActiveWindow.ScrollRow = 407
ActiveWindow.ScrollRow = 405
ActiveWindow.ScrollRow = 403
ActiveWindow.ScrollRow = 401
ActiveWindow.ScrollRow = 400
ActiveWindow.ScrollRow = 398
ActiveWindow.ScrollRow = 396
ActiveWindow.ScrollRow = 394
ActiveWindow.ScrollRow = 392
ActiveWindow.ScrollRow = 390
ActiveWindow.ScrollRow = 389
ActiveWindow.ScrollRow = 387
ActiveWindow.ScrollRow = 385
ActiveWindow.ScrollRow = 383
ActiveWindow.ScrollRow = 381
ActiveWindow.ScrollRow = 380
ActiveWindow.ScrollRow = 378
ActiveWindow.ScrollRow = 376
ActiveWindow.ScrollRow = 374
ActiveWindow.ScrollRow = 372
ActiveWindow.ScrollRow = 370
ActiveWindow.ScrollRow = 369
ActiveWindow.ScrollRow = 367
ActiveWindow.ScrollRow = 365
ActiveWindow.ScrollRow = 363
ActiveWindow.ScrollRow = 361
ActiveWindow.ScrollRow = 359
ActiveWindow.ScrollRow = 358
ActiveWindow.ScrollRow = 356
ActiveWindow.ScrollRow = 354
ActiveWindow.ScrollRow = 352
ActiveWindow.ScrollRow = 350
ActiveWindow.ScrollRow = 349
ActiveWindow.ScrollRow = 347
ActiveWindow.ScrollRow = 345
ActiveWindow.ScrollRow = 343
ActiveWindow.ScrollRow = 341
ActiveWindow.ScrollRow = 339
ActiveWindow.ScrollRow = 338
ActiveWindow.ScrollRow = 336
ActiveWindow.ScrollRow = 334
ActiveWindow.ScrollRow = 332
ActiveWindow.ScrollRow = 330
ActiveWindow.ScrollRow = 329
ActiveWindow.ScrollRow = 327
ActiveWindow.ScrollRow = 325
ActiveWindow.ScrollRow = 323
ActiveWindow.ScrollRow = 321
ActiveWindow.ScrollRow = 319
ActiveWindow.ScrollRow = 318
ActiveWindow.ScrollRow = 316
ActiveWindow.ScrollRow = 314
ActiveWindow.ScrollRow = 312
ActiveWindow.ScrollRow = 310
ActiveWindow.ScrollRow = 308
ActiveWindow.ScrollRow = 307
ActiveWindow.ScrollRow = 305
ActiveWindow.ScrollRow = 303
ActiveWindow.ScrollRow = 301
ActiveWindow.ScrollRow = 299
ActiveWindow.ScrollRow = 296
ActiveWindow.ScrollRow = 294
ActiveWindow.ScrollRow = 292
ActiveWindow.ScrollRow = 290
ActiveWindow.ScrollRow = 288
ActiveWindow.ScrollRow = 287
ActiveWindow.ScrollRow = 285
ActiveWindow.ScrollRow = 283
ActiveWindow.ScrollRow = 281
ActiveWindow.ScrollRow = 279
ActiveWindow.ScrollRow = 277
ActiveWindow.ScrollRow = 276
ActiveWindow.ScrollRow = 274
ActiveWindow.ScrollRow = 272
ActiveWindow.ScrollRow = 270
ActiveWindow.ScrollRow = 268
ActiveWindow.ScrollRow = 267
ActiveWindow.ScrollRow = 265
ActiveWindow.ScrollRow = 263
ActiveWindow.ScrollRow = 261
ActiveWindow.ScrollRow = 265
ActiveWindow.ScrollRow = 268
ActiveWindow.ScrollRow = 272
ActiveWindow.ScrollRow = 283
ActiveWindow.ScrollRow = 288
ActiveWindow.ScrollRow = 299
ActiveWindow.ScrollRow = 305
ActiveWindow.ScrollRow = 319
ActiveWindow.ScrollRow = 334
ActiveWindow.ScrollRow = 339
ActiveWindow.ScrollRow = 358
ActiveWindow.ScrollRow = 361
ActiveWindow.ScrollRow = 372
ActiveWindow.ScrollRow = 376
ActiveWindow.ScrollRow = 385
ActiveWindow.ScrollRow = 394
ActiveWindow.ScrollRow = 396
ActiveWindow.ScrollRow = 403
ActiveWindow.ScrollRow = 405
ActiveWindow.ScrollRow = 411
ActiveWindow.ScrollRow = 414
ActiveWindow.ScrollRow = 420
ActiveWindow.ScrollRow = 427
ActiveWindow.ScrollRow = 429
ActiveWindow.ScrollRow = 434
ActiveWindow.ScrollRow = 436
ActiveWindow.ScrollRow = 443
ActiveWindow.ScrollRow = 445
ActiveWindow.ScrollRow = 451
ActiveWindow.ScrollRow = 458
ActiveWindow.ScrollRow = 460
ActiveWindow.ScrollRow = 465
ActiveWindow.ScrollRow = 469
ActiveWindow.ScrollRow = 478
ActiveWindow.ScrollRow = 480
ActiveWindow.ScrollRow = 491
ActiveWindow.ScrollRow = 498
ActiveWindow.ScrollRow = 502
ActiveWindow.ScrollRow = 511
ActiveWindow.ScrollRow = 514
ActiveWindow.ScrollRow = 523
ActiveWindow.ScrollRow = 527
ActiveWindow.ScrollRow = 536
ActiveWindow.ScrollRow = 547
ActiveWindow.ScrollRow = 549
ActiveWindow.ScrollRow = 558
ActiveWindow.ScrollRow = 562
ActiveWindow.ScrollRow = 573
ActiveWindow.ScrollRow = 576
ActiveWindow.ScrollRow = 585
ActiveWindow.ScrollRow = 595
ActiveWindow.ScrollRow = 598
ActiveWindow.ScrollRow = 605
ActiveWindow.ScrollRow = 611
ActiveWindow.ScrollRow = 616
ActiveWindow.ScrollRow = 620
ActiveWindow.ScrollRow = 626
ActiveWindow.ScrollRow = 631
ActiveWindow.ScrollRow = 635
ActiveWindow.ScrollRow = 640
ActiveWindow.ScrollRow = 642
ActiveWindow.ScrollRow = 647
ActiveWindow.ScrollRow = 649
ActiveWindow.ScrollRow = 653
ActiveWindow.ScrollRow = 656
ActiveWindow.ScrollRow = 658
ActiveWindow.ScrollRow = 664
ActiveWindow.ScrollRow = 666
ActiveWindow.ScrollRow = 669
ActiveWindow.ScrollRow = 673
ActiveWindow.ScrollRow = 675
ActiveWindow.ScrollRow = 678
ActiveWindow.ScrollRow = 680
ActiveWindow.ScrollRow = 684
ActiveWindow.ScrollRow = 689
ActiveWindow.ScrollRow = 691
ActiveWindow.ScrollRow = 695
ActiveWindow.ScrollRow = 700
ActiveWindow.ScrollRow = 702
ActiveWindow.ScrollRow = 706
ActiveWindow.ScrollRow = 709
ActiveWindow.ScrollRow = 711
ActiveWindow.ScrollRow = 715
ActiveWindow.ScrollRow = 718
ActiveWindow.ScrollRow = 720
ActiveWindow.ScrollRow = 724
ActiveWindow.ScrollRow = 726
ActiveWindow.ScrollRow = 728
ActiveWindow.ScrollRow = 731
ActiveWindow.ScrollRow = 737
ActiveWindow.ScrollRow = 742
ActiveWindow.ScrollRow = 748
ActiveWindow.ScrollRow = 749
ActiveWindow.ScrollRow = 753
ActiveWindow.ScrollRow = 757
ActiveWindow.ScrollRow = 760
ActiveWindow.ScrollRow = 764
ActiveWindow.ScrollRow = 766
ActiveWindow.ScrollRow = 769
ActiveWindow.ScrollRow = 773
ActiveWindow.ScrollRow = 780
ActiveWindow.ScrollRow = 782
ActiveWindow.ScrollRow = 788
ActiveWindow.ScrollRow = 791
ActiveWindow.ScrollRow = 793
ActiveWindow.ScrollRow = 797
ActiveWindow.ScrollRow = 799
ActiveWindow.ScrollRow = 800
ActiveWindow.ScrollRow = 802
ActiveWindow.ScrollRow = 804
ActiveWindow.ScrollRow = 806
ActiveWindow.ScrollRow = 808
ActiveWindow.ScrollRow = 810
ActiveWindow.ScrollRow = 811
ActiveWindow.ScrollRow = 813
ActiveWindow.ScrollRow = 815
ActiveWindow.ScrollRow = 817
ActiveWindow.ScrollRow = 819
ActiveWindow.ScrollRow = 820
ActiveWindow.ScrollRow = 822
ActiveWindow.ScrollRow = 826
ActiveWindow.ScrollRow = 830
ActiveWindow.ScrollRow = 831
ActiveWindow.ScrollRow = 835
ActiveWindow.ScrollRow = 837
ActiveWindow.ScrollRow = 841
ActiveWindow.ScrollRow = 842
ActiveWindow.ScrollRow = 844
ActiveWindow.ScrollRow = 846
ActiveWindow.ScrollRow = 848
ActiveWindow.ScrollRow = 851
ActiveWindow.ScrollRow = 855
ActiveWindow.ScrollRow = 857
ActiveWindow.ScrollRow = 859
ActiveWindow.ScrollRow = 862
ActiveWindow.ScrollRow = 864
ActiveWindow.ScrollRow = 866
ActiveWindow.ScrollRow = 875
ActiveWindow.ScrollRow = 881
ActiveWindow.ScrollRow = 882
ActiveWindow.ScrollRow = 888
ActiveWindow.ScrollRow = 892
ActiveWindow.ScrollRow = 893
ActiveWindow.ScrollRow = 897
ActiveWindow.ScrollRow = 899
ActiveWindow.ScrollRow = 901
ActiveWindow.ScrollRow = 902
ActiveWindow.ScrollRow = 904
ActiveWindow.ScrollRow = 906
ActiveWindow.ScrollRow = 908
ActiveWindow.ScrollRow = 910
ActiveWindow.ScrollRow = 912
ActiveWindow.ScrollRow = 913
ActiveWindow.ScrollRow = 915
ActiveWindow.ScrollRow = 917
ActiveWindow.ScrollRow = 919
Range("A1:L941").Select
Selection.Copy
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Range("A6").Select
ActiveSheet.Previous.Select
ActiveSheet.Previous.Select
ActiveSheet.Previous.Select
Range("A6").Select
Application.CutCopyMode = False
ChDir "C:\Documents and Settings\Gökay\Desktop"
ActiveWorkbook.SaveAs Filename:= _
"C:\Documents and Settings\Gökay\Desktop\YMM_Raporu.xls", FileFormat:= _
xlNormal, Password:="", WriteResPassword:="", ReadOnlyRecommended:=False _
, CreateBackup:=False
Windows("Sablon.xls").Activate
Sheets("Giris").Select
End Sub
 
Üst