Loncat ke daftar isi utama

Bagaimana cara menghapus semua garis horizontal dari dokumen Word?

Garis horizontal dapat membagi paragraf dengan jelas. Banyak pengguna sudah mengetahui bahwa mereka bisa menambahkan garis horizontal ke dokumen dengan mengetikkan tiga tanda hubung, garis bawah atau tanda bintang dan seterusnya, lalu menekan Enter. Lihat tangkapan layar:

doc menghapus garis horizontal 1

Bagaimana cara menghapus semua garis horizontal dari dokumen? Tutorial ini akan memberi tahu Anda jawabannya.

Hapus semua garis horizontal satu per satu secara manual

Hapus semua garis horizontal dengan kode VBA

Hapus semua garis horizontal dengan Kutools for Word


Hapus semua garis horizontal satu per satu secara manual

Jika Anda hanya ingin menghapus beberapa garis horizontal, Anda dapat menghapusnya secara manual sebagai berikut:

1. Letakkan kursor di atas garis;

2. Klik pada Batas Halaman item di Latar belakang halaman kelompok Mendesain Tab;

doc menghapus garis horizontal 2

3. Klik Borders tab, klik Noneklik OK. Dan garis horizontal yang dipilih akan segera dihapus.

doc menghapus garis horizontal 3


Hapus semua garis horizontal dengan kode VBA

Jika Anda ingin menghapus semua garis horizontal dalam dokumen, membosankan untuk menghapusnya secara manual. VBA bisa mempermudah, lakukan hal berikut:

1. tekan Alt + F11 untuk membuka jendela VBA di Word;

2. Klik Modul dari Menyisipkan tab, dan masukkan kode ke dalam Modul jendela;

Kode VBA: Hapus semua garis horizontal dalam dokumen Word:

Sub removehline()
Dim ils As Paragraph
For Each ils In ActiveDocument.Paragraphs
ils.Borders(wdBorderBottom).LineStyle =wdLineStyleNone
Next ils
End Sub

3. Klik Run tombol atau tekan F5 untuk menerapkan VBA secara langsung. Dan semua garis horizontal telah dihapus dari dokumen.


Hapus semua garis horizontal dengan Kutools for Word

Paling mudah menghapus semua garis horizontal dari seluruh dokumen atau pemilihan dokumen dengan Kutools for Word.

Kutools for Word : dengan lebih dari 100 add-in Word yang praktis, gratis untuk dicoba tanpa batasan dalam 60 hari. 

1. Klik kutools > RemoveGaris horisontal, lihat tangkapan layar: 

2. Dan kemudian semua garis horizontal dari seluruh dokumen akan dihapus sekaligus, lihat tangkapan layar:

doc menghapus garis horizontal 5

Note: Jika Anda ingin menghapus bagian dari garis horizontal, pilih data jangkauan, lalu terapkan fitur ini.

Klik untuk mengunduh Kutools for Word dan uji coba gratis sekarang!


Demo: Hapus semua garis horizontal di Word

Kutools for Word: dengan lebih dari 100 add-in Word yang praktis, gratis untuk dicoba tanpa batasan dalam 60 hari. Unduh dan uji coba gratis sekarang!


Alat Produktivitas Kantor Terbaik

Kutools for Word - Tingkatkan Pengalaman Kata Anda dengan Over 100 Fitur Luar Biasa!

🤖 Asisten AI Kutools: Ubah tulisan Anda dengan AI - Hasilkan Konten  /  Menulis Ulang Teks  /  Meringkas Dokumen  /  Menanyakan Informasi berdasarkan Dokumen, semuanya dalam Word

📘 Penguasaan Dokumen: Halaman Terpisah  /  Gabungkan Dokumen  /  Ekspor Pilihan dalam Berbagai Format (PDF/TXT/DOC/HTML...)  /  Konversi Batch ke PDF  /  Ekspor Halaman sebagai Gambar  /  Cetak Banyak File sekaligus...

Pengeditan Isi: Temukan dan Ganti Batch di Banyak File  /  Ubah Ukuran Semua Gambar  /  Ubah Urutan Baris dan Kolom Tabel  /  Ubah Tabel menjadi Teks...

🧹 Bersih dengan Mudah: Menyapu Spasi Ekstra  /  Bagian Istirahat  /  Semua Header  /  Teks box  /  Hyperlink  / Untuk alat penghapus lainnya, kunjungi kami Hapus Grup...

Sisipan Kreatif: Memasukkan Seribu Pemisah  /  Kotak Centang  /  Tombol Radio  /  Kode QR  /  barcode  /  Tabel Garis Diagonal  /  Keterangan Persamaan  /  Keterangan gambar  /  Keterangan Tabel  /  Banyak Gambar  / Temukan lebih lanjut di Sisipkan Grup...

🔍 Pilihan Presisi: Tepat halaman tertentu  /  tabel  /  bentuk  /  paragraf judul  / Tingkatkan navigasi dengan lebih Pilih fitur...

Peningkatan Bintang: Navigasi dengan cepat ke lokasi mana pun  /  menyisipkan teks berulang secara otomatis  /  beralih antar jendela dokumen dengan mulus  /  11 Alat Konversi...

👉 Ingin mencoba fitur-fitur tersebut? Kutools for Word menawarkan a Uji coba gratis 60-hari, tanpa batasan! 🚀
 
Comments (13)
No ratings yet. Be the first to rate!
This comment was minimized by the moderator on the site
The VBA code returns the error 'compile error: must be first statement on line' for the first line. Any thoughts?
This comment was minimized by the moderator on the site
The VBA code returns the error - compile error: must be first statement on line for the first line.
This comment was minimized by the moderator on the site
The VBA code method worked. Thanks so much!
This comment was minimized by the moderator on the site
Thank you, thank you, thank you! I have a multi-gigabyte library of DOCX files that use horizontal lines (=== and ---) as internal section dividers. Thanks to your tip (perhaps the only instance on the web?) I will be able to programmatically split these documents into sub-files. Thanks again
This comment was minimized by the moderator on the site
I love you! OMG. The VBA thing worked!!!! That dump line was driving me crazy.
This comment was minimized by the moderator on the site
140 Ogrady St. Fall River, MA 02720-4911 USA How 3 lines made one line???
This comment was minimized by the moderator on the site
None of this page border stuff worked at all. I searched the document. The horizontal line was at the end, and 10 pages earlier was the culprit, a roman paragraph number lurking in a sentence for no reason at all. When I deleted it it removed the line 10 pages away. I will cut and pate the bugger here. In fact, you can have a set of them from 1 to 6. The then put a line at the bottom of every page. Go figure. MS Word 2007 is the platform. They are there, but do not display. They are just above this line, and will highlight if you mouse over.
This comment was minimized by the moderator on the site
The manual methods did not work, but the VBA code did. Very nice!
This comment was minimized by the moderator on the site
This is amazing!!! BIG THANK YOU for putting the VBA code. Searched in google but yours was the only thing that came up.
This comment was minimized by the moderator on the site
OMG! Thank you. I ran a macro as instructed and managed to remove the line. You were the onlly site among 3 to propose this solution.
There are no comments posted here yet
Load More
Please leave your comments in English
Posting as Guest
×
Rate this post:
0   Characters
Suggested Locations