Lewati ke konten utama

Tambahkan Baris ke Excel di dalam Power Automate: JSON ke Excel dengan PDF4me

PDF4me Excel - Tambahkan Baris adalah sebuah Power Automate tindakan yang menyisipkan JSON objek atau array sebagai baris baru ke dalam Excel Buku kerja, baik dalam mode berbasis tabel dengan pencocokan header otomatis atau mode berbasis koordinat dengan penempatan sel yang tepat. Gunakan untuk menulis hasil kueri basis data, pengiriman formulir, atau API tanggapan langsung ke dalam Excel laporan.

Apa yang dilakukan oleh tindakan ini?

PDF4me Excel - Tambahkan Baris menulis JSON Memasukkan data baris ke dalam buku kerja yang sudah ada, mencocokkan properti dengan header saat Nama Tabel diatur, atau mendarat di koordinat yang tepat saat dibiarkan kosong. Konversi Numerik dan Tanggal, Pola Format Tanggal, Pola Format Numerik, dan Nama Budaya mengontrol bagaimana nilai yang dimasukkan diketik dan diformat.

Postingan Blog Terkait
Belum ada postingan blog untuk fitur ini — akan segera hadir.
Sementara itu, jelajahi blog PDF4me untuk menemukan tutorial dan alur kerja di berbagai platform.
Kunjungi blog ini

Bagaimana Cara Saya Mengautentikasi Saya? Power Automate Mengalir?

Setiap PDF4me tindakan dalam Power Automate Membutuhkan koneksi yang valid. Buat atau pilih koneksi yang sesuai dengan kebutuhan Anda. PDF4me API kunci agar alur dapat melakukan autentikasi Excel permintaan penyisipan baris secara aman.

Fakta Penting yang Tidak Boleh Anda Lewatkan

Nama Tabel adalah sakelar mode
Nama Tabel yang tidak kosong mengaktifkan penyisipan berbasis tabel dengan pencocokan header dan Nomor Baris Excel untuk posisi. Biarkan kosong untuk penyisipan berbasis koordinat menggunakan Sisipkan Dari Baris dan Sisipkan Dari Kolom. Mencampur kedua set parameter dalam satu panggilan akan menghasilkan kesalahan.
Kolom data diberi label JSON Data Baris
Menerima satu JSON Objek untuk satu baris atau larik objek untuk menyisipkan beberapa baris dalam satu panggilan. Nama properti menentukan pencocokan header dalam mode tabel.
Konversi tipe memerlukan tombol aktif.
Pola Format Tanggal, Pola Format Numerik, dan Nama Budaya hanya berlaku jika Konversi Numerik dan Tanggal diaktifkan. Jika tidak diaktifkan, setiap nilai akan ditulis sebagai teks biasa.
Power Automate PDF4me Excel - Tindakan Tambah Baris dikonfigurasi dengan Konten File, Nama File, Data Baris JSON, Nama Lembar Kerja Sheet1, Sisipkan Dari Baris 6, Sisipkan Dari Kolom 2, dan parameter Lanjutan Konversi Numerik dan Tanggal, Pola Format Tanggal yyyy-MM-dd, dan Pola Format Numerik N2

Petakan Konten File dan Nama File, atur Data Baris JSON, pilih Nama Tabel atau Sisipkan Dari Baris/Kolom, lalu perluas Parameter Lanjutan untuk konversi tipe dan pemformatan.

Parameter

Diperlukan: Konten File, Nama File, dan Data Baris JSON harus selalu disediakan. Nama Tabel dan Nomor Baris Excel hanya berlaku untuk penyisipan berbasis tabel. Sisipkan Dari Baris dan Sisipkan Dari Kolom hanya berlaku untuk penyisipan berbasis koordinat, dan akan ditolak jika Nama Tabel juga diatur.

ParameterDiperlukanApa fungsinya?Contoh
File ContentRequiredBase64 content of the source Excel workbook, mapped from SharePoint, OneDrive, or another prior action.[File Content from Get File]
File NameRequiredExcel filename including extension (.xlsx or .xls), used for processing and output identification.data.xlsx
JSON Row DataRequiredJSON object or array of objects to insert. Each object becomes one row, property names match table headers in table mode.[{"Name":"John","Age":30}]
Worksheet NameOptionalName of the worksheet to insert into. Defaults to Sheet1 if left blank.Sheet1
Table NameOptionalName of an Excel table for table-based insertion. Leave empty to use coordinate-based insertion instead.SalesTable
Excel Row NumberConditional1-based position within the table, table mode only. Ignored in coordinate mode.5
Insert From RowConditional1-based worksheet row where insertion starts, coordinate mode only. Errors if Table Name is also set.10
Insert From ColumnConditional1-based worksheet column where insertion starts, coordinate mode only. Errors if Table Name is also set.3
Convert Numeric And DateOptionalEnables automatic conversion of JSON numbers to Excel numeric values and date-like strings to Excel dates. Default true.true
Date Format PatternOptionalExcel date format applied when Convert Numeric And Date is enabled. Default yyyy-MM-dd.MM/dd/yyyy
Numeric Format PatternOptionalExcel numeric format applied when Convert Numeric And Date is enabled. Default N2.#,##0.00
Ignore Null ValuesOptionalSkips inserting a value for any JSON property that is null when enabled. Default false, which inserts nulls as empty cells.false
Ignore Attribute TitlesOptionalMakes JSON property name matching case-insensitive against table headers when enabled. Default false.true
Culture NameOptionalCulture code used to parse incoming date and number strings before conversion. Default en-US.en-US

Bidang Keluaran

BidangJenisIsi di dalamnya
documentBase64The Excel workbook with the new rows inserted.
SuccessBooleantrue if insertion completed, false if the action failed.
ErrorMessageStringError description, null when Success is true.
ErrorsArrayDetailed error objects with Code and Message, empty when Success is true.

Apa Arti Pesan Kesalahan Umum Tersebut?

Pesan KesalahanMenyebabkanLarutan
JSON input is requiredJSON Row Data is null or empty.Provide a valid JSON object or array.
Invalid JSON structureMalformed JSON syntax.Fix the JSON formatting before mapping it in.
Worksheet not foundThe named worksheet does not exist in the workbook.Use an existing worksheet name or leave it blank for the first sheet.
Table not foundThe named table does not exist, table mode only.Use an existing Excel table name.
ExcelRowNumber must be greater than 0Excel Row Number is less than 1 in table mode.Set Excel Row Number to 1 or higher.
InsertFromRow and InsertFromColumn are ignored when TableName is specifiedCoordinate parameters were set alongside Table Name.Clear Table Name for coordinate mode, or clear the coordinate fields for table mode.
No valid data found in JSON inputJSON Row Data was an empty array or had no parseable objects.Provide at least one valid object in the JSON payload.

Bagaimana Cara Mengatur Penambahan Baris di Power Automate?

  1. Menambahkan PDF4meExcel - Tambahkan Baris untuk Anda Power Automate mengalir.
  2. Peta Isi File Dan Nama File dari tindakan sebelumnya (SharePoint, OneDrive, atau konektor basis data).
  3. Mengatur JSON Data Baris ke objek atau larik objek Anda.
  4. Mengatur Nama Tabel untuk penyisipan berbasis tabel, atau biarkan kosong dan atur Sisipkan Dari Baris / Sisipkan Dari Kolom untuk penyisipan berbasis koordinat.
  5. Memperluas Parameter lanjutan untuk memungkinkan Konversi Angka dan Tanggal dan atur formatnya. Jalankan alur kerja, buku kerja yang diperbarui akan kembali sebagai berikut. dokumen.

Pengaturan Umum

Contoh Alur KerjaCommon Power Automate flow patterns using Add Rows.
Impor data penjualan harian (mode tabel)
  1. Pemicu terjadwal menjalankan kueri SQL untuk mengambil catatan penjualan hari itu.
  2. Hasilnya dikonversi menjadi array JSON yang sesuai dengan judul kolom tabel penjualan.
  3. Get File mengambil templat laporan penjualan dengan Nama Tabel "DailySales".
  4. Add Rows menyisipkan array dengan Convert Numeric And Date diaktifkan dan Numeric Format Pattern diatur untuk mata uang.
  5. Laporan terbaru dikirimkan melalui email kepada manajer penjualan.
Pencatatan respons formulir (mode koordinat)
  1. Pengiriman formulir Microsoft Forms memicu alur kerja.
  2. Skenario ini membangun objek JSON dari jawaban yang dikirimkan.
  3. Get File mengambil buku kerja log respons.
  4. Fungsi Tambah Baris menyisipkan data pada baris kosong berikutnya menggunakan Sisipkan Dari Baris dan Sisipkan Dari Kolom, dengan Nama Tabel dibiarkan kosong.
  5. Log yang diperbarui disimpan kembali ke SharePoint.
Ekspor peluang CRM
  1. Pemicu mingguan memunculkan peluang baru dari sebuah CRM konektor.
  2. Data tersebut dikonversi menjadi array JSON dengan nama field yang fleksibel.
  3. Fungsi Tambah Baris memasukkan data ke dalam tabel "Peluang" dengan opsi Abaikan Judul Atribut diaktifkan untuk pencocokan header yang tidak peka terhadap huruf besar/kecil.
  4. Laporan yang telah diisi kemudian didistribusikan kepada tim penjualan.

Tips Praktis

Never set Table Name and Insert From Row together
The two parameter sets belong to different insertion modes. Setting both returns an error, clear one set before running.
JSON Row Data accepts a single object or an array
A bare object inserts one row, an array inserts one row per object. Choose the shape that matches how many rows you are writing.
Excel Row Number is 1-based within the table
Row 1 in table mode is the first data row after the header, not the header itself. Set it accordingly when targeting a specific position.
Culture Name affects parsing, not just display
Set Culture Name to match how your source data formats dates and decimals (for example de-DE for comma decimals), otherwise conversion can misread values.
Ignore Attribute Titles solves case-mismatch headaches
If your JSON property names differ in case from the Excel table headers, enable Ignore Attribute Titles instead of renaming every header or every JSON key.

Lembar Panduan Singkat

BidangNilai
ActionExcel - Add Rows
Mode switchTable Name set = table mode, empty = coordinate mode
JSON Row Data shapeSingle object or array of objects
Default worksheetSheet1
Type conversion toggleConvert Numeric And Date = true (default)
Default date/numeric formatyyyy-MM-dd / N2
Default cultureen-US
Outputdocument (Base64 workbook) + Success + ErrorMessage + Errors

Pertanyaan Umum

How do I insert JSON data into Excel in Power Automate?+
Add the PDF4me Excel - Add Rows action, map File Content and File Name from a prior action, set JSON Row Data to your JSON payload, then choose Table Name for table-based insertion or Insert From Row and Insert From Column for coordinate-based insertion.
What is the difference between table-based and coordinate-based insertion?+
Table-based insertion is used when Table Name is provided, JSON property names are matched to the Excel table headers and Excel Row Number sets the position within the table. Coordinate-based insertion is used when Table Name is empty, Insert From Row and Insert From Column set the exact worksheet cell where insertion starts, with no header matching.
Can I insert more than one row at once?+
Yes. Pass a JSON array of objects in JSON Row Data and every object becomes its own inserted row. A single JSON object inserts exactly one row.
What happens if I mix table-based and coordinate-based parameters?+
Setting Insert From Row or Insert From Column while Table Name is also set returns an error, since the two parameter sets belong to different insertion modes. Use one mode's parameters at a time.
How does automatic type conversion work?+
With Convert Numeric And Date enabled, JSON numbers become Excel numeric values formatted with Numeric Format Pattern, and date-like strings become Excel DateTime values formatted with Date Format Pattern. Culture Name controls how the incoming values are parsed before conversion. See <a href="https://learn.microsoft.com/en-us/dotnet/standard/base-types/standard-numeric-format-strings" target="_blank" rel="noopener noreferrer">Microsoft's numeric format string reference</a> and <a href="https://learn.microsoft.com/en-us/connectors/pdf4meconnect/" target="_blank" rel="noopener noreferrer">the PDF4me Power Automate connector reference</a> for details.

Studi Kasus & Aplikasi Industri

  • Laporan Saluran PenjualanMasukkan data peluang CRM ke dalam saluran penjualan Excel.
  • Pelacakan ProspekTambahkan prospek baru dari formulir ke lembar pelacakan Excel.
  • Analisis KampanyeMengisi hasil kampanye pemasaran dari API analitik
  • Daftar PelangganEkspor data pelanggan dari basis data ke daftar pelanggan Excel.

Tindakan Terkait

Tugas yang Sama di Platform Lain

Dapatkan Bantuan