Loncat ke daftar isi utama

Bagaimana cara membatasi untuk menempelkan nilai saja (mencegah pemformatan) di Excel?

Biasanya, kami menempelkan data yang disalin hanya dengan menekan tombol Ctrl + V secara bersamaan. Dan itu akan menempelkan nilai yang disalin bersama dengan semua pemformatan sel. Jika Anda hanya perlu menempelkan nilai saja dan membatasi pemformatan sel, metode berikut dapat membantu Anda.

Batasi untuk menempelkan nilai saja (mencegah pemformatan) dengan fitur nilai tempel
Batasi untuk hanya menempelkan nilai (mencegah pemformatan) dengan kode VBA
Batasi untuk menempelkan nilai hanya dengan Kutools for Excel


Batasi untuk menempelkan nilai saja (mencegah pemformatan) dengan fitur nilai tempel

Cara mudah untuk membatasi untuk menempelkan nilai saja adalah menempelkan data yang disalin sebagai nilai hanya di Excel.

1. Setelah menyalin data, klik kanan sel tujuan yang akan Anda tempelkan datanya.

2. Kemudian klik Nilai - Nilai tombol di bawah Opsi Tempel bagian di menu klik kanan. Lihat tangkapan layar:

Anda hanya dapat melihat nilai sel yang disalin ditempelkan ke sel tujuan.


Batasi untuk hanya menempelkan nilai (mencegah pemformatan) dengan kode VBA

Kode VBA berikut membantu Anda menempelkan hanya nilai sel yang disalin, dan membatasi semua pemformatan sel. Silakan lakukan sebagai berikut.

1. tekan lain + F11 tombol secara bersamaan untuk membuka Microsoft Visual Basic untuk Aplikasi jendela.

2. Dalam Microsoft Visual Basic untuk Aplikasi jendela, klik dua kali Buku Kerja Ini dalam Project panel kanan untuk membuka Buku Kerja Ini jendela kode. Kemudian salin dan tempel kode VBA di bawah ini ke jendela.

Kode VBA: Batasi untuk menempelkan nilai hanya di Excel

Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range)
    On Error Resume Next
    Target.PasteSpecial xlPasteValues
    Application.CutCopyMode = True
End Sub

3. tekan lain + Q secara bersamaan untuk menutup jendela Microsoft Visual Basic for Applications.

Sekarang, salin data Anda, dan buka lembar kerja tujuan. Hanya satu klik atau klik kanan pada sel tujuan yang akan menempelkan nilai sel yang disalin tanpa segera memformat.


Batasi untuk menempelkan nilai hanya dengan Kutools for Excel

Kutools untuk Excel 's Salin Rentang utilitas membantu Anda dengan mudah menempelkan hanya nilai dari rentang yang dipilih atau beberapa rentang yang dipilih di Excel. Silakan lakukan sebagai berikut.

Sebelum melamar Kutools untuk Excel, Mohon unduh dan instal terlebih dahulu.

1. Pilih rentang atau beberapa rentang dengan menahan Ctrl kunci, lalu klik Kutools > Salin Rentang

2. Dalam Salin Beberapa Rentang kotak dialog, pilih saja Nilai - Nilai pilihan dalam Tempel khusus bagian, dan kemudian klik OK .

Note: Anda dapat memeriksa keduanya atau salah satu file Termasuk tinggi baris dan Termasuk lebar kolom pilihan yang Anda butuhkan.

3. Selanjutnya Salin Beberapa Rentang kotak dialog, pilih sel kosong untuk menempelkan sel yang disalin, lalu klik OK .

Kemudian hanya nilai dari semua sel yang dipilih dalam satu atau beberapa rentang yang ditempelkan.

  Jika Anda ingin memiliki uji coba gratis (30 hari) dari utilitas ini, silahkan klik untuk mendownloadnya, lalu lanjutkan untuk menerapkan operasi sesuai langkah di atas.


Artikel terkait:

Alat Produktivitas Kantor Terbaik

馃 Kutools AI Ajudan: Merevolusi analisis data berdasarkan: Eksekusi Cerdas   |  Hasilkan Kode  |  Buat Rumus Khusus  |  Analisis Data dan Hasilkan Grafik  |  Aktifkan Fungsi Kutools...
Fitur Populer: Temukan, Sorot, atau Identifikasi Duplikat   |  Hapus Baris Kosong   |  Gabungkan Kolom atau Sel tanpa Kehilangan Data   |   Putaran tanpa Formula ...
Pencarian Super: VLookup Beberapa Kriteria    VLookup Nilai Berganda  |   VLookup di Beberapa Lembar   |   Pencarian Fuzzy ....
Daftar Drop-down Lanjutan: Buat Daftar Drop Down dengan Cepat   |  Daftar Drop Down yang Bergantung   |  Multi-pilih Drop Down List ....
Manajer Kolom: Tambahkan Jumlah Kolom Tertentu  |  Pindahkan Kolom  |  Alihkan Status Visibilitas Kolom Tersembunyi  |  Bandingkan Rentang & Kolom ...
Fitur Unggulan: Fokus Kisi   |  Tampilan Desain   |   Bar Formula Besar    Manajer Buku Kerja & Lembar   |  Perpustakaan Sumberdaya (Teks otomatis)   |  Pemetik tanggal   |  Gabungkan Lembar Kerja   |  Enkripsi/Dekripsi Sel    Kirim Email berdasarkan Daftar   |  Filter Super   |   Filter Khusus (filter tebal/miring/coret...) ...
15 Perangkat Teratas12 Teks Tools (Tambahkan Teks, Hapus Karakter, ...)   |   50 + Grafik jenis (Gantt Chart, ...)   |   40+ Praktis Rumus (Hitung usia berdasarkan ulang tahun, ...)   |   19 Insersi Tools (Masukkan Kode QR, Sisipkan Gambar dari Jalur, ...)   |   12 Konversi Tools (Angka ke Kata, Konversi Mata Uang, ...)   |   7 Gabungkan & Pisahkan Tools (Lanjutan Gabungkan Baris, Pisahkan Sel, ...)   |   ... dan banyak lagi

Tingkatkan Keterampilan Excel Anda dengan Kutools for Excel, dan Rasakan Efisiensi yang Belum Pernah Ada Sebelumnya. Kutools for Excel Menawarkan Lebih dari 300 Fitur Lanjutan untuk Meningkatkan Produktivitas dan Menghemat Waktu.  Klik Di Sini untuk Mendapatkan Fitur yang Paling Anda Butuhkan...

Deskripsi Produk


Tab Office Membawa antarmuka Tab ke Office, dan Membuat Pekerjaan Anda Jauh Lebih Mudah

  • Aktifkan pengeditan dan pembacaan tab di Word, Excel, PowerPoint, Publisher, Access, Visio, dan Project.
  • Buka dan buat banyak dokumen di tab baru di jendela yang sama, bukan di jendela baru.
  • Meningkatkan produktivitas Anda sebesar 50%, dan mengurangi ratusan klik mouse untuk Anda setiap hari!
Comments (14)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
Hello, there are a problem here, values are automatically paste when you click on the cell
This comment was minimized by the moderator on the site
Hi, any chance to add this feature only in some sheets?
This comment was minimized by the moderator on the site
Hallo,
ich habe eine Excel-Datei (100 Tabellenregister) f眉r die ich eine Formel gesucht habe, die es erlaubt, beim Kopieren nur Werte einf眉gen, m枚glich zu machen.

Ausschneiden+Drag&Drop habe ich bereits per Makro ausgeschaltet. Ich habe jetzt im Netz folgenden Code gefunden, den ich in
"Diese Arbeitsmappe" geschrieben habe:

Private Sub Workbook_SheetSelectionChange(ByVal Sh As Object, ByVal Target As Range)
On Error Resume Next
Target.PasteSpecial xlPasteValues
Application.CutCopyMode = True
End Sub

(Der Code verursacht, dass ich nach kopieren, den Inhalt sofort als Wert in eine angeklickte Zelle kopiert bekomme)
Das funktioniert sehr gut, jedoch habe ich noch ein Problem dabei:

Wenn ich Werte aus einer Zelle kopiere, kann ich diese auch in gesch眉tzte
Zellen kopieren und das soll nicht sein. In vielen gesch眉tzten Zellen stehen Formeln die nicht 眉berschrieben werden sollen.

Kann mir jemand helfen, wie ich den Code erweitern oder 盲ndern kann, dass er es nur erlaubt in nicht gesch眉tzte Zellen zu kopieren?

Gru脽 Heiko
This comment was minimized by the moderator on the site
Hi! for Kutools 'Copy Ranges', I realized there is limit on number of columns that can be copy at a time. I am working with 7,500 columns. I select 7,500 columns as the range, but it can only copy and paste partial of what I had selected, not all. I am planning to copy all these columns in one go and paste. Is there any way I can do that ? just to speed things up. Any help would highly be appreciated. Thanks!
This comment was minimized by the moderator on the site
Hi, is there code for working with ctrl+v. This code paste automatically when selecting cell. I found module code below link but couldn't find code for workbook like this.
https://www.extendoffice.com/documents/excel/2545-excel-set-paste-values-as-default.html
This comment was minimized by the moderator on the site
It's sad no one answers. I need this information too.
This comment was minimized by the moderator on the site
This code was great, but it was pasting items in the system clipboard that were copied from other programs. I put it in an 'If' statement which does nothing, unless Excel cells are actually in Cut or Copy mode. i.e. moving border around the cell(s).

Application.CutCopyMode has three modes: False = Not in Cut or Copy mode. | xlCopy = In Copy mode. | xlCut = In Cut mode.

'If in Cut or Copy mode, Paste Values Only
'If Not in Cut or Copy mode, skip and do nothing.

On Error Resume Next
If Not Application.CutCopyMode = False Then
Target.PasteSpecial xlPasteValues
Application.CutCopyMode = True
End If

This was a bit of a bugger for me to figure out. Hope it helps someone else.
-Travis (IT Professional since 1996)
This comment was minimized by the moderator on the site
This addition was a great help! Thank you so much for posting!
This comment was minimized by the moderator on the site
Hi Travis, Thank you very much for posting this.
I never respond to posts but i appreciate you posting this answer.
This comment was minimized by the moderator on the site
Hi Travis, is there code for working with ctrl+v. This code paste automatically when selecting cell. I found module code below link but couldn't find code for workbook like this. I hope what I have requested is possible.
https://www.extendoffice.com/documents/excel/2545-excel-set-paste-values-as-default.html
This comment was minimized by the moderator on the site
Dean, it is very useful! Thanks!
This comment was minimized by the moderator on the site
Thank you so much!! It works well and its so useful for the project that I am working on.
This comment was minimized by the moderator on the site
This works for me:

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error Resume Next
Target.PasteSpecial xlPasteValues
Application.CutCopyMode = True
End Sub
This comment was minimized by the moderator on the site
Would this work on Worksheet level only? I am trying to restrict this only on one worksheet (not entire workbook), but it seems there is a problem.
There are no comments posted here yet
Please leave your comments in English
Posting as Guest
Rate this post:
0   Characters
Suggested Locations