Altbilgi içeriğine atla
IRONPDF KULLANARAK
.NET 6'da PDF Dosyaları Nasıl Oluşturulur

C#'da PDF Oluşturma: (Başlangıç Kılavuzu) 2026'da VS Code Kullanarak

C#'ta PDF'ler oluşturmak, ister finansal raporlar oluşturun, ister saglik belgeleri uretin, veya e-ticaret makbuzlari uretin, modern .NET geliştiricileri icin temel bir beceridir. Dogru .NET PDF kutuphanesi ile, sadece birkac satir kodla HTML içeriklerini profesyonel PDF belgelerine dönüştürabilir, belge yapisi ve gorunumu uzerinde tam kontrol saglayabilirsiniz.

IronPDF, uzun yillar icinde en basit ve en kullanilabilir .NET PDF oluşturma kütüphanesidir - size PDF'leri oluşturmaya dakikalar icinde başlama imkani saglayan inanilmaz derecede kolay bir ogrenme egriyle. Bu kapsamli rehber, IronPDF kullanarak C#'ta PDF belgelerini nasıl oluşturacaginizi tam olarak gösterecektir - her modern .NET platformunu ve Kasim 2025'te yayinlanacak .NET 10 versionunu destekleyen guclu bir C# PDF oluşturucu. Bu eğitim, en basit kullanim alanlarindan en gelişmiş PDF oluşturma senaryolarina kadar her seyi kapsarken, korkmayin - basindan başlayin ve ilerleyin. PDF'leri oluşturmanin birden fazla yolunu, basit HTML dizilerinden kompleks birden fazla sayfa raporlarina kadar uretmeyi, ayrica yaygin sorunlarin nasıl cozulecegi ve çeşitli PDF oluşturma gorevleri icin performansi optimize etmenin nasıl yapilacagini ogreneceksiniz.

Ne Öğreneceksiniz

  1. Hizli Başlangic: Ilk PDF'inizi 2 Dakikadan Az Surede Oluşturun
  2. Gelİştiricİler Neden C#'ta PDF OIuşturmalİ
  3. C# Projenizde IronPDF'i Kurmak
  4. C#'de Farkli Yollarla PDF Oluşturma
  5. PDF'lerimi Nasıl Profesyonel Görünmesini Sağlayabilirim?

Hızlı Başlangıç: İlk PDF'inizi C#'de Oluşturun (2 Dakika İçinde)

Hemen şimdi bir PDF oluşturmak mı istiyorsunuz? Günümüzün modern PDF oluşturma gücünü .NET'te gösteren basit ama işlevsel bir PDF belgesi oluşturalım. Öncelikle, IronPDF'yi NuGet Paket Yöneticisi üzerinden yükleyin - bu tek paket, PDF oluşturmaya hemen başlamanız için gereken her şeyi içerir. IronPDF geliştirme için ücretsizdir, bu nedenle lisans kararı vermeden önce tüm özellikleri deneyebilirsiniz.

Install-Package IronPdf

Şimdi, C# kullanarak PDF içeriği oluşturalım:

using IronPdf;

// Instantiate the PDF generator - this is your gateway to PDF creation
var renderer = new ChromePdfRenderer();

// Create a PDF from HTML string - yes, it's really this simple!
var pdf = renderer.RenderHtmlAsPdf("<h1>Hello World</h1><p>PDF generated successfully!</p>");

// Save your newly created PDF document
pdf.SaveAs("my-first-pdf.pdf");

Console.WriteLine("PDF generated successfully!");
using IronPdf;

// Instantiate the PDF generator - this is your gateway to PDF creation
var renderer = new ChromePdfRenderer();

// Create a PDF from HTML string - yes, it's really this simple!
var pdf = renderer.RenderHtmlAsPdf("<h1>Hello World</h1><p>PDF generated successfully!</p>");

// Save your newly created PDF document
pdf.SaveAs("my-first-pdf.pdf");

Console.WriteLine("PDF generated successfully!");
Imports IronPdf

' Instantiate the PDF generator - this is your gateway to PDF creation
Private renderer = New ChromePdfRenderer()

' Create a PDF from HTML string - yes, it's really this simple!
Private pdf = renderer.RenderHtmlAsPdf("<h1>Hello World</h1><p>PDF generated successfully!</p>")

' Save your newly created PDF document
pdf.SaveAs("my-first-pdf.pdf")

Console.WriteLine("PDF generated successfully!")
$vbLabelText   $csharpLabel

Hepsi bu! İlk PDF belgenizi C#'da oluşturdunuz. Karmaşık PDF API'lerini öğrenmenize gerek yok, sunucu bağımlılıklarını yüklemenize gerek yok, düşük seviyeli PDF komutlarını öğrenmenize gerek yok. Sadece HTML içeri, PDF çıkışı - PDF oluşturmanın olması gereken yol. Ama bu sadece başlangıç - bu yaklaşımın neden bu kadar güçlü olduğunu ve daha sofistike PDF belgeleri nasıl oluşturabileceğinizi keşfedelim.

C#'da PDF Nasıl Oluşturulur: Hızlı Bir Genel Bakış

C#'da PDF oluşturmak için, IronPDF, QuestPDF veya PDFsharp gibi üçüncü taraf kütüphaneleri kullanabilirsiniz. Bu kütüphaneler, sıfırdan PDF oluşturma, HTML'i PDF'ye dönüştürme ve daha fazlası gibi çeşitli işlevler sunar.

İşte genel bir süreç özeti:

  1. Bir PDF kütüphanesi yükleyin: Uygun bir kütüphaneyi kurmak için Visual Studio'daki NuGet Paket Yöneticisini kullanın.
  2. Yeni bir PDF belgesi oluşturun: Bir PDF belge nesnesi oluşturun.
  3. İçerik ekleyin: Belgeye sayfalar, metinler, resimler ve diğer öğeler ekleyin.
  4. Belgeyi kaydedin: Bir dosya yolu belirtin ve PDF'yi kaydedin.

IronPDF kullanarak bir örnek:

using IronPdf;

public class Example
{
    public static void CreatePdf()
    {
        // Create a new PDF document
        var pdf = new ChromePdfRenderer();

        // Add some text
        string htmlContent = "<h1>Hello, PDF!</h1><p>This is a dynamically created PDF.</p>";

        // Render HTML to PDF
        var pdfDocument = pdf.RenderHtmlAsPdf(htmlContent);

        // Save the PDF
        pdfDocument.SaveAs("MyDynamicPdf.pdf");
    }
}
using IronPdf;

public class Example
{
    public static void CreatePdf()
    {
        // Create a new PDF document
        var pdf = new ChromePdfRenderer();

        // Add some text
        string htmlContent = "<h1>Hello, PDF!</h1><p>This is a dynamically created PDF.</p>";

        // Render HTML to PDF
        var pdfDocument = pdf.RenderHtmlAsPdf(htmlContent);

        // Save the PDF
        pdfDocument.SaveAs("MyDynamicPdf.pdf");
    }
}
Imports IronPdf

Public Class Example
	Public Shared Sub CreatePdf()
		' Create a new PDF document
		Dim pdf = New ChromePdfRenderer()

		' Add some text
		Dim htmlContent As String = "<h1>Hello, PDF!</h1><p>This is a dynamically created PDF.</p>"

		' Render HTML to PDF
		Dim pdfDocument = pdf.RenderHtmlAsPdf(htmlContent)

		' Save the PDF
		pdfDocument.SaveAs("MyDynamicPdf.pdf")
	End Sub
End Class
$vbLabelText   $csharpLabel

Şimdi geliştiricilerin neden PDF oluşturmaya ihtiyaç duyduğunu daha derinlemesine inceleyelim ve IronPDF'nin bu süreci nasıl basit ve güçlü hale getirdiğine bakalım.

Geliştiriciler Neden C#'da PDF Oluşturmaya İhtiyaç Duyarlar?

C# ile programatik olarak PDF oluşturmak, belge oluşturma otomasyonunu ve iş süreçlerini düzene sokmak için sonsuz olanaklar sunar. IronPDF, 14 milyondan fazla yüklenen geliştirici tarafından dünya çapında bu görevleri gerçekleştirmek için güvenilmektedir çünkü .NET'te PDF oluşturma için benzersiz güvenilirlik ve kullanım kolaylığı sağlar. Finans alanında, geliştiriciler C# kullanarak PDF faturaları, beyanları ve biçimlendirme ve güvenlik özellikleri gerektiren düzenleyici raporlar oluştururlar. Sağlık kuruluşları, belge bütünlüğü ve HIPAA uyumluluğunu sağlamak için hasta kayıtları, laboratuvar sonuçları ve sigorta formları gibi PDF'ler oluştururlar. E-ticaret platformları, doğrudan PDF'ye gömülü IronQR gibi araçları kullanarak QR kodları içeren PDF makbuzları, kargo etiketleri ve biletler üretir. PDF belgelerini programatik olarak manipüle etme yeteneği, belgesel ölçekte manuel müdahale olmadan oluşturma, değiştirme ve güvence altına alma olanağını sağlar.

Modern bir .NET PDF kütüphanesi olan IronPDF kullanmanın güzelliği, organizasyonunuzun mevcut iş akışlarına sorunsuz bir şekilde entegre olmasıdır. İş kullanıcılarınızdan Word belgelerini dönüştürmek, geliştirme ekibinizden Markdown belgelerini dönüştürmek veya web tabanlı raporları PDF olarak oluşturmak olsun, IronPDF hepsini halleder. Bu organizasyonel esneklik, şirketlerin programatik .NET'te PDF oluşturmayı neden tercih ettikleri - manuel belge oluşturmayı ortadan kaldırır, hataları azaltır, üretilen PDF'ler arasında tutarlılık sağlar ve sayısız saat çalışan zamanını kurtarır. Özel PDF söz dizimini öğrenmek yerine veya her öğeyi manuel olarak konumlandırmak yerine, belgelerinizi tasarlamak için HTML ve CSS kullanabilirsiniz. Bu yaklaşım geliştirme süresini önemli ölçüde azaltır ve tüm üretilen PDF'lerinizde tutarlı marka kimliğini sürdürmeyi kolaylaştırır. Tek sayfalık bir fatura veya karmaşık çok bölüm içeren bir rapor oluşturuyor olun, ilkeler aynı kalır - HTML ile tasarlayın, C# ile PDF oluşturun.

C# Projenizde IronPDF Kurulumu

PDF oluşturmaya başlamadan önce, geliştirme ortamınızın optimizasyon için doğru yapılandırıldığından emin olalım. IronPDF, .NET Foundation ve Microsoft ile sıkı işbirliği yaparak 2025 Kasım'ında planlanan .NET 10 sürümüne zaten uygun olan, .NET 8, .NET 9 dahil olmak üzere tüm modern .NET sürümlerini destekler. Kurulum süreci basit olduğunda, seçeneklerinizi anlamak, belirli ihtiyaçlarınız için en iyi yaklaşımı seçmenize yardımcı olur.

Yükleme Yöntemleri

Yöntem 1: Visual Studio Paket Yöneticisi (Yeni Başlayanlar İçin Önerilir)

IronPDF ile başlamak için en kolay yol, Visual Studio'nun yerleşik NuGet Paket Yöneticisi'dir. Bu grafik arayüz, PDF oluşturma bağımlılıklarınızı göz atmayı, yüklemeyi ve yönetmeyi basitleştirir:

  1. Solution Explorer'da projenizin uzerine sag tiklayin
  2. "NuGet Paketlerini Yonet"i secin
  3. "Gözat"a tıklayın ve "IronPDF" arayın
  4. Iron Software tarafından IronPdf paketini seçin
  5. Yükle'ye tıklayın ve lisans sözleşmesini kabul edin
Paket Yöneticisi Konsolu

Yöntem 2: Paket Yöneticisi Konsolu

Komut satırı araçlarını tercih eden geliştiriciler için, Paket Yöneticisi Konsolu IronPDF yüklemek için hızlı bir yol sunar:

Install-Package IronPdf

Yöntem 3: .NET CLI (Çapraz Platform Geliştirme İçin)

macOS, Linux üzerinde çalışıyorsanız veya .NET CLI'yı tercih ediyorsanız, proje dizininizde şu komutu kullanın:

dotnet add package IronPdf

Doğru Paketi Seçmek

IronPDF çeşitli dağıtım senaryoları için optimize edilmiş farklı NuGet paketleri sunar. Bu seçenekleri anlamak dağıtım boyutunu en aza indirgemenize ve performansı optimize etmenize yardımcı olur:

  • IronPdf: Windows, macOS ve Linux için ihtiyaçınız olan her şeyi içeren standart paket. Çoğu uygulama için mükemmel.
  • IronPdf.Slim: Çalışma zamanında platforma özgü bileşenleri indiren hafif bir temel paket. Paket boyutunun önemli olduğu bulut dağıtımları için idealdir.
  • IronPdf.Linux: Tüm gerekli bağımlılıkları önceden paketlenmiş olarak Linux dağıtımları için özel olarak optimize edilmiştir.
  • IronPdf.MacOs: Yerel Apple Silicon desteği ile macOS ortamları için özelleştirilmiştir.

Lütfen dikkate alinAzure, AWS veya Docker üzerinde bulut dağıtımları için, kapsayıcınızın boyutunu azaltmak için IronPdf.Slim'i kullanmayı düşünün. Gerekli bileşenler ilk kullanımda otomatik olarak indirilecektir.

Kurulumunuzu Doğrulama

Kurulumdan sonra, her şeyin doğru çalıştığını doğrulamak için yeni bir belge oluşturan bu basit testi yapın:

using IronPdf;
using System.IO;

// Test your IronPDF installation
var renderer = new ChromePdfRenderer();
var testPdf = renderer.RenderHtmlAsPdf("<p>Installation test successful!</p>");
testPdf.SaveAs("test.pdf");

if (File.Exists("test.pdf"))
{
    Console.WriteLine("IronPDF installed and working correctly!");
}
using IronPdf;
using System.IO;

// Test your IronPDF installation
var renderer = new ChromePdfRenderer();
var testPdf = renderer.RenderHtmlAsPdf("<p>Installation test successful!</p>");
testPdf.SaveAs("test.pdf");

if (File.Exists("test.pdf"))
{
    Console.WriteLine("IronPDF installed and working correctly!");
}
Imports IronPdf
Imports System.IO

' Test your IronPDF installation
Private renderer = New ChromePdfRenderer()
Private testPdf = renderer.RenderHtmlAsPdf("<p>Installation test successful!</p>")
testPdf.SaveAs("test.pdf")

If File.Exists("test.pdf") Then
	Console.WriteLine("IronPDF installed and working correctly!")
End If
$vbLabelText   $csharpLabel

C#'da Farklı PDF Üretme Yolları Nelerdir?

IronPDF, PDF belgeleri oluşturmak için farklı birden fazla yaklaşım sunar, her biri farklı senaryolar ve gereksinimlere uygundur. Bu yöntemleri anlamak, .NET'te PDF üretmeniz gerektiğinde sizin özel kullanım durumunuz için en verimli yaklaşımı seçmenize yardımcı olur. Sıfırdan HTML dizeleriyle PDF'ler oluşturmak, mevcut dosyaları dönüştürmek veya canlı web içeriğini yakalamak olsun, IronPDF, kapsamlı bir C# PDF oluşturucusu olarak tüm gereksinimlerinizi karşılar. Her yöntemi, gerçek dünya uygulamalarını C#'da PDF oluşturmak için gösteren pratik örneklerle detaylıca inceleyelim.

1. HTML Dizisinden PDF Oluşturmak (En Esnek)

HTML dizilerinden PDF oluşturmak, içeriği PDF formatına dönüştürmeniz gerektiğinde son belgenizin içeriği ve stil üzerinde tam kontrol sağlar. Bu yöntem, dinamik raporlar, faturalar veya içeriğin veri bazlı değiştiği herhangi bir belge oluşturmak için mükemmeldir. Modern HTML5 ve CSS3 özelliklerini, flexbox ve grid düzenlerini kullanarak HTML içeriğini profesyonel PDF'lere dönüştürebilirsiniz. HTML içeriğini dinamik olarak dönüştürme yeteneği, C#'da PDF oluşturmak için en esnek yaklaşımı haline getirir:

using IronPdf;
using System;
using System.Linq;

var renderer = new ChromePdfRenderer();

// Build dynamic content with data
var customerName = "Acme Corporation";
var orderDate = DateTime.Now;
var items = new[] { 
    new { Name = "Widget Pro", Price = 99.99m },
    new { Name = "Gadget Plus", Price = 149.99m }
};

// Create HTML with embedded data and modern CSS
var html = $@"
    <html>
    <head>
        <style>
            body {{ 
                font-family: 'Segoe UI', Arial, sans-serif; 
                margin: 40px;
                color: #333;
            }}
            .invoice-header {{
                display: flex;
                justify-content: space-between;
                border-bottom: 2px solid #0066cc;
                padding-bottom: 20px;
            }}
            .items-table {{
                width: 100%;
                margin-top: 30px;
                border-collapse: collapse;
            }}
            .items-table th {{
                background: #f0f0f0;
                padding: 10px;
                text-align: left;
            }}
        </style>
    </head>
    <body>
        <div class='invoice-header'>
            <div>
                <h1>Invoice</h1>
                <p>Customer: {customerName}</p>
            </div>
            <div>
                <p>Date: {orderDate:yyyy-MM-dd}</p>
                <p>Invoice #: INV-{orderDate:yyyyMMdd}-001</p>
            </div>
        </div>

        <table class='items-table'>
            <thead>
                <tr>
                    <th>Item</th>
                    <th>Price</th>
                </tr>
            </thead>
            <tbody>";

foreach (var item in items)
{
    html += $@"
                <tr>
                    <td>{item.Name}</td>
                    <td>${item.Price:F2}</td>
                </tr>";
}

html += @"
            </tbody>
        </table>
    </body>
    </html>";

// Generate the PDF document
var pdf = renderer.RenderHtmlAsPdf(html);
pdf.SaveAs($"invoice-{orderDate:yyyyMMdd}.pdf");
using IronPdf;
using System;
using System.Linq;

var renderer = new ChromePdfRenderer();

// Build dynamic content with data
var customerName = "Acme Corporation";
var orderDate = DateTime.Now;
var items = new[] { 
    new { Name = "Widget Pro", Price = 99.99m },
    new { Name = "Gadget Plus", Price = 149.99m }
};

// Create HTML with embedded data and modern CSS
var html = $@"
    <html>
    <head>
        <style>
            body {{ 
                font-family: 'Segoe UI', Arial, sans-serif; 
                margin: 40px;
                color: #333;
            }}
            .invoice-header {{
                display: flex;
                justify-content: space-between;
                border-bottom: 2px solid #0066cc;
                padding-bottom: 20px;
            }}
            .items-table {{
                width: 100%;
                margin-top: 30px;
                border-collapse: collapse;
            }}
            .items-table th {{
                background: #f0f0f0;
                padding: 10px;
                text-align: left;
            }}
        </style>
    </head>
    <body>
        <div class='invoice-header'>
            <div>
                <h1>Invoice</h1>
                <p>Customer: {customerName}</p>
            </div>
            <div>
                <p>Date: {orderDate:yyyy-MM-dd}</p>
                <p>Invoice #: INV-{orderDate:yyyyMMdd}-001</p>
            </div>
        </div>

        <table class='items-table'>
            <thead>
                <tr>
                    <th>Item</th>
                    <th>Price</th>
                </tr>
            </thead>
            <tbody>";

foreach (var item in items)
{
    html += $@"
                <tr>
                    <td>{item.Name}</td>
                    <td>${item.Price:F2}</td>
                </tr>";
}

html += @"
            </tbody>
        </table>
    </body>
    </html>";

// Generate the PDF document
var pdf = renderer.RenderHtmlAsPdf(html);
pdf.SaveAs($"invoice-{orderDate:yyyyMMdd}.pdf");
Imports IronPdf
Imports System
Imports System.Linq

Private renderer = New ChromePdfRenderer()

' Build dynamic content with data
Private customerName = "Acme Corporation"
Private orderDate = DateTime.Now
Private items = {
	New With {
		Key .Name = "Widget Pro",
		Key .Price = 99.99D
	},
	New With {
		Key .Name = "Gadget Plus",
		Key .Price = 149.99D
	}
}

' Create HTML with embedded data and modern CSS
Private html = $"
    <html>
    <head>
        <style>
            body {{ 
                font-family: 'Segoe UI', Arial, sans-serif; 
                margin: 40px;
                color: #333;
            }}
            .invoice-header {{
                display: flex;
                justify-content: space-between;
                border-bottom: 2px solid #0066cc;
                padding-bottom: 20px;
            }}
            .items-table {{
                width: 100%;
                margin-top: 30px;
                border-collapse: collapse;
            }}
            .items-table th {{
                background: #f0f0f0;
                padding: 10px;
                text-align: left;
            }}
        </style>
    </head>
    <body>
        <div class='invoice-header'>
            <div>
                <h1>Invoice</h1>
                <p>Customer: {customerName}</p>
            </div>
            <div>
                <p>Date: {orderDate:yyyy-MM-dd}</p>
                <p>Invoice #: INV-{orderDate:yyyyMMdd}-001</p>
            </div>
        </div>

        <table class='items-table'>
            <thead>
                <tr>
                    <th>Item</th>
                    <th>Price</th>
                </tr>
            </thead>
            <tbody>"

For Each item In items
	html += $"
                <tr>
                    <td>{item.Name}</td>
                    <td>${item.Price:F2}</td>
                </tr>"
Next item

html &= "
            </tbody>
        </table>
    </body>
    </html>"

' Generate the PDF document
Dim pdf = renderer.RenderHtmlAsPdf(html)
pdf.SaveAs($"invoice-{orderDate:yyyyMMdd}.pdf")
$vbLabelText   $csharpLabel

2. URL'den PDF Üretmek (Web Sayfası Yakalama)

Bazen mevcut web sayfalarını PDF belgelerine dönüştürmeniz gerekebilir - arşivleme, raporlama veya çevrimdışı versiyonlarını oluşturmak için mükemmeldir. IronPDF'nin URL'den PDF'ye dönüştürme işlemi, karmaşık JavaScript-ağır sitelerin doğru bir şekilde render edildiğinden emin olarak gerçek bir Chromium motoru kullanır. Bu yöntem, panoların anlık görüntülerini oluşturmak, çevrimiçi makbuzları kaydetmek veya web tabanlı raporları belgelemek için paha biçilmezdir:

URL'den PDF Örneği
using IronPdf;

var renderer = new ChromePdfRenderer();

// Configure rendering options for optimal capture
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
renderer.RenderingOptions.MarginTop = 25;
renderer.RenderingOptions.MarginBottom = 25;

// Wait for JavaScript to fully load (important for SPAs)
renderer.RenderingOptions.RenderDelay = 2000; // 2 seconds

// Enable JavaScript execution
renderer.RenderingOptions.EnableJavaScript = true;

// Capture a web page as PDF
var pdf = renderer.RenderUrlAsPdf("https://example.com/dashboard");
pdf.SaveAs("dashboard-capture.pdf");

// For authenticated pages, you can set cookies
var cookieManager = renderer.RenderingOptions.CustomCookies;
cookieManager["session_id"] = "your-session-token";

// Capture authenticated content
var securePdf = renderer.RenderUrlAsPdf("https://app.example.com/private/report");
securePdf.SaveAs("private-report.pdf");
using IronPdf;

var renderer = new ChromePdfRenderer();

// Configure rendering options for optimal capture
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
renderer.RenderingOptions.MarginTop = 25;
renderer.RenderingOptions.MarginBottom = 25;

// Wait for JavaScript to fully load (important for SPAs)
renderer.RenderingOptions.RenderDelay = 2000; // 2 seconds

// Enable JavaScript execution
renderer.RenderingOptions.EnableJavaScript = true;

// Capture a web page as PDF
var pdf = renderer.RenderUrlAsPdf("https://example.com/dashboard");
pdf.SaveAs("dashboard-capture.pdf");

// For authenticated pages, you can set cookies
var cookieManager = renderer.RenderingOptions.CustomCookies;
cookieManager["session_id"] = "your-session-token";

// Capture authenticated content
var securePdf = renderer.RenderUrlAsPdf("https://app.example.com/private/report");
securePdf.SaveAs("private-report.pdf");
Imports IronPdf

Private renderer = New ChromePdfRenderer()

' Configure rendering options for optimal capture
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4
renderer.RenderingOptions.MarginTop = 25
renderer.RenderingOptions.MarginBottom = 25

' Wait for JavaScript to fully load (important for SPAs)
renderer.RenderingOptions.RenderDelay = 2000 ' 2 seconds

' Enable JavaScript execution
renderer.RenderingOptions.EnableJavaScript = True

' Capture a web page as PDF
Dim pdf = renderer.RenderUrlAsPdf("https://example.com/dashboard")
pdf.SaveAs("dashboard-capture.pdf")

' For authenticated pages, you can set cookies
Dim cookieManager = renderer.RenderingOptions.CustomCookies
cookieManager("session_id") = "your-session-token"

' Capture authenticated content
Dim securePdf = renderer.RenderUrlAsPdf("https://app.example.com/private/report")
securePdf.SaveAs("private-report.pdf")
$vbLabelText   $csharpLabel

3. HTML Dosyasından PDF Oluşturmak (Şablon Tabanlı Üretim)

Şablon tabanlı PDF üretimi, tasarımcıların uygulama kodlarından bağımsız olarak karmaşık düzenleri sürdürebileceği durumlar için idealdir. HTML şablonlarını dosya olarak saklayarak, tasarım ile mantığın arasındaki temiz bir ayrım sağlayabilirsiniz. Bu yaklaşım, sertifikalar, sözleşmeler veya standart hale getirilmiş raporlar gibi tutarlı belgeler üretmek için son derece iyi çalışır:

HTML Dosyasından PDF'ye
using IronPdf;
using System.IO;
using System;

var renderer = new ChromePdfRenderer();

// Basic file conversion
var pdf = renderer.RenderHtmlFileAsPdf("Templates/certificate-template.html");
pdf.SaveAs("certificate.pdf");

// Advanced: Using templates with asset directories
// Perfect when your HTML references images, CSS, or JavaScript files
var basePath = Path.Combine(Directory.GetCurrentDirectory(), "Templates", "Assets");
var pdfWithAssets = renderer.RenderHtmlFileAsPdf(
    "Templates/report-template.html", 
    basePath  // IronPDF will resolve relative paths from here
);

// Even better: Template with placeholders
var templateHtml = File.ReadAllText("Templates/contract-template.html");
templateHtml = templateHtml
    .Replace("{{ClientName}}", "Tech Innovations Inc.")
    .Replace("{{ContractDate}}", DateTime.Now.ToString("MMMM dd, yyyy"))
    .Replace("{{ContractValue}}", "$50,000");

var contractPdf = renderer.RenderHtmlAsPdf(templateHtml);
contractPdf.SaveAs("contract-final.pdf");
using IronPdf;
using System.IO;
using System;

var renderer = new ChromePdfRenderer();

// Basic file conversion
var pdf = renderer.RenderHtmlFileAsPdf("Templates/certificate-template.html");
pdf.SaveAs("certificate.pdf");

// Advanced: Using templates with asset directories
// Perfect when your HTML references images, CSS, or JavaScript files
var basePath = Path.Combine(Directory.GetCurrentDirectory(), "Templates", "Assets");
var pdfWithAssets = renderer.RenderHtmlFileAsPdf(
    "Templates/report-template.html", 
    basePath  // IronPDF will resolve relative paths from here
);

// Even better: Template with placeholders
var templateHtml = File.ReadAllText("Templates/contract-template.html");
templateHtml = templateHtml
    .Replace("{{ClientName}}", "Tech Innovations Inc.")
    .Replace("{{ContractDate}}", DateTime.Now.ToString("MMMM dd, yyyy"))
    .Replace("{{ContractValue}}", "$50,000");

var contractPdf = renderer.RenderHtmlAsPdf(templateHtml);
contractPdf.SaveAs("contract-final.pdf");
Imports IronPdf
Imports System.IO
Imports System

Private renderer = New ChromePdfRenderer()

' Basic file conversion
Private pdf = renderer.RenderHtmlFileAsPdf("Templates/certificate-template.html")
pdf.SaveAs("certificate.pdf")

' Advanced: Using templates with asset directories
' Perfect when your HTML references images, CSS, or JavaScript files
Dim basePath = Path.Combine(Directory.GetCurrentDirectory(), "Templates", "Assets")
Dim pdfWithAssets = renderer.RenderHtmlFileAsPdf("Templates/report-template.html", basePath)

' Even better: Template with placeholders
Dim templateHtml = File.ReadAllText("Templates/contract-template.html")
templateHtml = templateHtml.Replace("{{ClientName}}", "Tech Innovations Inc.").Replace("{{ContractDate}}", DateTime.Now.ToString("MMMM dd, yyyy")).Replace("{{ContractValue}}", "$50,000")

Dim contractPdf = renderer.RenderHtmlAsPdf(templateHtml)
contractPdf.SaveAs("contract-final.pdf")
$vbLabelText   $csharpLabel

4. Markdown'dan PDF'ye Dönüştürmek

Markdown, teknik belgeler için standart hale geldi, README dosyaları ve içerik yönetim sistemleri için. IronPDF, Markdown içeriğini doğrudan PDF'ye dönüştürmeyi kolaylaştırır, biçimlendirmeyi korurken profesyonel görünümlü belgeler oluşturur. Bu özellik, belgelerini Markdown formatında sürdüren kuruluşlar için çok değerlidir - geliştiriciler tercih ettikleri formatta belgeleri yazabilir ve sistem, PDF'leri otomatik olarak müşterilere veya pay sahiplerine dağıtılmak için oluşturabilir.

using IronPdf;

var renderer = new ChromePdfRenderer();

// Convert Markdown string to PDF
string markdownContent = @"
# Project Documentation

## Overview
This project demonstrates **PDF generation** from _Markdown_ content.

### Features
- Easy conversion
- Preserves formatting
- Supports lists and tables

| Feature | Status |
|---------|--------|
| Markdown Support | |
| Table Rendering | |
| Code Blocks | |

```csharp
// Code blocks are preserved
var pdf = RenderMarkdownAsPdf(markdown);
\`\`\`
";

// Render Markdown as PDF
var pdfFromMarkdown = renderer.RenderMarkdownStringAsPdf(markdownContent);
pdfFromMarkdown.SaveAs("documentation.pdf");

// Convert Markdown file to PDF
var pdfFromFile = renderer.RenderMarkdownFileAsPdf("README.md");
pdfFromFile.SaveAs("readme-pdf.pdf");
using IronPdf;

var renderer = new ChromePdfRenderer();

// Convert Markdown string to PDF
string markdownContent = @"
# Project Documentation

## Overview
This project demonstrates **PDF generation** from _Markdown_ content.

### Features
- Easy conversion
- Preserves formatting
- Supports lists and tables

| Feature | Status |
|---------|--------|
| Markdown Support | |
| Table Rendering | |
| Code Blocks | |

```csharp
// Code blocks are preserved
var pdf = RenderMarkdownAsPdf(markdown);
\`\`\`
";

// Render Markdown as PDF
var pdfFromMarkdown = renderer.RenderMarkdownStringAsPdf(markdownContent);
pdfFromMarkdown.SaveAs("documentation.pdf");

// Convert Markdown file to PDF
var pdfFromFile = renderer.RenderMarkdownFileAsPdf("README.md");
pdfFromFile.SaveAs("readme-pdf.pdf");
Imports IronPdf

Dim renderer As New ChromePdfRenderer()

' Convert Markdown string to PDF
Dim markdownContent As String = "
# Project Documentation

## Overview
This project demonstrates **PDF generation** from _Markdown_ content.

### Features
- Easy conversion
- Preserves formatting
- Supports lists and tables

| Feature | Status |
|---------|--------|
| Markdown Support | |
| Table Rendering | |
| Code Blocks | |

```csharp
// Code blocks are preserved
var pdf = RenderMarkdownAsPdf(markdown);
\`\`\`
"

' Render Markdown as PDF
Dim pdfFromMarkdown = renderer.RenderMarkdownStringAsPdf(markdownContent)
pdfFromMarkdown.SaveAs("documentation.pdf")

' Convert Markdown file to PDF
Dim pdfFromFile = renderer.RenderMarkdownFileAsPdf("README.md")
pdfFromFile.SaveAs("readme-pdf.pdf")
$vbLabelText   $csharpLabel

Markdown'dan PDF'ye dönüşüm, Git gibi sürüm kontrol sistemlerini kullanan kuruluşlar için özellikle kullanışlıdır. Tüm belge iş akışınız otomatik hale getirilebilir - geliştiriciler Markdown dosyalarını günceller, CI/CD boru hatları otomatik olarak PDF belgeleri oluşturur ve paydaşlar manuel müdahale olmadan profesyonelce biçimlendirilmiş belgeler alır. Bu mevcut iş akışlarına sorunsuz entegrasyon, birçok geliştirme ekibinin belge ihtiyaçları için IronPDF'yi seçmesinin nedenidir.

5. Word Belgelerini (DOCX) PDF'ye Dönüştürmek

Birçok işletmenin dağıtım veya arşivleme için PDF'ye dönüştürülmesi gereken mevcut Word belgeleri vardır. IronPDF, biçimlendirme, resimler ve hatta posta birleştirme gibi karmaşık özellikleri koruyarak, sorunsuz DOCX'ten PDF'ye dönüşüm sağlar. Bu yetenek, işletmeler için dönüştürücüdür - iş kullanıcıları tanıdık Microsoft Word'de çalışmaya devam ederken, sistem otomatik olarak dış dağıtım için PDF'ler oluşturur. DOCX'ten PDF'ye dönüşüm özelliği, Word'ü tercih eden iş kullanıcıları ile güvenli, düzenlenemez PDF belgelerine duyulan ihtiyaç arasındaki boşluğu kapatır.

using IronPdf;
using System.Collections.Generic;

// Simple DOCX to PDF conversion
var docxRenderer = new DocxToPdfRenderer();
var pdfFromDocx = docxRenderer.RenderDocxAsPdf("proposal.docx");
pdfFromDocx.SaveAs("proposal.pdf");

// Advanced: Mail merge functionality for mass document generation
var recipients = new List<Dictionary<string, string>>
{
    new() { ["Name"] = "John Smith", ["Company"] = "Tech Corp", ["Date"] = "March 15, 2024" },
    new() { ["Name"] = "Jane Doe", ["Company"] = "Innovation Inc", ["Date"] = "March 15, 2024" }
};

// Configure mail merge options
var options = new DocxPdfRenderOptions
{
    MailMergeDataSource = recipients,
    MailMergePrintAllInOnePdfDocument = false // Creates separate PDFs
};

// Generate personalized PDFs from template
foreach (var recipient in recipients)
{
    var personalizedPdf = docxRenderer.RenderDocxAsPdf("letter-template.docx", options);
    personalizedPdf.SaveAs($"letter-{recipient["Name"].Replace(" ", "-")}.pdf");
}
using IronPdf;
using System.Collections.Generic;

// Simple DOCX to PDF conversion
var docxRenderer = new DocxToPdfRenderer();
var pdfFromDocx = docxRenderer.RenderDocxAsPdf("proposal.docx");
pdfFromDocx.SaveAs("proposal.pdf");

// Advanced: Mail merge functionality for mass document generation
var recipients = new List<Dictionary<string, string>>
{
    new() { ["Name"] = "John Smith", ["Company"] = "Tech Corp", ["Date"] = "March 15, 2024" },
    new() { ["Name"] = "Jane Doe", ["Company"] = "Innovation Inc", ["Date"] = "March 15, 2024" }
};

// Configure mail merge options
var options = new DocxPdfRenderOptions
{
    MailMergeDataSource = recipients,
    MailMergePrintAllInOnePdfDocument = false // Creates separate PDFs
};

// Generate personalized PDFs from template
foreach (var recipient in recipients)
{
    var personalizedPdf = docxRenderer.RenderDocxAsPdf("letter-template.docx", options);
    personalizedPdf.SaveAs($"letter-{recipient["Name"].Replace(" ", "-")}.pdf");
}
Imports IronPdf
Imports System.Collections.Generic

' Simple DOCX to PDF conversion
Private docxRenderer = New DocxToPdfRenderer()
Private pdfFromDocx = docxRenderer.RenderDocxAsPdf("proposal.docx")
pdfFromDocx.SaveAs("proposal.pdf")

' Advanced: Mail merge functionality for mass document generation
Dim recipients = New List(Of Dictionary(Of String, String)) From {
	New() {
		("Name") = "John Smith",
		("Company") = "Tech Corp",
		("Date") = "March 15, 2024"
	},
	New() {
		("Name") = "Jane Doe",
		("Company") = "Innovation Inc",
		("Date") = "March 15, 2024"
	}
}

' Configure mail merge options
Dim options = New DocxPdfRenderOptions With {
	.MailMergeDataSource = recipients,
	.MailMergePrintAllInOnePdfDocument = False
}

' Generate personalized PDFs from template
For Each recipient In recipients
	Dim personalizedPdf = docxRenderer.RenderDocxAsPdf("letter-template.docx", options)
	personalizedPdf.SaveAs($"letter-{recipient("Name").Replace(" ", "-")}.pdf")
Next recipient
$vbLabelText   $csharpLabel

Bu DOCX dönüşüm özelliği, organizasyon içindeki belge iş akışlarını otomatikleştirmek için paha biçilmezdir. Bir satış ekibinin teklifleri Word'de oluşturduğunu düşünün – IronPDF ile bu teklifler, programatik olarak filigranlar eklenerek, güvenlik ayarları uygulanarak ve dijital imzalar eklenerek otomatik olarak PDF'ye dönüştürülebilir. Posta birleştirme işlevi, manuel müdahale olmadan binlerce kişiselleştirilmiş mektup, sertifika veya sözleşme oluşturmak için mükemmel olan kişiselleştirilmiş PDF belgelerinin kitlesel olarak üretilmesini sağlar. Bu entegrasyon yeteneği, IronPDF'nin dünya genelinde işletmeler tarafından belge otomasyon ihtiyaçlarını karşılamak için güvenilir olmasını sağlayan sebeptir.

6. Görüntüleri PDF'ye Dönüştürme

Görüntüleri PDF'ye dönüştürmek, fotoğraf albümleri, taranmış belge derlemeleri veya görüntü tabanlı raporlar oluşturmak için esastır. IronPDF, tüm ana görüntü formatlarını destekler ve düzen ve kaliteyi kontrol etme seçenekleri sunar:

using IronPdf;
using IronPdf.Imaging; // Install-Package IronPdf
using System.IO;

var renderer = new ChromePdfRenderer();

// Convert single image to PDF
var imagePath = "product-photo.jpg";
var imageHtml = $@"
    <html>
    <body style='margin: 0; padding: 0;'>
        <img src='{imagePath}' style='width: 100%; height: auto;' />
    </body>
    </html>";

var imagePdf = renderer.RenderHtmlAsPdf(imageHtml, Path.GetDirectoryName(imagePath));
imagePdf.SaveAs("product-catalog-page.pdf");

// Create multi-page PDF from multiple images
var imageFiles = Directory.GetFiles("ProductImages", "*.jpg");
var catalogHtml = "<html><body style='margin: 0;'>";

foreach (var image in imageFiles)
{
    catalogHtml += $@"
        <div style='page-break-after: always;'>
            <img src='{Path.GetFileName(image)}' style='width: 100%; height: auto;' />
            <p style='text-align: center;'>{Path.GetFileNameWithoutExtension(image)}</p>
        </div>";
}

catalogHtml += "</body></html>";

var catalogPdf = renderer.RenderHtmlAsPdf(catalogHtml, "ProductImages");
catalogPdf.SaveAs("product-catalog.pdf");
using IronPdf;
using IronPdf.Imaging; // Install-Package IronPdf
using System.IO;

var renderer = new ChromePdfRenderer();

// Convert single image to PDF
var imagePath = "product-photo.jpg";
var imageHtml = $@"
    <html>
    <body style='margin: 0; padding: 0;'>
        <img src='{imagePath}' style='width: 100%; height: auto;' />
    </body>
    </html>";

var imagePdf = renderer.RenderHtmlAsPdf(imageHtml, Path.GetDirectoryName(imagePath));
imagePdf.SaveAs("product-catalog-page.pdf");

// Create multi-page PDF from multiple images
var imageFiles = Directory.GetFiles("ProductImages", "*.jpg");
var catalogHtml = "<html><body style='margin: 0;'>";

foreach (var image in imageFiles)
{
    catalogHtml += $@"
        <div style='page-break-after: always;'>
            <img src='{Path.GetFileName(image)}' style='width: 100%; height: auto;' />
            <p style='text-align: center;'>{Path.GetFileNameWithoutExtension(image)}</p>
        </div>";
}

catalogHtml += "</body></html>";

var catalogPdf = renderer.RenderHtmlAsPdf(catalogHtml, "ProductImages");
catalogPdf.SaveAs("product-catalog.pdf");
Imports IronPdf
Imports IronPdf.Imaging ' Install-Package IronPdf
Imports System.IO

Private renderer = New ChromePdfRenderer()

' Convert single image to PDF
Private imagePath = "product-photo.jpg"
Private imageHtml = $"
    <html>
    <body style='margin: 0; padding: 0;'>
        <img src='{imagePath}' style='width: 100%; height: auto;' />
    </body>
    </html>"

Private imagePdf = renderer.RenderHtmlAsPdf(imageHtml, Path.GetDirectoryName(imagePath))
imagePdf.SaveAs("product-catalog-page.pdf")

' Create multi-page PDF from multiple images
Dim imageFiles = Directory.GetFiles("ProductImages", "*.jpg")
Dim catalogHtml = "<html><body style='margin: 0;'>"

For Each image In imageFiles
	catalogHtml &= $"
        <div style='page-break-after: always;'>
            <img src='{Path.GetFileName(image)}' style='width: 100%; height: auto;' />
            <p style='text-align: center;'>{Path.GetFileNameWithoutExtension(image)}</p>
        </div>"
Next image

catalogHtml &= "</body></html>"

Dim catalogPdf = renderer.RenderHtmlAsPdf(catalogHtml, "ProductImages")
catalogPdf.SaveAs("product-catalog.pdf")
$vbLabelText   $csharpLabel

7. ASP.NET Sayfalarından PDF Oluşturma

Web uygulamaları için mevcut görünümlerinizden PDF'ler oluşturmak, web içeriğinin indirilebilir versiyonlarını yaratmanın kusursuz bir yolunu sağlar. Bu entegrasyon yeteneği, müşteri portalları bildirim oluştururken, idari panolar raporlar üretirken veya e-öğrenme platformları sertifikalar yaratırken, web uygulamalarından PDF'ler oluşturması gereken organizasyonlar için kritiktir. IronPDF, MVC, Razor Pages ve Blazor dahil olmak üzere tüm ASP.NET teknolojileriyle çalışır ve Microsoft ekosistemine zaten yatırım yapmış olan organizasyonlar için mükemmel bir seçimdir:

// Namespace: Microsoft.AspNetCore.Mvc
using Microsoft.AspNetCore.Mvc;
// Namespace: IronPdf
using IronPdf;
// Namespace: System.Threading.Tasks
using System.Threading.Tasks;
// Namespace: System.IO
using System.IO;
// Namespace: System
using System;

// ASP.NET Core MVC Controller
public class ReportController : Controller
{
    private readonly ChromePdfRenderer _pdfRenderer;

    public ReportController()
    {
        _pdfRenderer = new ChromePdfRenderer();
    }

    public async Task<IActionResult> DownloadReport(int reportId)
    {
        // Get your report data
        var reportData = await GetReportData(reportId);

        // Render view to HTML string
        var html = await RenderViewToStringAsync("Reports/MonthlyReport", reportData);

        // Convert HTML content to PDF
        var pdf = _pdfRenderer.RenderHtmlAsPdf(html);

        // Return as file download
        return File(
            pdf.BinaryData, 
            "application/pdf", 
            $"report-{reportId}-{DateTime.Now:yyyy-MM}.pdf"
        );
    }

    private async Task<string> RenderViewToStringAsync(string viewName, object model)
    {
        ViewData.Model = model;
        using var sw = new StringWriter();
        var viewResult = ViewEngines.Engines.FindPartialView(ControllerContext, viewName);
        var viewContext = new ViewContext(
            ControllerContext, 
            viewResult.View, 
            ViewData, 
            TempData, 
            sw, 
            new HtmlHelperOptions()
        );
        viewResult.View.Render(viewContext, sw);
        return sw.GetStringBuilder().ToString();
    }
}
// Namespace: Microsoft.AspNetCore.Mvc
using Microsoft.AspNetCore.Mvc;
// Namespace: IronPdf
using IronPdf;
// Namespace: System.Threading.Tasks
using System.Threading.Tasks;
// Namespace: System.IO
using System.IO;
// Namespace: System
using System;

// ASP.NET Core MVC Controller
public class ReportController : Controller
{
    private readonly ChromePdfRenderer _pdfRenderer;

    public ReportController()
    {
        _pdfRenderer = new ChromePdfRenderer();
    }

    public async Task<IActionResult> DownloadReport(int reportId)
    {
        // Get your report data
        var reportData = await GetReportData(reportId);

        // Render view to HTML string
        var html = await RenderViewToStringAsync("Reports/MonthlyReport", reportData);

        // Convert HTML content to PDF
        var pdf = _pdfRenderer.RenderHtmlAsPdf(html);

        // Return as file download
        return File(
            pdf.BinaryData, 
            "application/pdf", 
            $"report-{reportId}-{DateTime.Now:yyyy-MM}.pdf"
        );
    }

    private async Task<string> RenderViewToStringAsync(string viewName, object model)
    {
        ViewData.Model = model;
        using var sw = new StringWriter();
        var viewResult = ViewEngines.Engines.FindPartialView(ControllerContext, viewName);
        var viewContext = new ViewContext(
            ControllerContext, 
            viewResult.View, 
            ViewData, 
            TempData, 
            sw, 
            new HtmlHelperOptions()
        );
        viewResult.View.Render(viewContext, sw);
        return sw.GetStringBuilder().ToString();
    }
}
' Namespace: Microsoft.AspNetCore.Mvc
Imports Microsoft.AspNetCore.Mvc
' Namespace: IronPdf
Imports IronPdf
' Namespace: System.Threading.Tasks
Imports System.Threading.Tasks
' Namespace: System.IO
Imports System.IO
' Namespace: System
Imports System

' ASP.NET Core MVC Controller
Public Class ReportController
	Inherits Controller

	Private ReadOnly _pdfRenderer As ChromePdfRenderer

	Public Sub New()
		_pdfRenderer = New ChromePdfRenderer()
	End Sub

	Public Async Function DownloadReport(ByVal reportId As Integer) As Task(Of IActionResult)
		' Get your report data
		Dim reportData = Await GetReportData(reportId)

		' Render view to HTML string
		Dim html = Await RenderViewToStringAsync("Reports/MonthlyReport", reportData)

		' Convert HTML content to PDF
		Dim pdf = _pdfRenderer.RenderHtmlAsPdf(html)

		' Return as file download
		Return File(pdf.BinaryData, "application/pdf", $"report-{reportId}-{DateTime.Now:yyyy-MM}.pdf")
	End Function

	Private Async Function RenderViewToStringAsync(ByVal viewName As String, ByVal model As Object) As Task(Of String)
		ViewData.Model = model
		Dim sw = New StringWriter()
		Dim viewResult = ViewEngines.Engines.FindPartialView(ControllerContext, viewName)
		Dim viewContext As New ViewContext(ControllerContext, viewResult.View, ViewData, TempData, sw, New HtmlHelperOptions())
		viewResult.View.Render(viewContext, sw)
		Return sw.GetStringBuilder().ToString()
	End Function
End Class
$vbLabelText   $csharpLabel

PDF'lerimi Nasıl Profesyonel Gösteririm?

PDF oluşturmak bir şey; onları profesyonel göstermek, uygulamanızı .NET'te PDF oluştururken öne çıkaran şeydir. Profesyonel PDF belgeleri, doğru izlenim yaratmak için düzene, tipografiye ve marka tutarlılığına dikkat gerektirir. IronPDF'nin kapsamlı stil seçenekleri ve gelişmiş PDF özellikleri ile, bu güçlü C# PDF üreteci kullanarak şirket kimliğinize mükemmel uyacak belgeler oluşturabilirsiniz. HTML'den PDF'ye dönüştürme yetenekleri, stilize belgelerinizin PDF olarak üretildiğinde görsel cazibesini korumasını sağlar. Temel PDF'leri cilalı, profesyonel belgeler haline getiren ve müşterileri ve paydaşları etkileyen özellikleri inceleyelim.

Başlıklar, Altbilgiler ve Sayfa Numaraları

Profesyonel belgelerin, bağlam ve gezinme sağlayan tutarlı başlıklar ve altbilgilere ihtiyaçı vardır. IronPDF, başlıklar ve altbilgiler için hem basit metin tabanlı hem de karmaşık HTML tabanlı seçenekler sunar. Bu esneklik, organizasyonların markalı PDF belgeleri ölçekli olarak oluşturması gerektiğinde IronPDF'yi seçmelerinin sebebidir. Sayfa numaraları, tarihler ve belge başlıkları gibi dinamik içerikleri dahil edebilirsiniz - her üretilmiş PDFin profesyonel standartları korumasını sağlayarak:

using IronPdf;
using System;

var renderer = new ChromePdfRenderer();

// Simple text header and footer with page numbers
renderer.RenderingOptions.TextHeader = new TextHeaderFooter
{
    Text = "Confidential Report - {date}",
    DrawDividerLine = true,
    Font = "Arial",
    FontSize = 12
};

renderer.RenderingOptions.TextFooter = new TextHeaderFooter
{
    Text = "Page {page} of {total-pages}",
    DrawDividerLine = true,
    Font = "Arial", 
    FontSize = 10,
    CenterText = true
};

// HTML headers for complex layouts with logos
renderer.RenderingOptions.HtmlHeader = new HtmlHeaderFooter
{
    Html = @"
        <div style='display: flex; justify-content: space-between; align-items: center; padding: 10px 40px;'>
            <img src='logo.png' style='height: 40px;' />
            <div style='text-align: center;'>
                <h2 style='margin: 0; color: #333;'>Annual Report 2024</h2>
                <p style='margin: 0; font-size: 12px; color: #666;'>Confidential</p>
            </div>
            <div style='text-align: right; font-size: 11px; color: #666;'>
                Generated: {date}<br/>
                Department: Finance
            </div>
        </div>",
    Height = 80,
    LoadStylesAndCSSFromMainHtmlDocument = true
};

// Create your PDF with professional headers/footers
var html = @"<h1>Financial Overview</h1><p>Report content here...</p>";
var pdf = renderer.RenderHtmlAsPdf(html);
pdf.SaveAs("professional-report.pdf");
using IronPdf;
using System;

var renderer = new ChromePdfRenderer();

// Simple text header and footer with page numbers
renderer.RenderingOptions.TextHeader = new TextHeaderFooter
{
    Text = "Confidential Report - {date}",
    DrawDividerLine = true,
    Font = "Arial",
    FontSize = 12
};

renderer.RenderingOptions.TextFooter = new TextHeaderFooter
{
    Text = "Page {page} of {total-pages}",
    DrawDividerLine = true,
    Font = "Arial", 
    FontSize = 10,
    CenterText = true
};

// HTML headers for complex layouts with logos
renderer.RenderingOptions.HtmlHeader = new HtmlHeaderFooter
{
    Html = @"
        <div style='display: flex; justify-content: space-between; align-items: center; padding: 10px 40px;'>
            <img src='logo.png' style='height: 40px;' />
            <div style='text-align: center;'>
                <h2 style='margin: 0; color: #333;'>Annual Report 2024</h2>
                <p style='margin: 0; font-size: 12px; color: #666;'>Confidential</p>
            </div>
            <div style='text-align: right; font-size: 11px; color: #666;'>
                Generated: {date}<br/>
                Department: Finance
            </div>
        </div>",
    Height = 80,
    LoadStylesAndCSSFromMainHtmlDocument = true
};

// Create your PDF with professional headers/footers
var html = @"<h1>Financial Overview</h1><p>Report content here...</p>";
var pdf = renderer.RenderHtmlAsPdf(html);
pdf.SaveAs("professional-report.pdf");
Imports IronPdf
Imports System

Private renderer = New ChromePdfRenderer()

' Simple text header and footer with page numbers
renderer.RenderingOptions.TextHeader = New TextHeaderFooter With {
	.Text = "Confidential Report - {date}",
	.DrawDividerLine = True,
	.Font = "Arial",
	.FontSize = 12
}

renderer.RenderingOptions.TextFooter = New TextHeaderFooter With {
	.Text = "Page {page} of {total-pages}",
	.DrawDividerLine = True,
	.Font = "Arial",
	.FontSize = 10,
	.CenterText = True
}

' HTML headers for complex layouts with logos
renderer.RenderingOptions.HtmlHeader = New HtmlHeaderFooter With {
	.Html = "
        <div style='display: flex; justify-content: space-between; align-items: center; padding: 10px 40px;'>
            <img src='logo.png' style='height: 40px;' />
            <div style='text-align: center;'>
                <h2 style='margin: 0; color: #333;'>Annual Report 2024</h2>
                <p style='margin: 0; font-size: 12px; color: #666;'>Confidential</p>
            </div>
            <div style='text-align: right; font-size: 11px; color: #666;'>
                Generated: {date}<br/>
                Department: Finance
            </div>
        </div>",
	.Height = 80,
	.LoadStylesAndCSSFromMainHtmlDocument = True
}

' Create your PDF with professional headers/footers
Dim html = "<h1>Financial Overview</h1><p>Report content here...</p>"
Dim pdf = renderer.RenderHtmlAsPdf(html)
pdf.SaveAs("professional-report.pdf")
$vbLabelText   $csharpLabel

Bu başlık ve altbilgi seçenekleri, organizasyonların tüm üretilmiş PDF'ler arasında marka tutarlılığını korumasını sağlar. Finansal raporlar veya teknik dokümantasyon oluşturuyorsanız, profesyonel başlıklar ve altbilgiler belgelerinizin kurumsal standartlara uymasını sağlar.

Gelişmiş Sayfa Ayarı ve Düzen Kontrolü

Sayfa düzeni üzerindeki kontrol, belgelerin doğru yazdırılması ve tüm cihazlarda profesyonel görünmesi için çok önemlidir. IronPDF, özel boyutlar, yönler ve kenar boşlukları dahil sayfa ayarı için geniş seçenekler sunar:

var renderer = new ChromePdfRenderer();

// Configure page setup for professional printing
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
renderer.RenderingOptions.PaperOrientation = PdfPaperOrientation.Portrait;

// Set margins in millimeters for precise control
renderer.RenderingOptions.MarginTop = 25;
renderer.RenderingOptions.MarginBottom = 25;
renderer.RenderingOptions.MarginLeft = 20;
renderer.RenderingOptions.MarginRight = 20;

// Enable background colors and images (important for branding)
renderer.RenderingOptions.PrintHtmlBackgrounds = true;

// Use screen media type for vibrant colors
renderer.RenderingOptions.CssMediaType = PdfCssMediaType.Screen;

// Custom page size for special documents
renderer.RenderingOptions.SetCustomPaperSizeinMilimeters(210, 297); // A4

// Enable high-quality rendering
renderer.RenderingOptions.RenderQuality = 100; // 0-100 scale
var renderer = new ChromePdfRenderer();

// Configure page setup for professional printing
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
renderer.RenderingOptions.PaperOrientation = PdfPaperOrientation.Portrait;

// Set margins in millimeters for precise control
renderer.RenderingOptions.MarginTop = 25;
renderer.RenderingOptions.MarginBottom = 25;
renderer.RenderingOptions.MarginLeft = 20;
renderer.RenderingOptions.MarginRight = 20;

// Enable background colors and images (important for branding)
renderer.RenderingOptions.PrintHtmlBackgrounds = true;

// Use screen media type for vibrant colors
renderer.RenderingOptions.CssMediaType = PdfCssMediaType.Screen;

// Custom page size for special documents
renderer.RenderingOptions.SetCustomPaperSizeinMilimeters(210, 297); // A4

// Enable high-quality rendering
renderer.RenderingOptions.RenderQuality = 100; // 0-100 scale
Dim renderer = New ChromePdfRenderer()

' Configure page setup for professional printing
renderer.RenderingOptions.PaperSize = PdfPaperSize.A4
renderer.RenderingOptions.PaperOrientation = PdfPaperOrientation.Portrait

' Set margins in millimeters for precise control
renderer.RenderingOptions.MarginTop = 25
renderer.RenderingOptions.MarginBottom = 25
renderer.RenderingOptions.MarginLeft = 20
renderer.RenderingOptions.MarginRight = 20

' Enable background colors and images (important for branding)
renderer.RenderingOptions.PrintHtmlBackgrounds = True

' Use screen media type for vibrant colors
renderer.RenderingOptions.CssMediaType = PdfCssMediaType.Screen

' Custom page size for special documents
renderer.RenderingOptions.SetCustomPaperSizeinMilimeters(210, 297) ' A4

' Enable high-quality rendering
renderer.RenderingOptions.RenderQuality = 100 ' 0-100 scale
$vbLabelText   $csharpLabel

Yazı Tipleri ve Tipografi ile Çalışma

Tipografi, belge profesyonelliğinde önemli bir rol oynar. IronPDF, web yazı tipleri, özel yazı tipleri ve gelişmiş tipografi özelliklerini destekler:

var renderer = new ChromePdfRenderer();

// HTML with custom fonts and typography
var html = @"
    <html>
    <head>
        <link href='https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;700&display=swap' rel='stylesheet'>
        <style>
            @font-face {
                font-family: 'CustomBrand';
                src: url('BrandFont.ttf') format('truetype');
            }

            body {
                font-family: 'Roboto', Arial, sans-serif;
                font-size: 11pt;
                line-height: 1.6;
                color: #333;
            }

            h1 {
                font-family: 'CustomBrand', Georgia, serif;
                font-size: 28pt;
                color: #0066cc;
                letter-spacing: -0.5px;
            }

            .quote {
                font-style: italic;
                font-size: 14pt;
                color: #666;
                border-left: 4px solid #0066cc;
                padding-left: 20px;
                margin: 20px 0;
            }
        </style>
    </head>
    <body>
        # Professional Document
        <p>This document demonstrates professional typography.</p>
        <div class='quote'>
            "Excellence in typography enhances readability and professionalism."
        </div>
    </body>
    </html>";

var pdf = renderer.RenderHtmlAsPdf(html, "Assets/Fonts");
pdf.SaveAs("typography-demo.pdf");
var renderer = new ChromePdfRenderer();

// HTML with custom fonts and typography
var html = @"
    <html>
    <head>
        <link href='https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;700&display=swap' rel='stylesheet'>
        <style>
            @font-face {
                font-family: 'CustomBrand';
                src: url('BrandFont.ttf') format('truetype');
            }

            body {
                font-family: 'Roboto', Arial, sans-serif;
                font-size: 11pt;
                line-height: 1.6;
                color: #333;
            }

            h1 {
                font-family: 'CustomBrand', Georgia, serif;
                font-size: 28pt;
                color: #0066cc;
                letter-spacing: -0.5px;
            }

            .quote {
                font-style: italic;
                font-size: 14pt;
                color: #666;
                border-left: 4px solid #0066cc;
                padding-left: 20px;
                margin: 20px 0;
            }
        </style>
    </head>
    <body>
        # Professional Document
        <p>This document demonstrates professional typography.</p>
        <div class='quote'>
            "Excellence in typography enhances readability and professionalism."
        </div>
    </body>
    </html>";

var pdf = renderer.RenderHtmlAsPdf(html, "Assets/Fonts");
pdf.SaveAs("typography-demo.pdf");
Imports System

Dim renderer = New ChromePdfRenderer()

' HTML with custom fonts and typography
Dim html = "
    <html>
    <head>
        <link href='https://fonts.googleapis.com/css2?family=Roboto:wght@300;400;700&display=swap' rel='stylesheet'>
        <style>
            @font-face {
                font-family: 'CustomBrand';
                src: url('BrandFont.ttf') format('truetype');
            }

            body {
                font-family: 'Roboto', Arial, sans-serif;
                font-size: 11pt;
                line-height: 1.6;
                color: #333;
            }

            h1 {
                font-family: 'CustomBrand', Georgia, serif;
                font-size: 28pt;
                color: #0066cc;
                letter-spacing: -0.5px;
            }

            .quote {
                font-style: italic;
                font-size: 14pt;
                color: #666;
                border-left: 4px solid #0066cc;
                padding-left: 20px;
                margin: 20px 0;
            }
        </style>
    </head>
    <body>
        # Professional Document
        <p>This document demonstrates professional typography.</p>
        <div class='quote'>
            ""Excellence in typography enhances readability and professionalism.""
        </div>
    </body>
    </html>"

Dim pdf = renderer.RenderHtmlAsPdf(html, "Assets/Fonts")
pdf.SaveAs("typography-demo.pdf")
$vbLabelText   $csharpLabel

Gerçek Dünya Örneği: Nasıl Fatura PDF Açarım?

Üretime hazır, tamamlanmış bir fatura üreteci oluşturup, gerçek dünya uygulamalarında PDF belgeleri oluşturma için en iyi uygulamaları gösterelim. Bu örnek, binlerce işletmenin IronPDF'yi fatura üretim ihtiyaçları için C# PDF üreteci olarak seçmesinin nedenini ortaya koyar - veri bağlama, profesyonel stil ve doğru belge yapısını güçlü ve bakımı kolay bir şekilde bir araya getirir. Benzer uygulamalar, e-ticaret platformları tarafından aylık milyonlarca fatura üretmek için kullanılır ve .NET'teki programatik PDF üretiminin ölçeklenebilirliğini gösterir. Bu kodu, kendi PDF oluşturma görevleriniz için uyarlayabilirsiniz:

using IronPdf;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;

public class InvoiceGenerator
{
    private readonly ChromePdfRenderer _renderer;

    public InvoiceGenerator()
    {
        _renderer = new ChromePdfRenderer();
        ConfigureRenderer();
    }

    private void ConfigureRenderer()
    {
        // Professional page setup
        _renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
        _renderer.RenderingOptions.MarginTop = 25;
        _renderer.RenderingOptions.MarginBottom = 25;
        _renderer.RenderingOptions.MarginLeft = 25;
        _renderer.RenderingOptions.MarginRight = 25;
        _renderer.RenderingOptions.PrintHtmlBackgrounds = true;

        // Add footer with page numbers
        _renderer.RenderingOptions.TextFooter = new TextHeaderFooter
        {
            Text = "Page {page} of {total-pages} | Invoice generated on {date}",
            FontSize = 9,
            Font = "Arial",
            CenterText = true
        };
    }

    public void CreateInvoice(Invoice invoice)
    {
        var html = GenerateInvoiceHtml(invoice);
        var pdf = _renderer.RenderHtmlAsPdf(html);

        // Add metadata to the final document
        pdf.MetaData.Title = $"Invoice {invoice.Number}";
        pdf.MetaData.Author = "Your Company Name";
        pdf.MetaData.Subject = $"Invoice for {invoice.CustomerName}";
        pdf.MetaData.Keywords = "invoice, billing, payment";
        pdf.MetaData.CreationDate = DateTime.Now;

        // Save the PDF document
        var fileName = $"Invoice-{invoice.Number}.pdf";
        pdf.SaveAs(fileName);

        Console.WriteLine($"PDF generated successfully: {fileName}");
    }

    private string GenerateInvoiceHtml(Invoice invoice)
    {
        var itemsHtml = string.Join("", invoice.Items.Select(item => $@"
            <tr>
                <td style='padding: 12px; border-bottom: 1px solid #eee;'>{item.Description}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: center;'>{item.Quantity}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.UnitPrice:F2}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.Total:F2}</td>
            </tr>"));

        return $@"
            <html>
            <head>
                <style>
                    * {{ box-sizing: border-box; }}
                    body {{ 
                        font-family: 'Segoe UI', Arial, sans-serif; 
                        line-height: 1.6;
                        color: #333;
                        margin: 0;
                        padding: 0;
                    }}
                    .invoice-container {{
                        max-width: 800px;
                        margin: 0 auto;
                        padding: 40px;
                    }}
                    .invoice-header {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                        padding-bottom: 20px;
                        border-bottom: 3px solid #0066cc;
                    }}
                    .company-details {{
                        flex: 1;
                    }}
                    .company-details h1 {{
                        color: #0066cc;
                        margin: 0 0 10px 0;
                        font-size: 28px;
                    }}
                    .invoice-details {{
                        flex: 1;
                        text-align: right;
                    }}
                    .invoice-details h2 {{
                        margin: 0 0 10px 0;
                        color: #666;
                        font-size: 24px;
                    }}
                    .invoice-number {{
                        font-size: 18px;
                        color: #0066cc;
                        font-weight: bold;
                    }}
                    .billing-section {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                    }}
                    .billing-box {{
                        flex: 1;
                        padding: 20px;
                        background: #f8f9fa;
                        border-radius: 8px;
                        margin-right: 20px;
                    }}
                    .billing-box:last-child {{
                        margin-right: 0;
                    }}
                    .billing-box h3 {{
                        margin: 0 0 15px 0;
                        color: #0066cc;
                        font-size: 16px;
                        text-transform: uppercase;
                        letter-spacing: 1px;
                    }}
                    .items-table {{
                        width: 100%;
                        border-collapse: collapse;
                        margin-bottom: 40px;
                    }}
                    .items-table th {{
                        background: #0066cc;
                        color: white;
                        padding: 12px;
                        text-align: left;
                        font-weight: 600;
                    }}
                    .items-table th:last-child {{
                        text-align: right;
                    }}
                    .totals-section {{
                        display: flex;
                        justify-content: flex-end;
                        margin-bottom: 40px;
                    }}
                    .totals-box {{
                        width: 300px;
                    }}
                    .total-row {{
                        display: flex;
                        justify-content: space-between;
                        padding: 8px 0;
                        border-bottom: 1px solid #eee;
                    }}
                    .total-row.final {{
                        border-bottom: none;
                        border-top: 2px solid #0066cc;
                        margin-top: 10px;
                        padding-top: 15px;
                        font-size: 20px;
                        font-weight: bold;
                        color: #0066cc;
                    }}
                    .payment-terms {{
                        background: #f8f9fa;
                        padding: 20px;
                        border-radius: 8px;
                        margin-bottom: 30px;
                    }}
                    .payment-terms h3 {{
                        margin: 0 0 10px 0;
                        color: #0066cc;
                    }}
                    .footer-note {{
                        text-align: center;
                        color: #666;
                        font-size: 14px;
                        margin-top: 40px;
                        padding-top: 20px;
                        border-top: 1px solid #eee;
                    }}
                </style>
            </head>
            <body>
                <div class='invoice-container'>
                    <div class='invoice-header'>
                        <div class='company-details'>
                            <h1>{invoice.CompanyName}</h1>
                            <p>{invoice.CompanyAddress}<br>
                            {invoice.CompanyCity}, {invoice.CompanyState} {invoice.CompanyZip}<br>
                            Phone: {invoice.CompanyPhone}<br>
                            Email: {invoice.CompanyEmail}</p>
                        </div>
                        <div class='invoice-details'>
                            <h2>INVOICE</h2>
                            <p class='invoice-number'>#{invoice.Number}</p>
                            <p><strong>Date:</strong> {invoice.Date:MMMM dd, yyyy}<br>
                            <strong>Due Date:</strong> {invoice.DueDate:MMMM dd, yyyy}</p>
                        </div>
                    </div>

                    <div class='billing-section'>
                        <div class='billing-box'>
                            <h3>Bill To</h3>
                            <p><strong>{invoice.CustomerName}</strong><br>
                            {invoice.CustomerAddress}<br>
                            {invoice.CustomerCity}, {invoice.CustomerState} {invoice.CustomerZip}<br>
                            {invoice.CustomerEmail}</p>
                        </div>
                        <div class='billing-box'>
                            <h3>Payment Information</h3>
                            <p><strong>Payment Terms:</strong> {invoice.PaymentTerms}<br>
                            <strong>Invoice Status:</strong> <span style='color: #ff6b6b;'>Unpaid</span><br>
                            <strong>Amount Due:</strong> ${invoice.Total:F2}</p>
                        </div>
                    </div>

                    <table class='items-table'>
                        <thead>
                            <tr>
                                <th>Description</th>
                                <th style='text-align: center;'>Quantity</th>
                                <th style='text-align: right;'>Unit Price</th>
                                <th style='text-align: right;'>Total</th>
                            </tr>
                        </thead>
                        <tbody>
                            {itemsHtml}
                        </tbody>
                    </table>

                    <div class='totals-section'>
                        <div class='totals-box'>
                            <div class='total-row'>
                                <span>Subtotal:</span>
                                <span>${invoice.Subtotal:F2}</span>
                            </div>
                            <div class='total-row'>
                                <span>Tax ({invoice.TaxRate:F0}%):</span>
                                <span>${invoice.Tax:F2}</span>
                            </div>
                            <div class='total-row final'>
                                <span>Total Due:</span>
                                <span>${invoice.Total:F2}</span>
                            </div>
                        </div>
                    </div>

                    <div class='payment-terms'>
                        <h3>Payment Terms & Conditions</h3>
                        <p>Payment is due within {invoice.PaymentTerms}. Late payments are subject to a 1.5% monthly service charge. 
                        Please make checks payable to {invoice.CompanyName} or pay online at {invoice.CompanyWebsite}.</p>
                    </div>

                    <div class='footer-note'>
                        <p>Thank you for your business! This invoice was generated automatically using our C# PDF generation system.</p>
                        <p>Questions? Contact us at {invoice.CompanyEmail} or {invoice.CompanyPhone}</p>
                    </div>
                </div>
            </body>
            </html>";
    }
}

// Invoice model classes
public class Invoice
{
    public string Number { get; set; }
    public DateTime Date { get; set; }
    public DateTime DueDate { get; set; }
    public string CompanyName { get; set; }
    public string CompanyAddress { get; set; }
    public string CompanyCity { get; set; }
    public string CompanyState { get; set; }
    public string CompanyZip { get; set; }
    public string CompanyPhone { get; set; }
    public string CompanyEmail { get; set; }
    public string CompanyWebsite { get; set; }
    public string CustomerName { get; set; }
    public string CustomerAddress { get; set; }
    public string CustomerCity { get; set; }
    public string CustomerState { get; set; }
    public string CustomerZip { get; set; }
    public string CustomerEmail { get; set; }
    public string PaymentTerms { get; set; }
    public List<InvoiceItem> Items { get; set; }
    public decimal Subtotal => Items.Sum(i => i.Total);
    public decimal TaxRate { get; set; }
    public decimal Tax => Subtotal * (TaxRate / 100);
    public decimal Total => Subtotal + Tax;
}

public class InvoiceItem
{
    public string Description { get; set; }
    public int Quantity { get; set; }
    public decimal UnitPrice { get; set; }
    public decimal Total => Quantity * UnitPrice;
}

// Usage example
var generator = new InvoiceGenerator();
var invoice = new Invoice
{
    Number = "INV-2024-001",
    Date = DateTime.Now,
    DueDate = DateTime.Now.AddDays(30),
    CompanyName = "Your Company Name",
    CompanyAddress = "123 Business Street",
    CompanyCity = "New York",
    CompanyState = "NY",
    CompanyZip = "10001",
    CompanyPhone = "(555) 123-4567",
    CompanyEmail = "billing@yourcompany.com",
    CompanyWebsite = "www.yourcompany.com",
    CustomerName = "Acme Corporation",
    CustomerAddress = "456 Client Avenue",
    CustomerCity = "Los Angeles",
    CustomerState = "CA",
    CustomerZip = "90001",
    CustomerEmail = "accounts@acmecorp.com",
    PaymentTerms = "Net 30",
    TaxRate = 8.5m,
    Items = new List<InvoiceItem>
    {
        new() { Description = "Professional Services - March 2024", Quantity = 40, UnitPrice = 125.00m },
        new() { Description = "Software License (Annual)", Quantity = 1, UnitPrice = 2400.00m },
        new() { Description = "Technical Support", Quantity = 10, UnitPrice = 150.00m }
    }
};

generator.CreateInvoice(invoice);
using IronPdf;
using System;
using System.Collections.Generic;
using System.Globalization;
using System.Linq;

public class InvoiceGenerator
{
    private readonly ChromePdfRenderer _renderer;

    public InvoiceGenerator()
    {
        _renderer = new ChromePdfRenderer();
        ConfigureRenderer();
    }

    private void ConfigureRenderer()
    {
        // Professional page setup
        _renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
        _renderer.RenderingOptions.MarginTop = 25;
        _renderer.RenderingOptions.MarginBottom = 25;
        _renderer.RenderingOptions.MarginLeft = 25;
        _renderer.RenderingOptions.MarginRight = 25;
        _renderer.RenderingOptions.PrintHtmlBackgrounds = true;

        // Add footer with page numbers
        _renderer.RenderingOptions.TextFooter = new TextHeaderFooter
        {
            Text = "Page {page} of {total-pages} | Invoice generated on {date}",
            FontSize = 9,
            Font = "Arial",
            CenterText = true
        };
    }

    public void CreateInvoice(Invoice invoice)
    {
        var html = GenerateInvoiceHtml(invoice);
        var pdf = _renderer.RenderHtmlAsPdf(html);

        // Add metadata to the final document
        pdf.MetaData.Title = $"Invoice {invoice.Number}";
        pdf.MetaData.Author = "Your Company Name";
        pdf.MetaData.Subject = $"Invoice for {invoice.CustomerName}";
        pdf.MetaData.Keywords = "invoice, billing, payment";
        pdf.MetaData.CreationDate = DateTime.Now;

        // Save the PDF document
        var fileName = $"Invoice-{invoice.Number}.pdf";
        pdf.SaveAs(fileName);

        Console.WriteLine($"PDF generated successfully: {fileName}");
    }

    private string GenerateInvoiceHtml(Invoice invoice)
    {
        var itemsHtml = string.Join("", invoice.Items.Select(item => $@"
            <tr>
                <td style='padding: 12px; border-bottom: 1px solid #eee;'>{item.Description}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: center;'>{item.Quantity}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.UnitPrice:F2}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.Total:F2}</td>
            </tr>"));

        return $@"
            <html>
            <head>
                <style>
                    * {{ box-sizing: border-box; }}
                    body {{ 
                        font-family: 'Segoe UI', Arial, sans-serif; 
                        line-height: 1.6;
                        color: #333;
                        margin: 0;
                        padding: 0;
                    }}
                    .invoice-container {{
                        max-width: 800px;
                        margin: 0 auto;
                        padding: 40px;
                    }}
                    .invoice-header {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                        padding-bottom: 20px;
                        border-bottom: 3px solid #0066cc;
                    }}
                    .company-details {{
                        flex: 1;
                    }}
                    .company-details h1 {{
                        color: #0066cc;
                        margin: 0 0 10px 0;
                        font-size: 28px;
                    }}
                    .invoice-details {{
                        flex: 1;
                        text-align: right;
                    }}
                    .invoice-details h2 {{
                        margin: 0 0 10px 0;
                        color: #666;
                        font-size: 24px;
                    }}
                    .invoice-number {{
                        font-size: 18px;
                        color: #0066cc;
                        font-weight: bold;
                    }}
                    .billing-section {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                    }}
                    .billing-box {{
                        flex: 1;
                        padding: 20px;
                        background: #f8f9fa;
                        border-radius: 8px;
                        margin-right: 20px;
                    }}
                    .billing-box:last-child {{
                        margin-right: 0;
                    }}
                    .billing-box h3 {{
                        margin: 0 0 15px 0;
                        color: #0066cc;
                        font-size: 16px;
                        text-transform: uppercase;
                        letter-spacing: 1px;
                    }}
                    .items-table {{
                        width: 100%;
                        border-collapse: collapse;
                        margin-bottom: 40px;
                    }}
                    .items-table th {{
                        background: #0066cc;
                        color: white;
                        padding: 12px;
                        text-align: left;
                        font-weight: 600;
                    }}
                    .items-table th:last-child {{
                        text-align: right;
                    }}
                    .totals-section {{
                        display: flex;
                        justify-content: flex-end;
                        margin-bottom: 40px;
                    }}
                    .totals-box {{
                        width: 300px;
                    }}
                    .total-row {{
                        display: flex;
                        justify-content: space-between;
                        padding: 8px 0;
                        border-bottom: 1px solid #eee;
                    }}
                    .total-row.final {{
                        border-bottom: none;
                        border-top: 2px solid #0066cc;
                        margin-top: 10px;
                        padding-top: 15px;
                        font-size: 20px;
                        font-weight: bold;
                        color: #0066cc;
                    }}
                    .payment-terms {{
                        background: #f8f9fa;
                        padding: 20px;
                        border-radius: 8px;
                        margin-bottom: 30px;
                    }}
                    .payment-terms h3 {{
                        margin: 0 0 10px 0;
                        color: #0066cc;
                    }}
                    .footer-note {{
                        text-align: center;
                        color: #666;
                        font-size: 14px;
                        margin-top: 40px;
                        padding-top: 20px;
                        border-top: 1px solid #eee;
                    }}
                </style>
            </head>
            <body>
                <div class='invoice-container'>
                    <div class='invoice-header'>
                        <div class='company-details'>
                            <h1>{invoice.CompanyName}</h1>
                            <p>{invoice.CompanyAddress}<br>
                            {invoice.CompanyCity}, {invoice.CompanyState} {invoice.CompanyZip}<br>
                            Phone: {invoice.CompanyPhone}<br>
                            Email: {invoice.CompanyEmail}</p>
                        </div>
                        <div class='invoice-details'>
                            <h2>INVOICE</h2>
                            <p class='invoice-number'>#{invoice.Number}</p>
                            <p><strong>Date:</strong> {invoice.Date:MMMM dd, yyyy}<br>
                            <strong>Due Date:</strong> {invoice.DueDate:MMMM dd, yyyy}</p>
                        </div>
                    </div>

                    <div class='billing-section'>
                        <div class='billing-box'>
                            <h3>Bill To</h3>
                            <p><strong>{invoice.CustomerName}</strong><br>
                            {invoice.CustomerAddress}<br>
                            {invoice.CustomerCity}, {invoice.CustomerState} {invoice.CustomerZip}<br>
                            {invoice.CustomerEmail}</p>
                        </div>
                        <div class='billing-box'>
                            <h3>Payment Information</h3>
                            <p><strong>Payment Terms:</strong> {invoice.PaymentTerms}<br>
                            <strong>Invoice Status:</strong> <span style='color: #ff6b6b;'>Unpaid</span><br>
                            <strong>Amount Due:</strong> ${invoice.Total:F2}</p>
                        </div>
                    </div>

                    <table class='items-table'>
                        <thead>
                            <tr>
                                <th>Description</th>
                                <th style='text-align: center;'>Quantity</th>
                                <th style='text-align: right;'>Unit Price</th>
                                <th style='text-align: right;'>Total</th>
                            </tr>
                        </thead>
                        <tbody>
                            {itemsHtml}
                        </tbody>
                    </table>

                    <div class='totals-section'>
                        <div class='totals-box'>
                            <div class='total-row'>
                                <span>Subtotal:</span>
                                <span>${invoice.Subtotal:F2}</span>
                            </div>
                            <div class='total-row'>
                                <span>Tax ({invoice.TaxRate:F0}%):</span>
                                <span>${invoice.Tax:F2}</span>
                            </div>
                            <div class='total-row final'>
                                <span>Total Due:</span>
                                <span>${invoice.Total:F2}</span>
                            </div>
                        </div>
                    </div>

                    <div class='payment-terms'>
                        <h3>Payment Terms & Conditions</h3>
                        <p>Payment is due within {invoice.PaymentTerms}. Late payments are subject to a 1.5% monthly service charge. 
                        Please make checks payable to {invoice.CompanyName} or pay online at {invoice.CompanyWebsite}.</p>
                    </div>

                    <div class='footer-note'>
                        <p>Thank you for your business! This invoice was generated automatically using our C# PDF generation system.</p>
                        <p>Questions? Contact us at {invoice.CompanyEmail} or {invoice.CompanyPhone}</p>
                    </div>
                </div>
            </body>
            </html>";
    }
}

// Invoice model classes
public class Invoice
{
    public string Number { get; set; }
    public DateTime Date { get; set; }
    public DateTime DueDate { get; set; }
    public string CompanyName { get; set; }
    public string CompanyAddress { get; set; }
    public string CompanyCity { get; set; }
    public string CompanyState { get; set; }
    public string CompanyZip { get; set; }
    public string CompanyPhone { get; set; }
    public string CompanyEmail { get; set; }
    public string CompanyWebsite { get; set; }
    public string CustomerName { get; set; }
    public string CustomerAddress { get; set; }
    public string CustomerCity { get; set; }
    public string CustomerState { get; set; }
    public string CustomerZip { get; set; }
    public string CustomerEmail { get; set; }
    public string PaymentTerms { get; set; }
    public List<InvoiceItem> Items { get; set; }
    public decimal Subtotal => Items.Sum(i => i.Total);
    public decimal TaxRate { get; set; }
    public decimal Tax => Subtotal * (TaxRate / 100);
    public decimal Total => Subtotal + Tax;
}

public class InvoiceItem
{
    public string Description { get; set; }
    public int Quantity { get; set; }
    public decimal UnitPrice { get; set; }
    public decimal Total => Quantity * UnitPrice;
}

// Usage example
var generator = new InvoiceGenerator();
var invoice = new Invoice
{
    Number = "INV-2024-001",
    Date = DateTime.Now,
    DueDate = DateTime.Now.AddDays(30),
    CompanyName = "Your Company Name",
    CompanyAddress = "123 Business Street",
    CompanyCity = "New York",
    CompanyState = "NY",
    CompanyZip = "10001",
    CompanyPhone = "(555) 123-4567",
    CompanyEmail = "billing@yourcompany.com",
    CompanyWebsite = "www.yourcompany.com",
    CustomerName = "Acme Corporation",
    CustomerAddress = "456 Client Avenue",
    CustomerCity = "Los Angeles",
    CustomerState = "CA",
    CustomerZip = "90001",
    CustomerEmail = "accounts@acmecorp.com",
    PaymentTerms = "Net 30",
    TaxRate = 8.5m,
    Items = new List<InvoiceItem>
    {
        new() { Description = "Professional Services - March 2024", Quantity = 40, UnitPrice = 125.00m },
        new() { Description = "Software License (Annual)", Quantity = 1, UnitPrice = 2400.00m },
        new() { Description = "Technical Support", Quantity = 10, UnitPrice = 150.00m }
    }
};

generator.CreateInvoice(invoice);
Imports IronPdf
Imports System
Imports System.Collections.Generic
Imports System.Globalization
Imports System.Linq

Public Class InvoiceGenerator
	Private ReadOnly _renderer As ChromePdfRenderer

	Public Sub New()
		_renderer = New ChromePdfRenderer()
		ConfigureRenderer()
	End Sub

	Private Sub ConfigureRenderer()
		' Professional page setup
		_renderer.RenderingOptions.PaperSize = PdfPaperSize.A4
		_renderer.RenderingOptions.MarginTop = 25
		_renderer.RenderingOptions.MarginBottom = 25
		_renderer.RenderingOptions.MarginLeft = 25
		_renderer.RenderingOptions.MarginRight = 25
		_renderer.RenderingOptions.PrintHtmlBackgrounds = True

		' Add footer with page numbers
		_renderer.RenderingOptions.TextFooter = New TextHeaderFooter With {
			.Text = "Page {page} of {total-pages} | Invoice generated on {date}",
			.FontSize = 9,
			.Font = "Arial",
			.CenterText = True
		}
	End Sub

	Public Sub CreateInvoice(ByVal invoice As Invoice)
		Dim html = GenerateInvoiceHtml(invoice)
		Dim pdf = _renderer.RenderHtmlAsPdf(html)

		' Add metadata to the final document
		pdf.MetaData.Title = $"Invoice {invoice.Number}"
		pdf.MetaData.Author = "Your Company Name"
		pdf.MetaData.Subject = $"Invoice for {invoice.CustomerName}"
		pdf.MetaData.Keywords = "invoice, billing, payment"
		pdf.MetaData.CreationDate = DateTime.Now

		' Save the PDF document
		Dim fileName = $"Invoice-{invoice.Number}.pdf"
		pdf.SaveAs(fileName)

		Console.WriteLine($"PDF generated successfully: {fileName}")
	End Sub

	Private Function GenerateInvoiceHtml(ByVal invoice As Invoice) As String
		Dim itemsHtml = String.Join("", invoice.Items.Select(Function(item) $"
            <tr>
                <td style='padding: 12px; border-bottom: 1px solid #eee;'>{item.Description}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: center;'>{item.Quantity}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.UnitPrice:F2}</td>
                <td style='padding: 12px; border-bottom: 1px solid #eee; text-align: right;'>${item.Total:F2}</td>
            </tr>"))

		Return $"
            <html>
            <head>
                <style>
                    * {{ box-sizing: border-box; }}
                    body {{ 
                        font-family: 'Segoe UI', Arial, sans-serif; 
                        line-height: 1.6;
                        color: #333;
                        margin: 0;
                        padding: 0;
                    }}
                    .invoice-container {{
                        max-width: 800px;
                        margin: 0 auto;
                        padding: 40px;
                    }}
                    .invoice-header {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                        padding-bottom: 20px;
                        border-bottom: 3px solid #0066cc;
                    }}
                    .company-details {{
                        flex: 1;
                    }}
                    .company-details h1 {{
                        color: #0066cc;
                        margin: 0 0 10px 0;
                        font-size: 28px;
                    }}
                    .invoice-details {{
                        flex: 1;
                        text-align: right;
                    }}
                    .invoice-details h2 {{
                        margin: 0 0 10px 0;
                        color: #666;
                        font-size: 24px;
                    }}
                    .invoice-number {{
                        font-size: 18px;
                        color: #0066cc;
                        font-weight: bold;
                    }}
                    .billing-section {{
                        display: flex;
                        justify-content: space-between;
                        margin-bottom: 40px;
                    }}
                    .billing-box {{
                        flex: 1;
                        padding: 20px;
                        background: #f8f9fa;
                        border-radius: 8px;
                        margin-right: 20px;
                    }}
                    .billing-box:last-child {{
                        margin-right: 0;
                    }}
                    .billing-box h3 {{
                        margin: 0 0 15px 0;
                        color: #0066cc;
                        font-size: 16px;
                        text-transform: uppercase;
                        letter-spacing: 1px;
                    }}
                    .items-table {{
                        width: 100%;
                        border-collapse: collapse;
                        margin-bottom: 40px;
                    }}
                    .items-table th {{
                        background: #0066cc;
                        color: white;
                        padding: 12px;
                        text-align: left;
                        font-weight: 600;
                    }}
                    .items-table th:last-child {{
                        text-align: right;
                    }}
                    .totals-section {{
                        display: flex;
                        justify-content: flex-end;
                        margin-bottom: 40px;
                    }}
                    .totals-box {{
                        width: 300px;
                    }}
                    .total-row {{
                        display: flex;
                        justify-content: space-between;
                        padding: 8px 0;
                        border-bottom: 1px solid #eee;
                    }}
                    .total-row.final {{
                        border-bottom: none;
                        border-top: 2px solid #0066cc;
                        margin-top: 10px;
                        padding-top: 15px;
                        font-size: 20px;
                        font-weight: bold;
                        color: #0066cc;
                    }}
                    .payment-terms {{
                        background: #f8f9fa;
                        padding: 20px;
                        border-radius: 8px;
                        margin-bottom: 30px;
                    }}
                    .payment-terms h3 {{
                        margin: 0 0 10px 0;
                        color: #0066cc;
                    }}
                    .footer-note {{
                        text-align: center;
                        color: #666;
                        font-size: 14px;
                        margin-top: 40px;
                        padding-top: 20px;
                        border-top: 1px solid #eee;
                    }}
                </style>
            </head>
            <body>
                <div class='invoice-container'>
                    <div class='invoice-header'>
                        <div class='company-details'>
                            <h1>{invoice.CompanyName}</h1>
                            <p>{invoice.CompanyAddress}<br>
                            {invoice.CompanyCity}, {invoice.CompanyState} {invoice.CompanyZip}<br>
                            Phone: {invoice.CompanyPhone}<br>
                            Email: {invoice.CompanyEmail}</p>
                        </div>
                        <div class='invoice-details'>
                            <h2>INVOICE</h2>
                            <p class='invoice-number'>#{invoice.Number}</p>
                            <p><strong>Date:</strong> {invoice.Date:=MMMM dd, yyyy}<br>
                            <strong>Due Date:</strong> {invoice.DueDate:=MMMM dd, yyyy}</p>
                        </div>
                    </div>

                    <div class='billing-section'>
                        <div class='billing-box'>
                            <h3>Bill To</h3>
                            <p><strong>{invoice.CustomerName}</strong><br>
                            {invoice.CustomerAddress}<br>
                            {invoice.CustomerCity}, {invoice.CustomerState} {invoice.CustomerZip}<br>
                            {invoice.CustomerEmail}</p>
                        </div>
                        <div class='billing-box'>
                            <h3>Payment Information</h3>
                            <p><strong>Payment Terms:</strong> {invoice.PaymentTerms}<br>
                            <strong>Invoice Status:</strong> <span style='color: #ff6b6b;'>Unpaid</span><br>
                            <strong>Amount Due:</strong> ${invoice.Total:F2}</p>
                        </div>
                    </div>

                    <table class='items-table'>
                        <thead>
                            <tr>
                                <th>Description</th>
                                <th style='text-align: center;'>Quantity</th>
                                <th style='text-align: right;'>Unit Price</th>
                                <th style='text-align: right;'>Total</th>
                            </tr>
                        </thead>
                        <tbody>
                            {itemsHtml}
                        </tbody>
                    </table>

                    <div class='totals-section'>
                        <div class='totals-box'>
                            <div class='total-row'>
                                <span>Subtotal:</span>
                                <span>${invoice.Subtotal:F2}</span>
                            </div>
                            <div class='total-row'>
                                <span>Tax ({invoice.TaxRate:F0}%):</span>
                                <span>${invoice.Tax:F2}</span>
                            </div>
                            <div class='total-row final'>
                                <span>Total Due:</span>
                                <span>${invoice.Total:F2}</span>
                            </div>
                        </div>
                    </div>

                    <div class='payment-terms'>
                        <h3>Payment Terms & Conditions</h3>
                        <p>Payment is due within {invoice.PaymentTerms}. Late payments are subject to a 1.5% monthly service charge. 
                        Please make checks payable to {invoice.CompanyName} or pay online at {invoice.CompanyWebsite}.</p>
                    </div>

                    <div class='footer-note'>
                        <p>Thank you for your business! This invoice was generated automatically using our C# PDF generation system.</p>
                        <p>Questions? Contact us at {invoice.CompanyEmail} or {invoice.CompanyPhone}</p>
                    </div>
                </div>
            </body>
            </html>"
	End Function
End Class

' Invoice model classes
Public Class Invoice
	Public Property Number() As String
	Public Property [Date]() As DateTime
	Public Property DueDate() As DateTime
	Public Property CompanyName() As String
	Public Property CompanyAddress() As String
	Public Property CompanyCity() As String
	Public Property CompanyState() As String
	Public Property CompanyZip() As String
	Public Property CompanyPhone() As String
	Public Property CompanyEmail() As String
	Public Property CompanyWebsite() As String
	Public Property CustomerName() As String
	Public Property CustomerAddress() As String
	Public Property CustomerCity() As String
	Public Property CustomerState() As String
	Public Property CustomerZip() As String
	Public Property CustomerEmail() As String
	Public Property PaymentTerms() As String
	Public Property Items() As List(Of InvoiceItem)
	Public ReadOnly Property Subtotal() As Decimal
		Get
			Return Items.Sum(Function(i) i.Total)
		End Get
	End Property
	Public Property TaxRate() As Decimal
	Public ReadOnly Property Tax() As Decimal
		Get
			Return Subtotal * (TaxRate / 100)
		End Get
	End Property
	Public ReadOnly Property Total() As Decimal
		Get
			Return Subtotal + Tax
		End Get
	End Property
End Class

Public Class InvoiceItem
	Public Property Description() As String
	Public Property Quantity() As Integer
	Public Property UnitPrice() As Decimal
	Public ReadOnly Property Total() As Decimal
		Get
			Return Quantity * UnitPrice
		End Get
	End Property
End Class

' Usage example
Private generator = New InvoiceGenerator()
Private invoice = New Invoice With {
	.Number = "INV-2024-001",
	.Date = DateTime.Now,
	.DueDate = DateTime.Now.AddDays(30),
	.CompanyName = "Your Company Name",
	.CompanyAddress = "123 Business Street",
	.CompanyCity = "New York",
	.CompanyState = "NY",
	.CompanyZip = "10001",
	.CompanyPhone = "(555) 123-4567",
	.CompanyEmail = "billing@yourcompany.com",
	.CompanyWebsite = "www.yourcompany.com",
	.CustomerName = "Acme Corporation",
	.CustomerAddress = "456 Client Avenue",
	.CustomerCity = "Los Angeles",
	.CustomerState = "CA",
	.CustomerZip = "90001",
	.CustomerEmail = "accounts@acmecorp.com",
	.PaymentTerms = "Net 30",
	.TaxRate = 8.5D,
	.Items = New List(Of InvoiceItem) From {
		New() {
			Description = "Professional Services - March 2024",
			Quantity = 40,
			UnitPrice = 125.00D
		},
		New() {
			Description = "Software License (Annual)",
			Quantity = 1,
			UnitPrice = 2400.00D
		},
		New() {
			Description = "Technical Support",
			Quantity = 10,
			UnitPrice = 150.00D
		}
	}
}

generator.CreateInvoice(invoice)
$vbLabelText   $csharpLabel

IronPDF Hangi Gelişmiş PDF Özelliklerini Sunar?

IronPDF, C#'da temel PDF oluşturmanın ötesine geçerek, karmaşık belge iş akışlarını ve kurumsal düzeyde işlevselliği mümkün kılan sofistike özellikler sunar. Bu gelişmiş yetenekler, .NET'te PDF oluşturduğunuzda etkileşimli formlar yaratmanıza, hassas belgeleri güvence altına almanıza ve mevcut PDF'leri hassas bir şekilde değiştirmenize olanak tanır. Bu özellikler, dünya çapında 14 milyondan fazla geliştiricinin görev kritik PDF üretim ihtiyaçları için IronPDF'ye güvenmesinin nedenidir. Bu özellikleri anlamak, en zorlu gereksinimleri karşılayan kapsamlı PDF çözümleri oluşturmanıza yardımcı olur - doldurulabilir formlar yaratmaktan C# ile PDF oluşturduğunuz projelerinizde kurumsal düzeyde güvenlik uygulanmasına kadar.

Etkileşimli PDF Formları Oluşturma

Doldurulabilir PDF formlarını programlı olarak oluşturmak, veri toplama ve belge iş akışlarını otomatikleştirme imkanları sunar. IronPDF, HTML formlarını PDF okuyucusunda kullanıcılar tarafından doldurulabilir etkileşimli PDF formlarına dönüştürebilir:

// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

var renderer = new ChromePdfRenderer();

// Enable form creation from HTML
renderer.RenderingOptions.CreatePdfFormsFromHtml = true;

// Create an interactive form with various input types
var formHtml = @"
    <html>
    <head>
        <style>
            body { font-family: Arial, sans-serif; padding: 40px; }
            .form-group { margin-bottom: 20px; }
            label { display: block; margin-bottom: 5px; font-weight: bold; }
            input[type='text'], input[type='email'], select, textarea {
                width: 100%;
                padding: 8px;
                border: 1px solid #ccc;
                border-radius: 4px;
                font-size: 14px;
            }
            .checkbox-group { margin: 10px 0; }
            .submit-section { 
                margin-top: 30px; 
                padding-top: 20px; 
                border-top: 2px solid #0066cc; 
            }
        </style>
    </head>
    <body>
        # Application Form
        <form>
            <div class='form-group'>
                <label for='fullName'>Full Name:</label>
                <input type='text' id='fullName' name='fullName' required />
            </div>

            <div class='form-group'>
                <label for='email'>Email Address:</label>
                <input type='email' id='email' name='email' required />
            </div>

            <div class='form-group'>
                <label for='department'>Department:</label>
                <select id='department' name='department'>
                    <option value=''>Select Department</option>
                    <option value='sales'>Sales</option>
                    <option value='marketing'>Marketing</option>
                    <option value='engineering'>Engineering</option>
                    <option value='hr'>Human Resources</option>
                </select>
            </div>

            <div class='form-group'>
                <label>Interests:</label>
                <div class='checkbox-group'>
                    <label><input type='checkbox' name='interests' value='training' /> Professional Training</label>
                    <label><input type='checkbox' name='interests' value='conferences' /> Industry Conferences</label>
                    <label><input type='checkbox' name='interests' value='certification' /> Certification Programs</label>
                </div>
            </div>

            <div class='form-group'>
                <label for='comments'>Additional Comments:</label>
                <textarea id='comments' name='comments' rows='4'></textarea>
            </div>

            <div class='submit-section'>
                <p><em>Please save this form and email to hr@company.com</em></p>
            </div>
        </form>
    </body>
    </html>";

// Create the PDF with form fields
var formPdf = renderer.RenderHtmlAsPdf(formHtml);

// Optionally pre-fill form fields programmatically
formPdf.Form.FindFormField("fullName").Value = "John Smith";
formPdf.Form.FindFormField("email").Value = "john.smith@example.com";
formPdf.Form.FindFormField("department").Value = "engineering";

// Save the interactive form
formPdf.SaveAs("application-form.pdf");

// You can also read and process submitted forms
var submittedPdf = PdfDocument.FromFile("submitted-form.pdf");
var name = submittedPdf.Form.FindFormField("fullName").Value;
var email = submittedPdf.Form.FindFormField("email").Value;
Console.WriteLine($"Form submitted by: {name} ({email})");
// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

var renderer = new ChromePdfRenderer();

// Enable form creation from HTML
renderer.RenderingOptions.CreatePdfFormsFromHtml = true;

// Create an interactive form with various input types
var formHtml = @"
    <html>
    <head>
        <style>
            body { font-family: Arial, sans-serif; padding: 40px; }
            .form-group { margin-bottom: 20px; }
            label { display: block; margin-bottom: 5px; font-weight: bold; }
            input[type='text'], input[type='email'], select, textarea {
                width: 100%;
                padding: 8px;
                border: 1px solid #ccc;
                border-radius: 4px;
                font-size: 14px;
            }
            .checkbox-group { margin: 10px 0; }
            .submit-section { 
                margin-top: 30px; 
                padding-top: 20px; 
                border-top: 2px solid #0066cc; 
            }
        </style>
    </head>
    <body>
        # Application Form
        <form>
            <div class='form-group'>
                <label for='fullName'>Full Name:</label>
                <input type='text' id='fullName' name='fullName' required />
            </div>

            <div class='form-group'>
                <label for='email'>Email Address:</label>
                <input type='email' id='email' name='email' required />
            </div>

            <div class='form-group'>
                <label for='department'>Department:</label>
                <select id='department' name='department'>
                    <option value=''>Select Department</option>
                    <option value='sales'>Sales</option>
                    <option value='marketing'>Marketing</option>
                    <option value='engineering'>Engineering</option>
                    <option value='hr'>Human Resources</option>
                </select>
            </div>

            <div class='form-group'>
                <label>Interests:</label>
                <div class='checkbox-group'>
                    <label><input type='checkbox' name='interests' value='training' /> Professional Training</label>
                    <label><input type='checkbox' name='interests' value='conferences' /> Industry Conferences</label>
                    <label><input type='checkbox' name='interests' value='certification' /> Certification Programs</label>
                </div>
            </div>

            <div class='form-group'>
                <label for='comments'>Additional Comments:</label>
                <textarea id='comments' name='comments' rows='4'></textarea>
            </div>

            <div class='submit-section'>
                <p><em>Please save this form and email to hr@company.com</em></p>
            </div>
        </form>
    </body>
    </html>";

// Create the PDF with form fields
var formPdf = renderer.RenderHtmlAsPdf(formHtml);

// Optionally pre-fill form fields programmatically
formPdf.Form.FindFormField("fullName").Value = "John Smith";
formPdf.Form.FindFormField("email").Value = "john.smith@example.com";
formPdf.Form.FindFormField("department").Value = "engineering";

// Save the interactive form
formPdf.SaveAs("application-form.pdf");

// You can also read and process submitted forms
var submittedPdf = PdfDocument.FromFile("submitted-form.pdf");
var name = submittedPdf.Form.FindFormField("fullName").Value;
var email = submittedPdf.Form.FindFormField("email").Value;
Console.WriteLine($"Form submitted by: {name} ({email})");
Imports IronPdf
Imports System

Dim renderer As New ChromePdfRenderer()

' Enable form creation from HTML
renderer.RenderingOptions.CreatePdfFormsFromHtml = True

' Create an interactive form with various input types
Dim formHtml As String = "
    <html>
    <head>
        <style>
            body { font-family: Arial, sans-serif; padding: 40px; }
            .form-group { margin-bottom: 20px; }
            label { display: block; margin-bottom: 5px; font-weight: bold; }
            input[type='text'], input[type='email'], select, textarea {
                width: 100%;
                padding: 8px;
                border: 1px solid #ccc;
                border-radius: 4px;
                font-size: 14px;
            }
            .checkbox-group { margin: 10px 0; }
            .submit-section { 
                margin-top: 30px; 
                padding-top: 20px; 
                border-top: 2px solid #0066cc; 
            }
        </style>
    </head>
    <body>
        # Application Form
        <form>
            <div class='form-group'>
                <label for='fullName'>Full Name:</label>
                <input type='text' id='fullName' name='fullName' required />
            </div>

            <div class='form-group'>
                <label for='email'>Email Address:</label>
                <input type='email' id='email' name='email' required />
            </div>

            <div class='form-group'>
                <label for='department'>Department:</label>
                <select id='department' name='department'>
                    <option value=''>Select Department</option>
                    <option value='sales'>Sales</option>
                    <option value='marketing'>Marketing</option>
                    <option value='engineering'>Engineering</option>
                    <option value='hr'>Human Resources</option>
                </select>
            </div>

            <div class='form-group'>
                <label>Interests:</label>
                <div class='checkbox-group'>
                    <label><input type='checkbox' name='interests' value='training' /> Professional Training</label>
                    <label><input type='checkbox' name='interests' value='conferences' /> Industry Conferences</label>
                    <label><input type='checkbox' name='interests' value='certification' /> Certification Programs</label>
                </div>
            </div>

            <div class='form-group'>
                <label for='comments'>Additional Comments:</label>
                <textarea id='comments' name='comments' rows='4'></textarea>
            </div>

            <div class='submit-section'>
                <p><em>Please save this form and email to hr@company.com</em></p>
            </div>
        </form>
    </body>
    </html>"

' Create the PDF with form fields
Dim formPdf = renderer.RenderHtmlAsPdf(formHtml)

' Optionally pre-fill form fields programmatically
formPdf.Form.FindFormField("fullName").Value = "John Smith"
formPdf.Form.FindFormField("email").Value = "john.smith@example.com"
formPdf.Form.FindFormField("department").Value = "engineering"

' Save the interactive form
formPdf.SaveAs("application-form.pdf")

' You can also read and process submitted forms
Dim submittedPdf = PdfDocument.FromFile("submitted-form.pdf")
Dim name = submittedPdf.Form.FindFormField("fullName").Value
Dim email = submittedPdf.Form.FindFormField("email").Value
Console.WriteLine($"Form submitted by: {name} ({email})")
$vbLabelText   $csharpLabel

Üretilmiş PDF'lerinizi Güvence Altına Alın

Güvenlik, hassas belgelerle uğraşırken en önemli unsurdur. IronPDF, PDF'lerinizi yetkisiz erişim veya değişiklikten korumak için kapsamlı güvenlik özellikleri sunar:

// Namespace: IronPdf
using IronPdf;
// Namespace: IronPdf.Editing
using IronPdf.Editing;

var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf("<h1>Confidential Document</h1><p>Sensitive information...</p>");

// Apply password protection
pdf.SecuritySettings.UserPassword = "user123";      // Required to open
pdf.SecuritySettings.OwnerPassword = "owner456";    // Required to modify

// Set detailed permissions
pdf.SecuritySettings.AllowUserCopyPasteContent = false;
pdf.SecuritySettings.AllowUserAnnotations = false;
pdf.SecuritySettings.AllowUserFormData = true;
pdf.SecuritySettings.AllowUserPrinting = PrintPermissions.LowQualityPrint;

// Add digital signature for authenticity
pdf.SignWithFile(
    certificatePath: "certificate.pfx",
    certificatePassword: "certpass123",
    signingReason: "Document Approval",
    signingLocation: "New York, NY",
    signatureImage: new Signature("signature.png")
    {
        Width = 150,
        Height = 50
    }
);

// Apply redaction to hide sensitive information
pdf.RedactTextOnPage(
    pageIndex: 0,
    searchText: "SSN: ***-**-****",
    replacementText: "[REDACTED]",
    caseSensitive: false
);

// Save the secured PDF
pdf.SaveAs("secure-confidential.pdf");
// Namespace: IronPdf
using IronPdf;
// Namespace: IronPdf.Editing
using IronPdf.Editing;

var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf("<h1>Confidential Document</h1><p>Sensitive information...</p>");

// Apply password protection
pdf.SecuritySettings.UserPassword = "user123";      // Required to open
pdf.SecuritySettings.OwnerPassword = "owner456";    // Required to modify

// Set detailed permissions
pdf.SecuritySettings.AllowUserCopyPasteContent = false;
pdf.SecuritySettings.AllowUserAnnotations = false;
pdf.SecuritySettings.AllowUserFormData = true;
pdf.SecuritySettings.AllowUserPrinting = PrintPermissions.LowQualityPrint;

// Add digital signature for authenticity
pdf.SignWithFile(
    certificatePath: "certificate.pfx",
    certificatePassword: "certpass123",
    signingReason: "Document Approval",
    signingLocation: "New York, NY",
    signatureImage: new Signature("signature.png")
    {
        Width = 150,
        Height = 50
    }
);

// Apply redaction to hide sensitive information
pdf.RedactTextOnPage(
    pageIndex: 0,
    searchText: "SSN: ***-**-****",
    replacementText: "[REDACTED]",
    caseSensitive: false
);

// Save the secured PDF
pdf.SaveAs("secure-confidential.pdf");
' Namespace: IronPdf
Imports IronPdf
' Namespace: IronPdf.Editing
Imports IronPdf.Editing

Private renderer = New ChromePdfRenderer()
Private pdf = renderer.RenderHtmlAsPdf("<h1>Confidential Document</h1><p>Sensitive information...</p>")

' Apply password protection
pdf.SecuritySettings.UserPassword = "user123" ' Required to open
pdf.SecuritySettings.OwnerPassword = "owner456" ' Required to modify

' Set detailed permissions
pdf.SecuritySettings.AllowUserCopyPasteContent = False
pdf.SecuritySettings.AllowUserAnnotations = False
pdf.SecuritySettings.AllowUserFormData = True
pdf.SecuritySettings.AllowUserPrinting = PrintPermissions.LowQualityPrint

' Add digital signature for authenticity
pdf.SignWithFile(certificatePath:= "certificate.pfx", certificatePassword:= "certpass123", signingReason:= "Document Approval", signingLocation:= "New York, NY", signatureImage:= New Signature("signature.png") With {
	.Width = 150,
	.Height = 50
})

' Apply redaction to hide sensitive information
pdf.RedactTextOnPage(pageIndex:= 0, searchText:= "SSN: ***-**-****", replacementText:= "[REDACTED]", caseSensitive:= False)

' Save the secured PDF
pdf.SaveAs("secure-confidential.pdf")
$vbLabelText   $csharpLabel

PDF'leri Birleştir ve Böl

Birden fazla PDF'yi birleştirmek veya belirli sayfaları çıkarmak, belge yönetimi iş akışları için temel gereksinimdir:

// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

// Merge multiple PDFs into one document
var coverPage = new ChromePdfRenderer().RenderHtmlAsPdf("<h1>Annual Report 2024</h1>");
var introduction = PdfDocument.FromFile("introduction.pdf");
var financials = PdfDocument.FromFile("financials.pdf");
var appendix = PdfDocument.FromFile("appendix.pdf");

// Merge all documents
var completeReport = PdfDocument.Merge(coverPage, introduction, financials, appendix);

// Add page numbers to the merged document
for (int i = 0; i < completeReport.PageCount; i++)
{
    completeReport.AddTextFooterToPage(i, 
        $"Page {i + 1} of {completeReport.PageCount}", 
        IronPdf.Font.FontTypes.Arial, 
        10);
}

completeReport.SaveAs("annual-report-complete.pdf");

// Extract specific pages
var executiveSummary = completeReport.CopyPages(0, 4); // First 5 pages
executiveSummary.SaveAs("executive-summary.pdf");

// Split a large PDF into chapters
var sourcePdf = PdfDocument.FromFile("large-document.pdf");
var chaptersPerFile = 50;

for (int i = 0; i < sourcePdf.PageCount; i += chaptersPerFile)
{
    var endPage = Math.Min(i + chaptersPerFile - 1, sourcePdf.PageCount - 1);
    var chapter = sourcePdf.CopyPages(i, endPage);
    chapter.SaveAs($"chapter-{(i / chaptersPerFile) + 1}.pdf");
}
// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

// Merge multiple PDFs into one document
var coverPage = new ChromePdfRenderer().RenderHtmlAsPdf("<h1>Annual Report 2024</h1>");
var introduction = PdfDocument.FromFile("introduction.pdf");
var financials = PdfDocument.FromFile("financials.pdf");
var appendix = PdfDocument.FromFile("appendix.pdf");

// Merge all documents
var completeReport = PdfDocument.Merge(coverPage, introduction, financials, appendix);

// Add page numbers to the merged document
for (int i = 0; i < completeReport.PageCount; i++)
{
    completeReport.AddTextFooterToPage(i, 
        $"Page {i + 1} of {completeReport.PageCount}", 
        IronPdf.Font.FontTypes.Arial, 
        10);
}

completeReport.SaveAs("annual-report-complete.pdf");

// Extract specific pages
var executiveSummary = completeReport.CopyPages(0, 4); // First 5 pages
executiveSummary.SaveAs("executive-summary.pdf");

// Split a large PDF into chapters
var sourcePdf = PdfDocument.FromFile("large-document.pdf");
var chaptersPerFile = 50;

for (int i = 0; i < sourcePdf.PageCount; i += chaptersPerFile)
{
    var endPage = Math.Min(i + chaptersPerFile - 1, sourcePdf.PageCount - 1);
    var chapter = sourcePdf.CopyPages(i, endPage);
    chapter.SaveAs($"chapter-{(i / chaptersPerFile) + 1}.pdf");
}
' Namespace: IronPdf
Imports IronPdf
' Namespace: System
Imports System

' Merge multiple PDFs into one document
Private coverPage = (New ChromePdfRenderer()).RenderHtmlAsPdf("<h1>Annual Report 2024</h1>")
Private introduction = PdfDocument.FromFile("introduction.pdf")
Private financials = PdfDocument.FromFile("financials.pdf")
Private appendix = PdfDocument.FromFile("appendix.pdf")

' Merge all documents
Private completeReport = PdfDocument.Merge(coverPage, introduction, financials, appendix)

' Add page numbers to the merged document
Dim i As Integer = 0
Do While i < completeReport.PageCount
	completeReport.AddTextFooterToPage(i, $"Page {i + 1} of {completeReport.PageCount}", IronPdf.Font.FontTypes.Arial, 10)
	i += 1
Loop

completeReport.SaveAs("annual-report-complete.pdf")

' Extract specific pages
Dim executiveSummary = completeReport.CopyPages(0, 4) ' First 5 pages
executiveSummary.SaveAs("executive-summary.pdf")

' Split a large PDF into chapters
Dim sourcePdf = PdfDocument.FromFile("large-document.pdf")
Dim chaptersPerFile = 50

For i As Integer = 0 To sourcePdf.PageCount - 1 Step chaptersPerFile
	Dim endPage = Math.Min(i + chaptersPerFile - 1, sourcePdf.PageCount - 1)
	Dim chapter = sourcePdf.CopyPages(i, endPage)
	chapter.SaveAs($"chapter-{(i \ chaptersPerFile) + 1}.pdf")
Next i
$vbLabelText   $csharpLabel

Filigran ve Damga Ekleme

PDF'lere filigran eklemek, belge kontrolü ve markalama açısından çok önemlidir. IronPDF, hem metin hem de görüntü tabanlı filigranlar destekler:

// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

var pdf = PdfDocument.FromFile("document.pdf");

// Add text watermark
pdf.ApplyWatermark(
    html: "<h1 style='color: #ff0000; opacity: 0.5; font-size: 100px;'>DRAFT</h1>",
    rotation: 45,
    opacity: 50,
    verticalAlignment: VerticalAlignment.Middle,
    horizontalAlignment: HorizontalAlignment.Center
);

// Add image watermark (company logo)
pdf.ApplyWatermark(
    html: "<img src='logo-watermark.png' style='width: 300px;' />",
    rotation: 0,
    opacity: 30,
    verticalAlignment: VerticalAlignment.Bottom,
    horizontalAlignment: HorizontalAlignment.Right
);

// Add stamps for document status
pdf.StampHtml(
    Html: @"<div style='border: 3px solid green; padding: 10px; 
            background: white; font-weight: bold; color: green;'>
            APPROVED<br/>
            " + DateTime.Now.ToString("MM/dd/yyyy") + @"
            </div>",
    X: 400,
    Y: 100,
    Width: 150,
    Height: 60,
    PageIndex: 0
);

pdf.SaveAs("watermarked-document.pdf");
// Namespace: IronPdf
using IronPdf;
// Namespace: System
using System;

var pdf = PdfDocument.FromFile("document.pdf");

// Add text watermark
pdf.ApplyWatermark(
    html: "<h1 style='color: #ff0000; opacity: 0.5; font-size: 100px;'>DRAFT</h1>",
    rotation: 45,
    opacity: 50,
    verticalAlignment: VerticalAlignment.Middle,
    horizontalAlignment: HorizontalAlignment.Center
);

// Add image watermark (company logo)
pdf.ApplyWatermark(
    html: "<img src='logo-watermark.png' style='width: 300px;' />",
    rotation: 0,
    opacity: 30,
    verticalAlignment: VerticalAlignment.Bottom,
    horizontalAlignment: HorizontalAlignment.Right
);

// Add stamps for document status
pdf.StampHtml(
    Html: @"<div style='border: 3px solid green; padding: 10px; 
            background: white; font-weight: bold; color: green;'>
            APPROVED<br/>
            " + DateTime.Now.ToString("MM/dd/yyyy") + @"
            </div>",
    X: 400,
    Y: 100,
    Width: 150,
    Height: 60,
    PageIndex: 0
);

pdf.SaveAs("watermarked-document.pdf");
' Namespace: IronPdf
Imports IronPdf
' Namespace: System
Imports System

Private pdf = PdfDocument.FromFile("document.pdf")

' Add text watermark
pdf.ApplyWatermark(html:= "<h1 style='color: #ff0000; opacity: 0.5; font-size: 100px;'>DRAFT</h1>", rotation:= 45, opacity:= 50, verticalAlignment:= VerticalAlignment.Middle, horizontalAlignment:= HorizontalAlignment.Center)

' Add image watermark (company logo)
pdf.ApplyWatermark(html:= "<img src='logo-watermark.png' style='width: 300px;' />", rotation:= 0, opacity:= 30, verticalAlignment:= VerticalAlignment.Bottom, horizontalAlignment:= HorizontalAlignment.Right)

' Add stamps for document status
pdf.StampHtml(Html:= "<div style='border: 3px solid green; padding: 10px; 
            background: white; font-weight: bold; color: green;'>
            APPROVED<br/>
            " & DateTime.Now.ToString("MM/dd/yyyy") & "
            </div>", X:= 400, Y:= 100, Width:= 150, Height:= 60, PageIndex:= 0)

pdf.SaveAs("watermarked-document.pdf")
$vbLabelText   $csharpLabel

PDF'leri Ölçekli Olarak Ürettiğinizde Performansı Nasıl Optimize Edebilirim?

PDF'leri ölçekli olarak ürettiğinizde, performans kritik hale gelir. Binlerce fatura oluşturuyor veya büyük toplu işlemleri işliyorsanız, PDF oluşturma kodunuzu optimize etmek, verimliliği büyük ölçüde artırabilir ve kaynak tüketimini azaltabilir. Modern uygulamalar, işlemi engellemeyen veya aşırı bellek tüketmeyen verimli C# ile PDF oluşturma gerektirir. .NET'te PDF üretmenin gerekliliğini karşılayacak çeşitli PDF üretim görevlerinizde performansı maksimize etmek için kanıtlanmış stratejiler şunlardır.

Asenkron PDF Oluşturma

Modern uygulamalar engelleme yapmayan işlemler gerektirir, böylece yanıt verebilirlik korunur. IronPDF, tüm ana işlemler için async yöntemler sunar:

// Namespace: IronPdf
using IronPdf;
// Namespace: System.Threading.Tasks
using System.Threading.Tasks;
// Namespace: System.Collections.Generic
using System.Collections.Generic;
// Namespace: System.Linq
using System.Linq;
// Namespace: System
using System;
// Namespace: System.Threading
using System.Threading;

public class AsyncPdfService
{
    private readonly ChromePdfRenderer _renderer;

    public AsyncPdfService()
    {
        _renderer = new ChromePdfRenderer();
        // Configure renderer once for reuse
        _renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
    }

    public async Task<byte[]> GeneratePdfAsync(string html)
    {
        // Non-blocking PDF generation
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        return pdf.BinaryData;
    }

    public async Task GenerateBatchAsync(List<string> htmlDocuments)
    {
        // Process multiple PDFs concurrently
        var tasks = htmlDocuments.Select(async (html, index) =>
        {
            var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
            await pdf.SaveAsAsync($"document-{index}.pdf");
        });

        await Task.WhenAll(tasks);
    }

    // Async with cancellation support
    public async Task<PdfDocument> GenerateWithTimeoutAsync(string html, int timeoutSeconds)
    {
        using var cts = new CancellationTokenSource(TimeSpan.FromSeconds(timeoutSeconds));

        try
        {
            return await _renderer.RenderHtmlAsPdfAsync(html, cts.Token);
        }
        catch (OperationCanceledException)
        {
            throw new TimeoutException("PDF generation exceeded timeout");
        }
    }
}
// Namespace: IronPdf
using IronPdf;
// Namespace: System.Threading.Tasks
using System.Threading.Tasks;
// Namespace: System.Collections.Generic
using System.Collections.Generic;
// Namespace: System.Linq
using System.Linq;
// Namespace: System
using System;
// Namespace: System.Threading
using System.Threading;

public class AsyncPdfService
{
    private readonly ChromePdfRenderer _renderer;

    public AsyncPdfService()
    {
        _renderer = new ChromePdfRenderer();
        // Configure renderer once for reuse
        _renderer.RenderingOptions.PaperSize = PdfPaperSize.A4;
    }

    public async Task<byte[]> GeneratePdfAsync(string html)
    {
        // Non-blocking PDF generation
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        return pdf.BinaryData;
    }

    public async Task GenerateBatchAsync(List<string> htmlDocuments)
    {
        // Process multiple PDFs concurrently
        var tasks = htmlDocuments.Select(async (html, index) =>
        {
            var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
            await pdf.SaveAsAsync($"document-{index}.pdf");
        });

        await Task.WhenAll(tasks);
    }

    // Async with cancellation support
    public async Task<PdfDocument> GenerateWithTimeoutAsync(string html, int timeoutSeconds)
    {
        using var cts = new CancellationTokenSource(TimeSpan.FromSeconds(timeoutSeconds));

        try
        {
            return await _renderer.RenderHtmlAsPdfAsync(html, cts.Token);
        }
        catch (OperationCanceledException)
        {
            throw new TimeoutException("PDF generation exceeded timeout");
        }
    }
}
' Namespace: IronPdf
Imports IronPdf
' Namespace: System.Threading.Tasks
Imports System.Threading.Tasks
' Namespace: System.Collections.Generic
Imports System.Collections.Generic
' Namespace: System.Linq
Imports System.Linq
' Namespace: System
Imports System
' Namespace: System.Threading
Imports System.Threading

Public Class AsyncPdfService
	Private ReadOnly _renderer As ChromePdfRenderer

	Public Sub New()
		_renderer = New ChromePdfRenderer()
		' Configure renderer once for reuse
		_renderer.RenderingOptions.PaperSize = PdfPaperSize.A4
	End Sub

	Public Async Function GeneratePdfAsync(ByVal html As String) As Task(Of Byte())
		' Non-blocking PDF generation
		Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(html)
		Return pdf.BinaryData
	End Function

	Public Async Function GenerateBatchAsync(ByVal htmlDocuments As List(Of String)) As Task
		' Process multiple PDFs concurrently
		Dim tasks = htmlDocuments.Select(Async Function(html, index)
			Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(html)
			Await pdf.SaveAsAsync($"document-{index}.pdf")
		End Function)

		Await Task.WhenAll(tasks)
	End Function

	' Async with cancellation support
	Public Async Function GenerateWithTimeoutAsync(ByVal html As String, ByVal timeoutSeconds As Integer) As Task(Of PdfDocument)
		Dim cts = New CancellationTokenSource(TimeSpan.FromSeconds(timeoutSeconds))

		Try
			Return Await _renderer.RenderHtmlAsPdfAsync(html, cts.Token)
		Catch e1 As OperationCanceledException
			Throw New TimeoutException("PDF generation exceeded timeout")
		End Try
	End Function
End Class
$vbLabelText   $csharpLabel

Toplu İşleme En İyi Uygulamalar

Birden fazla PDF işlerken, uygun kaynak yönetimi ve paralel işleme performansı önemli ölçüde artırabilir:

using IronPdf;
using System.Threading.Tasks.Dataflow;

public class BatchPdfProcessor
{
    private readonly ChromePdfRenderer _renderer;
    private readonly ActionBlock<PdfJob> _processingBlock;

    public BatchPdfProcessor(int maxConcurrency = 4)
    {
        _renderer = new ChromePdfRenderer();

        // Create a processing pipeline with controlled concurrency
        _processingBlock = new ActionBlock<PdfJob>(
            async job => await ProcessPdfAsync(job),
            new ExecutionDataflowBlockOptions
            {
                MaxDegreeOfParallelism = maxConcurrency,
                BoundedCapacity = maxConcurrency * 2
            });
    }

    private async Task ProcessPdfAsync(PdfJob job)
    {
        try
        {
            var pdf = await _renderer.RenderHtmlAsPdfAsync(job.Html);
            await pdf.SaveAsAsync(job.OutputPath);
            job.OnSuccess?.Invoke();
        }
        catch (Exception ex)
        {
            job.OnError?.Invoke(ex);
        }
    }

    public async Task<bool> QueuePdfAsync(PdfJob job)
    {
        return await _processingBlock.SendAsync(job);
    }

    public async Task CompleteAsync()
    {
        _processingBlock.Complete();
        await _processingBlock.Completion;
    }
}

public class PdfJob
{
    public string Html { get; set; }
    public string OutputPath { get; set; }
    public Action OnSuccess { get; set; }
    public Action<Exception> OnError { get; set; }
}
using IronPdf;
using System.Threading.Tasks.Dataflow;

public class BatchPdfProcessor
{
    private readonly ChromePdfRenderer _renderer;
    private readonly ActionBlock<PdfJob> _processingBlock;

    public BatchPdfProcessor(int maxConcurrency = 4)
    {
        _renderer = new ChromePdfRenderer();

        // Create a processing pipeline with controlled concurrency
        _processingBlock = new ActionBlock<PdfJob>(
            async job => await ProcessPdfAsync(job),
            new ExecutionDataflowBlockOptions
            {
                MaxDegreeOfParallelism = maxConcurrency,
                BoundedCapacity = maxConcurrency * 2
            });
    }

    private async Task ProcessPdfAsync(PdfJob job)
    {
        try
        {
            var pdf = await _renderer.RenderHtmlAsPdfAsync(job.Html);
            await pdf.SaveAsAsync(job.OutputPath);
            job.OnSuccess?.Invoke();
        }
        catch (Exception ex)
        {
            job.OnError?.Invoke(ex);
        }
    }

    public async Task<bool> QueuePdfAsync(PdfJob job)
    {
        return await _processingBlock.SendAsync(job);
    }

    public async Task CompleteAsync()
    {
        _processingBlock.Complete();
        await _processingBlock.Completion;
    }
}

public class PdfJob
{
    public string Html { get; set; }
    public string OutputPath { get; set; }
    public Action OnSuccess { get; set; }
    public Action<Exception> OnError { get; set; }
}
Imports IronPdf
Imports System.Threading.Tasks.Dataflow

Public Class BatchPdfProcessor
	Private ReadOnly _renderer As ChromePdfRenderer
	Private ReadOnly _processingBlock As ActionBlock(Of PdfJob)

	Public Sub New(Optional ByVal maxConcurrency As Integer = 4)
		_renderer = New ChromePdfRenderer()

		' Create a processing pipeline with controlled concurrency
		_processingBlock = New ActionBlock(Of PdfJob)(Async Function(job) Await ProcessPdfAsync(job), New ExecutionDataflowBlockOptions With {
			.MaxDegreeOfParallelism = maxConcurrency,
			.BoundedCapacity = maxConcurrency * 2
		})
	End Sub

	Private Async Function ProcessPdfAsync(ByVal job As PdfJob) As Task
		Try
			Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(job.Html)
			Await pdf.SaveAsAsync(job.OutputPath)
			If job.OnSuccess IsNot Nothing Then
				job.OnSuccess.Invoke()
			End If
		Catch ex As Exception
			If job.OnError IsNot Nothing Then
				job.OnError.Invoke(ex)
			End If
		End Try
	End Function

	Public Async Function QueuePdfAsync(ByVal job As PdfJob) As Task(Of Boolean)
		Return Await _processingBlock.SendAsync(job)
	End Function

	Public Async Function CompleteAsync() As Task
		_processingBlock.Complete()
		Await _processingBlock.Completion
	End Function
End Class

Public Class PdfJob
	Public Property Html() As String
	Public Property OutputPath() As String
	Public Property OnSuccess() As Action
	Public Property OnError() As Action(Of Exception)
End Class
$vbLabelText   $csharpLabel

Bellek Optimizasyon Teknikleri

Büyük PDF'ler veya yüksek hacimli işlem için, bellek yönetimi çok önemlidir:

using IronPdf;

public class MemoryEfficientPdfGenerator
{
    private readonly ChromePdfRenderer _renderer;

    public MemoryEfficientPdfGenerator()
    {
        _renderer = new ChromePdfRenderer();

        // Optimize for memory usage
        _renderer.RenderingOptions.RenderQuality = 90; // Slightly lower quality for smaller size
        _renderer.RenderingOptions.ImageQuality = 85; // Compress images
    }

    // Stream large PDFs instead of loading into memory
    public async Task GenerateLargePdfToStreamAsync(string html, Stream outputStream)
    {
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);

        // Write directly to stream without keeping in memory
        using (pdf)
        {
            var bytes = pdf.BinaryData;
            await outputStream.WriteAsync(bytes, 0, bytes.Length);
        }
    }

    // Process large HTML in chunks
    public async Task<PdfDocument> GenerateFromChunksAsync(List<string> htmlChunks)
    {
        var pdfs = new List<PdfDocument>();

        try
        {
            // Generate each chunk separately
            foreach (var chunk in htmlChunks)
            {
                var chunkPdf = await _renderer.RenderHtmlAsPdfAsync(chunk);
                pdfs.Add(chunkPdf);
            }

            // Merge all chunks
            return PdfDocument.Merge(pdfs.ToArray());
        }
        finally
        {
            // Ensure all temporary PDFs are disposed
            foreach (var pdf in pdfs)
            {
                pdf?.Dispose();
            }
        }
    }
}
using IronPdf;

public class MemoryEfficientPdfGenerator
{
    private readonly ChromePdfRenderer _renderer;

    public MemoryEfficientPdfGenerator()
    {
        _renderer = new ChromePdfRenderer();

        // Optimize for memory usage
        _renderer.RenderingOptions.RenderQuality = 90; // Slightly lower quality for smaller size
        _renderer.RenderingOptions.ImageQuality = 85; // Compress images
    }

    // Stream large PDFs instead of loading into memory
    public async Task GenerateLargePdfToStreamAsync(string html, Stream outputStream)
    {
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);

        // Write directly to stream without keeping in memory
        using (pdf)
        {
            var bytes = pdf.BinaryData;
            await outputStream.WriteAsync(bytes, 0, bytes.Length);
        }
    }

    // Process large HTML in chunks
    public async Task<PdfDocument> GenerateFromChunksAsync(List<string> htmlChunks)
    {
        var pdfs = new List<PdfDocument>();

        try
        {
            // Generate each chunk separately
            foreach (var chunk in htmlChunks)
            {
                var chunkPdf = await _renderer.RenderHtmlAsPdfAsync(chunk);
                pdfs.Add(chunkPdf);
            }

            // Merge all chunks
            return PdfDocument.Merge(pdfs.ToArray());
        }
        finally
        {
            // Ensure all temporary PDFs are disposed
            foreach (var pdf in pdfs)
            {
                pdf?.Dispose();
            }
        }
    }
}
Imports IronPdf

Public Class MemoryEfficientPdfGenerator
	Private ReadOnly _renderer As ChromePdfRenderer

	Public Sub New()
		_renderer = New ChromePdfRenderer()

		' Optimize for memory usage
		_renderer.RenderingOptions.RenderQuality = 90 ' Slightly lower quality for smaller size
		_renderer.RenderingOptions.ImageQuality = 85 ' Compress images
	End Sub

	' Stream large PDFs instead of loading into memory
	Public Async Function GenerateLargePdfToStreamAsync(ByVal html As String, ByVal outputStream As Stream) As Task
		Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(html)

		' Write directly to stream without keeping in memory
		Using pdf
			Dim bytes = pdf.BinaryData
			Await outputStream.WriteAsync(bytes, 0, bytes.Length)
		End Using
	End Function

	' Process large HTML in chunks
	Public Async Function GenerateFromChunksAsync(ByVal htmlChunks As List(Of String)) As Task(Of PdfDocument)
		Dim pdfs = New List(Of PdfDocument)()

		Try
			' Generate each chunk separately
			For Each chunk In htmlChunks
				Dim chunkPdf = Await _renderer.RenderHtmlAsPdfAsync(chunk)
				pdfs.Add(chunkPdf)
			Next chunk

			' Merge all chunks
			Return PdfDocument.Merge(pdfs.ToArray())
		Finally
			' Ensure all temporary PDFs are disposed
			For Each pdf In pdfs
				If pdf IsNot Nothing Then
					pdf.Dispose()
				End If
			Next pdf
		End Try
	End Function
End Class
$vbLabelText   $csharpLabel

Önbelleğe Alma ve Şablon Optimizasyonu

Ortak unsurları önbelleğe alarak ve şablonları optimize ederek oluşturma süresini azaltın:

using IronPdf;
using Microsoft.Extensions.Caching.Memory;

public class CachedPdfService
{
    private readonly ChromePdfRenderer _renderer;
    private readonly IMemoryCache _cache;
    private readonly Dictionary<string, string> _compiledTemplates;

    public CachedPdfService(IMemoryCache cache)
    {
        _renderer = new ChromePdfRenderer();
        _cache = cache;
        _compiledTemplates = new Dictionary<string, string>();

        // Pre-compile common templates
        PrecompileTemplates();
    }

    private void PrecompileTemplates()
    {
        // Load and cache common CSS
        var commonCss = File.ReadAllText("Templates/common.css");
        _compiledTemplates["commonCss"] = commonCss;

        // Cache logo as Base64
        var logoBytes = File.ReadAllBytes("Assets/logo.png");
        var logoBase64 = Convert.ToBase64String(logoBytes);
        _compiledTemplates["logoData"] = $"data:image/png;base64,{logoBase64}";
    }

    public async Task<byte[]> GenerateInvoicePdfAsync(string invoiceId, InvoiceData data)
    {
        // Check cache first
        var cacheKey = $"invoice_{invoiceId}";
        if (_cache.TryGetValue<byte[]>(cacheKey, out var cachedPdf))
        {
            return cachedPdf;
        }

        // Generate PDF with cached templates
        var html = BuildHtmlWithCache(data);
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        var pdfBytes = pdf.BinaryData;

        // Cache for 1 hour
        _cache.Set(cacheKey, pdfBytes, TimeSpan.FromHours(1));

        return pdfBytes;
    }

    private string BuildHtmlWithCache(InvoiceData data)
    {
        return $@"
            <html>
            <head>
                <style>{_compiledTemplates["commonCss"]}</style>
            </head>
            <body>
                <img src='{_compiledTemplates["logoData"]}' />

            </body>
            </html>";
    }
}
using IronPdf;
using Microsoft.Extensions.Caching.Memory;

public class CachedPdfService
{
    private readonly ChromePdfRenderer _renderer;
    private readonly IMemoryCache _cache;
    private readonly Dictionary<string, string> _compiledTemplates;

    public CachedPdfService(IMemoryCache cache)
    {
        _renderer = new ChromePdfRenderer();
        _cache = cache;
        _compiledTemplates = new Dictionary<string, string>();

        // Pre-compile common templates
        PrecompileTemplates();
    }

    private void PrecompileTemplates()
    {
        // Load and cache common CSS
        var commonCss = File.ReadAllText("Templates/common.css");
        _compiledTemplates["commonCss"] = commonCss;

        // Cache logo as Base64
        var logoBytes = File.ReadAllBytes("Assets/logo.png");
        var logoBase64 = Convert.ToBase64String(logoBytes);
        _compiledTemplates["logoData"] = $"data:image/png;base64,{logoBase64}";
    }

    public async Task<byte[]> GenerateInvoicePdfAsync(string invoiceId, InvoiceData data)
    {
        // Check cache first
        var cacheKey = $"invoice_{invoiceId}";
        if (_cache.TryGetValue<byte[]>(cacheKey, out var cachedPdf))
        {
            return cachedPdf;
        }

        // Generate PDF with cached templates
        var html = BuildHtmlWithCache(data);
        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        var pdfBytes = pdf.BinaryData;

        // Cache for 1 hour
        _cache.Set(cacheKey, pdfBytes, TimeSpan.FromHours(1));

        return pdfBytes;
    }

    private string BuildHtmlWithCache(InvoiceData data)
    {
        return $@"
            <html>
            <head>
                <style>{_compiledTemplates["commonCss"]}</style>
            </head>
            <body>
                <img src='{_compiledTemplates["logoData"]}' />

            </body>
            </html>";
    }
}
Imports IronPdf
Imports Microsoft.Extensions.Caching.Memory
Imports System.IO
Imports System.Threading.Tasks

Public Class CachedPdfService
    Private ReadOnly _renderer As ChromePdfRenderer
    Private ReadOnly _cache As IMemoryCache
    Private ReadOnly _compiledTemplates As Dictionary(Of String, String)

    Public Sub New(cache As IMemoryCache)
        _renderer = New ChromePdfRenderer()
        _cache = cache
        _compiledTemplates = New Dictionary(Of String, String)()

        ' Pre-compile common templates
        PrecompileTemplates()
    End Sub

    Private Sub PrecompileTemplates()
        ' Load and cache common CSS
        Dim commonCss = File.ReadAllText("Templates/common.css")
        _compiledTemplates("commonCss") = commonCss

        ' Cache logo as Base64
        Dim logoBytes = File.ReadAllBytes("Assets/logo.png")
        Dim logoBase64 = Convert.ToBase64String(logoBytes)
        _compiledTemplates("logoData") = $"data:image/png;base64,{logoBase64}"
    End Sub

    Public Async Function GenerateInvoicePdfAsync(invoiceId As String, data As InvoiceData) As Task(Of Byte())
        ' Check cache first
        Dim cacheKey = $"invoice_{invoiceId}"
        Dim cachedPdf As Byte() = Nothing
        If _cache.TryGetValue(cacheKey, cachedPdf) Then
            Return cachedPdf
        End If

        ' Generate PDF with cached templates
        Dim html = BuildHtmlWithCache(data)
        Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(html)
        Dim pdfBytes = pdf.BinaryData

        ' Cache for 1 hour
        _cache.Set(cacheKey, pdfBytes, TimeSpan.FromHours(1))

        Return pdfBytes
    End Function

    Private Function BuildHtmlWithCache(data As InvoiceData) As String
        Return $"
            <html>
            <head>
                <style>{_compiledTemplates("commonCss")}</style>
            </head>
            <body>
                <img src='{_compiledTemplates("logoData")}' />
            </body>
            </html>"
    End Function
End Class
$vbLabelText   $csharpLabel

PDF Oluştururken Ortak Sorunlar Nelerdir ve Bunları Nasıl Düzeltebilirim?

Güçlü bir .NET PDF kütüphanesi olan IronPDF ile bile PDF'leri C# ile oluştururken geliştirme veya dağıtım sırasında zorluklarla karşılaşabilirsiniz. Ortak sorunları ve çözümlerini anlamak, sorunları hızlı bir şekilde çözmenize ve kesintisiz PDF üretim işlemlerini sürdürmenize yardımcı olur. İyi haber, IronPDF'yi C# PDF üreteci olarak kullanan 14 milyondan fazla geliştiriciyle, çoğu sorunun daha önce karşılaşılmış ve çözülmüş olmasıdır. Bu sorun giderme kılavuzu, .NET'te PDF oluştururken geliştiricilerin karşılaştığı en sık sorunları kapsar ve gerçek dünya deneyimine dayalı pratik çözümler sunar. Unutmayın, 7/24 destek, PDF oluşturma zorluklarıyla ilgili anında yardıma ihtiyaçınız olduğunda her zaman mevcuttur.

Sorun 1: Başarısız Oluşturma veya Boş PDF'ler

En yaygın sorunlardan biri PDF'lerin boş görünmesi veya düzgün oluşturulmamasıdır. Bu genellikle varlıklar zamanında yüklenmediğinde veya JavaScript zamanlama sorunları olduğunda: meydana gelir.

// Namespace: IronPdf
using IronPdf;
// Namespace: System.IO
using System.IO;
// Namespace: System
using System;

// Problem: PDF is blank or missing content
var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf(complexHtml); // Results in blank PDF

// Solution 1: Add render delay for JavaScript-heavy content
renderer.RenderingOptions.RenderDelay = 3000; // Wait 3 seconds
renderer.RenderingOptions.EnableJavaScript = true;

// Solution 2: Wait for specific elements
renderer.RenderingOptions.WaitFor = new WaitFor()
{
    JavaScriptQuery = "document.querySelector('#chart-loaded') !== null",
    WaitForType = WaitForType.JavaScript,
    Timeout = 30000 // 30 second timeout
};

// Solution 3: Use base path for local assets
var basePath = Path.GetFullPath("Assets");
var pdf = renderer.RenderHtmlAsPdf(htmlWithImages, basePath);

// Solution 4: Embed assets as Base64
var imageBase64 = Convert.ToBase64String(File.ReadAllBytes("logo.png"));
var htmlWithEmbedded = $@"<img src='data:image/png;base64,{imageBase64}' />";
// Namespace: IronPdf
using IronPdf;
// Namespace: System.IO
using System.IO;
// Namespace: System
using System;

// Problem: PDF is blank or missing content
var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf(complexHtml); // Results in blank PDF

// Solution 1: Add render delay for JavaScript-heavy content
renderer.RenderingOptions.RenderDelay = 3000; // Wait 3 seconds
renderer.RenderingOptions.EnableJavaScript = true;

// Solution 2: Wait for specific elements
renderer.RenderingOptions.WaitFor = new WaitFor()
{
    JavaScriptQuery = "document.querySelector('#chart-loaded') !== null",
    WaitForType = WaitForType.JavaScript,
    Timeout = 30000 // 30 second timeout
};

// Solution 3: Use base path for local assets
var basePath = Path.GetFullPath("Assets");
var pdf = renderer.RenderHtmlAsPdf(htmlWithImages, basePath);

// Solution 4: Embed assets as Base64
var imageBase64 = Convert.ToBase64String(File.ReadAllBytes("logo.png"));
var htmlWithEmbedded = $@"<img src='data:image/png;base64,{imageBase64}' />";
' Namespace: IronPdf
Imports IronPdf
' Namespace: System.IO
Imports System.IO
' Namespace: System
Imports System

' Problem: PDF is blank or missing content
Private renderer = New ChromePdfRenderer()
Private pdf = renderer.RenderHtmlAsPdf(complexHtml) ' Results in blank PDF

' Solution 1: Add render delay for JavaScript-heavy content
renderer.RenderingOptions.RenderDelay = 3000 ' Wait 3 seconds
renderer.RenderingOptions.EnableJavaScript = True

' Solution 2: Wait for specific elements
renderer.RenderingOptions.WaitFor = New WaitFor() With {
	.JavaScriptQuery = "document.querySelector('#chart-loaded') !== null",
	.WaitForType = WaitForType.JavaScript,
	.Timeout = 30000
}

' Solution 3: Use base path for local assets
Dim basePath = Path.GetFullPath("Assets")
Dim pdf = renderer.RenderHtmlAsPdf(htmlWithImages, basePath)

' Solution 4: Embed assets as Base64
Dim imageBase64 = Convert.ToBase64String(File.ReadAllBytes("logo.png"))
Dim htmlWithEmbedded = $"<img src='data:image/png;base64,{imageBase64}' />"
$vbLabelText   $csharpLabel

Kalıcı oluşturma sorunları için, sorunu teşhis etmek üzere günlükleri etkinleştirin:

// Enable detailed logging
IronPdf.Logging.Logger.EnableDebugging = true;
IronPdf.Logging.Logger.LogFilePath = "IronPdf.log";
IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All;
// Enable detailed logging
IronPdf.Logging.Logger.EnableDebugging = true;
IronPdf.Logging.Logger.LogFilePath = "IronPdf.log";
IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All;
' Enable detailed logging
IronPdf.Logging.Logger.EnableDebugging = True
IronPdf.Logging.Logger.LogFilePath = "IronPdf.log"
IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All
$vbLabelText   $csharpLabel

Oluşturma sorunlarıyla ilgili daha fazla bilgi edinin

Sorun 2: Yavaş İlk Oluşturma

İlk PDF üretimi, başlatma aşırı yükü nedeniyle daha yavaş olabilir. IronPDF'nin ilk oluşturması, Chrome'un masaüstü bir ortamda açılmasına benzer şekilde, yürütmesi için 2-3 saniye sürebilir:

// Problem: First PDF takes too long to generate
public class PdfService
{
    private ChromePdfRenderer _renderer;

    // Solution 1: Initialize renderer at startup
    public void Initialize()
    {
        _renderer = new ChromePdfRenderer();

        // Warm up the renderer
        _ = _renderer.RenderHtmlAsPdf("<p>Warm up</p>");
    }

    // Solution 2: Use IronPdf.Native packages for faster initialization
    // Install-Package IronPdf.Native.Windows.X64
    // This includes pre-loaded binaries for your platform

    // Solution 3: For cloud deployments, use appropriate packages
    // For Linux: Install-Package IronPdf.Linux
    // For Docker: Use IronPdf.Linux with proper dependencies
}

// Solution 4: Skip initialization checks in production
IronPdf.Installation.SkipInitialization = true; // Use only with persistent storage
// Problem: First PDF takes too long to generate
public class PdfService
{
    private ChromePdfRenderer _renderer;

    // Solution 1: Initialize renderer at startup
    public void Initialize()
    {
        _renderer = new ChromePdfRenderer();

        // Warm up the renderer
        _ = _renderer.RenderHtmlAsPdf("<p>Warm up</p>");
    }

    // Solution 2: Use IronPdf.Native packages for faster initialization
    // Install-Package IronPdf.Native.Windows.X64
    // This includes pre-loaded binaries for your platform

    // Solution 3: For cloud deployments, use appropriate packages
    // For Linux: Install-Package IronPdf.Linux
    // For Docker: Use IronPdf.Linux with proper dependencies
}

// Solution 4: Skip initialization checks in production
IronPdf.Installation.SkipInitialization = true; // Use only with persistent storage
' Problem: First PDF takes too long to generate
Public Class PdfService
	Private _renderer As ChromePdfRenderer

	' Solution 1: Initialize renderer at startup
	Public Sub Initialize()
		_renderer = New ChromePdfRenderer()

		' Warm up the renderer
'INSTANT VB TODO TASK: Underscore 'discards' are not converted by Instant VB:
'ORIGINAL LINE: _ = _renderer.RenderHtmlAsPdf("<p>Warm up</p>");
		underscore = _renderer.RenderHtmlAsPdf("<p>Warm up</p>")
	End Sub

	' Solution 2: Use IronPdf.Native packages for faster initialization
	' Install-Package IronPdf.Native.Windows.X64
	' This includes pre-loaded binaries for your platform

	' Solution 3: For cloud deployments, use appropriate packages
	' For Linux: Install-Package IronPdf.Linux
	' For Docker: Use IronPdf.Linux with proper dependencies
End Class

' Solution 4: Skip initialization checks in production
IronPdf.Installation.SkipInitialization = True ' Use only with persistent storage
$vbLabelText   $csharpLabel

Başlangıç performansını optimize etme hakkında daha fazla bilgi edinin

Sorun 3: Linux/Docker Dağıtım Sorunları

IronPDF, minimal Docker görüntülerinde bulunmayabilecek belirli Linux bağımlılıklarını gerektirir. Ortak dağıtım sorunlarını çözmenin yolu aşağıda:

# Dockerfile for IronPDF on Linux
FROM mcr.microsoft.com/dotnet/aspnet:8.0

# Install required dependencies
RUN apt-get update && apt-get install -y \
    libglib2.0-0 \
    libnss3 \
    libatk1.0-0 \
    libatk-bridge2.0-0 \
    libcups2 \
    libxkbcommon0 \
    libxcomposite1 \
    libxdamage1 \
    libxrandr2 \
    libgbm1 \
    libpango-1.0-0 \
    libcairo2 \
    libasound2 \
    libxshmfence1 \
    libx11-xcb1

# Copy and run your application
WORKDIR /app
COPY . .
ENTRYPOINT ["dotnet", "YourApp.dll"]

Özellikle Google Cloud Run için:

// Use 2nd generation execution environment
// Deploy with: gcloud run deploy --execution-environment gen2

// In your code, ensure compatibility
IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = true;
IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled;
// Use 2nd generation execution environment
// Deploy with: gcloud run deploy --execution-environment gen2

// In your code, ensure compatibility
IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = true;
IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled;
' Use 2nd generation execution environment
' Deploy with: gcloud run deploy --execution-environment gen2

' In your code, ensure compatibility
IronPdf.Installation.LinuxAndDockerDependenciesAutoConfig = True
IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled
$vbLabelText   $csharpLabel

Docker dağıtımı hakkında daha fazla bilgi edinin

Sorun 4: Bellek ve Performans Sorunları

Yüksek hacimli PDF üretimi için, bellek kullanımı ve performansı optimize edin:

// Problem: High memory usage or slow batch processing
public class OptimizedPdfService
{
    private readonly ChromePdfRenderer _renderer;

    public OptimizedPdfService()
    {
        _renderer = new ChromePdfRenderer();

        // Optimize for performance
        _renderer.RenderingOptions.RenderQuality = 90;
        _renderer.RenderingOptions.ImageQuality = 85;

        // Disable features you don't need
        _renderer.RenderingOptions.EnableJavaScript = false; // If not needed
        _renderer.RenderingOptions.RenderDelay = 0; // If content is static
    }

    // Solution 1: Process large documents in chunks
    public async Task<PdfDocument> GenerateLargeReportAsync(List<ReportSection> sections)
    {
        var pdfs = new List<PdfDocument>();

        foreach (var section in sections)
        {
            var sectionHtml = GenerateSectionHtml(section);
            var sectionPdf = await _renderer.RenderHtmlAsPdfAsync(sectionHtml);
            pdfs.Add(sectionPdf);

            // Force garbage collection after each section
            if (pdfs.Count % 10 == 0)
            {
                GC.Collect();
                GC.WaitForPendingFinalizers();
            }
        }

        return PdfDocument.Merge(pdfs.ToArray());
    }

    // Solution 2: Use streaming for large files
    public async Task StreamLargePdfAsync(string html, HttpResponse response)
    {
        response.ContentType = "application/pdf";
        response.Headers.Add("Content-Disposition", "attachment; filename=report.pdf");

        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        var bytes = pdf.BinaryData;

        await response.Body.WriteAsync(bytes, 0, bytes.Length);
        await response.Body.FlushAsync();
    }
}
// Problem: High memory usage or slow batch processing
public class OptimizedPdfService
{
    private readonly ChromePdfRenderer _renderer;

    public OptimizedPdfService()
    {
        _renderer = new ChromePdfRenderer();

        // Optimize for performance
        _renderer.RenderingOptions.RenderQuality = 90;
        _renderer.RenderingOptions.ImageQuality = 85;

        // Disable features you don't need
        _renderer.RenderingOptions.EnableJavaScript = false; // If not needed
        _renderer.RenderingOptions.RenderDelay = 0; // If content is static
    }

    // Solution 1: Process large documents in chunks
    public async Task<PdfDocument> GenerateLargeReportAsync(List<ReportSection> sections)
    {
        var pdfs = new List<PdfDocument>();

        foreach (var section in sections)
        {
            var sectionHtml = GenerateSectionHtml(section);
            var sectionPdf = await _renderer.RenderHtmlAsPdfAsync(sectionHtml);
            pdfs.Add(sectionPdf);

            // Force garbage collection after each section
            if (pdfs.Count % 10 == 0)
            {
                GC.Collect();
                GC.WaitForPendingFinalizers();
            }
        }

        return PdfDocument.Merge(pdfs.ToArray());
    }

    // Solution 2: Use streaming for large files
    public async Task StreamLargePdfAsync(string html, HttpResponse response)
    {
        response.ContentType = "application/pdf";
        response.Headers.Add("Content-Disposition", "attachment; filename=report.pdf");

        var pdf = await _renderer.RenderHtmlAsPdfAsync(html);
        var bytes = pdf.BinaryData;

        await response.Body.WriteAsync(bytes, 0, bytes.Length);
        await response.Body.FlushAsync();
    }
}
' Problem: High memory usage or slow batch processing
Public Class OptimizedPdfService
	Private ReadOnly _renderer As ChromePdfRenderer

	Public Sub New()
		_renderer = New ChromePdfRenderer()

		' Optimize for performance
		_renderer.RenderingOptions.RenderQuality = 90
		_renderer.RenderingOptions.ImageQuality = 85

		' Disable features you don't need
		_renderer.RenderingOptions.EnableJavaScript = False ' If not needed
		_renderer.RenderingOptions.RenderDelay = 0 ' If content is static
	End Sub

	' Solution 1: Process large documents in chunks
	Public Async Function GenerateLargeReportAsync(ByVal sections As List(Of ReportSection)) As Task(Of PdfDocument)
		Dim pdfs = New List(Of PdfDocument)()

		For Each section In sections
			Dim sectionHtml = GenerateSectionHtml(section)
			Dim sectionPdf = Await _renderer.RenderHtmlAsPdfAsync(sectionHtml)
			pdfs.Add(sectionPdf)

			' Force garbage collection after each section
			If pdfs.Count Mod 10 = 0 Then
				GC.Collect()
				GC.WaitForPendingFinalizers()
			End If
		Next section

		Return PdfDocument.Merge(pdfs.ToArray())
	End Function

	' Solution 2: Use streaming for large files
	Public Async Function StreamLargePdfAsync(ByVal html As String, ByVal response As HttpResponse) As Task
		response.ContentType = "application/pdf"
		response.Headers.Add("Content-Disposition", "attachment; filename=report.pdf")

		Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(html)
		Dim bytes = pdf.BinaryData

		Await response.Body.WriteAsync(bytes, 0, bytes.Length)
		Await response.Body.FlushAsync()
	End Function
End Class
$vbLabelText   $csharpLabel

Tam performans optimizasyon kılavuzunu okuyun

Sorun 5: Yazı Tipi ve Kodlama Sorunları

Uluslararası içerik veya özel yazı tipleriyle uğraşırken:

// Problem: Fonts not rendering correctly
var renderer = new ChromePdfRenderer();

// Solution 1: Install fonts on the server
// For Linux/Docker, add to Dockerfile:
// RUN apt-get install -y fonts-liberation fonts-noto

// Solution 2: Embed fonts in HTML
var html = @"
<html>
<head>
    <style>
        @font-face {
            font-family: 'CustomFont';
            src: url('data:font/woff2;base64,[base64-encoded-font]') format('woff2');
        }
        body { font-family: 'CustomFont', Arial, sans-serif; }
    </style>
</head>
<body>
    <p>Content with custom font</p>
</body>
</html>";

// Solution 3: Use web fonts
var htmlWithWebFont = @"
<html>
<head>
    <link href='https://fonts.googleapis.com/css2?family=Noto+Sans+JP' rel='stylesheet'>
    <style>
        body { font-family: 'Noto Sans JP', sans-serif; }
    </style>
</head>
<body>
    <p>日本語のテキスト</p>
</body>
</html>";

// Ensure proper encoding
renderer.RenderingOptions.InputEncoding = Encoding.UTF8;
// Problem: Fonts not rendering correctly
var renderer = new ChromePdfRenderer();

// Solution 1: Install fonts on the server
// For Linux/Docker, add to Dockerfile:
// RUN apt-get install -y fonts-liberation fonts-noto

// Solution 2: Embed fonts in HTML
var html = @"
<html>
<head>
    <style>
        @font-face {
            font-family: 'CustomFont';
            src: url('data:font/woff2;base64,[base64-encoded-font]') format('woff2');
        }
        body { font-family: 'CustomFont', Arial, sans-serif; }
    </style>
</head>
<body>
    <p>Content with custom font</p>
</body>
</html>";

// Solution 3: Use web fonts
var htmlWithWebFont = @"
<html>
<head>
    <link href='https://fonts.googleapis.com/css2?family=Noto+Sans+JP' rel='stylesheet'>
    <style>
        body { font-family: 'Noto Sans JP', sans-serif; }
    </style>
</head>
<body>
    <p>日本語のテキスト</p>
</body>
</html>";

// Ensure proper encoding
renderer.RenderingOptions.InputEncoding = Encoding.UTF8;
' Problem: Fonts not rendering correctly
Dim renderer = New ChromePdfRenderer()

' Solution 1: Install fonts on the server
' For Linux/Docker, add to Dockerfile:
' RUN apt-get install -y fonts-liberation fonts-noto

' Solution 2: Embed fonts in HTML
Dim html = "
<html>
<head>
    <style>
        @font-face {
            font-family: 'CustomFont';
            src: url('data:font/woff2;base64,[base64-encoded-font]') format('woff2');
        }
        body { font-family: 'CustomFont', Arial, sans-serif; }
    </style>
</head>
<body>
    <p>Content with custom font</p>
</body>
</html>"

' Solution 3: Use web fonts
Dim htmlWithWebFont = "
<html>
<head>
    <link href='https://fonts.googleapis.com/css2?family=Noto+Sans+JP' rel='stylesheet'>
    <style>
        body { font-family: 'Noto Sans JP', sans-serif; }
    </style>
</head>
<body>
    <p>日本語のテキスト</p>
</body>
</html>"

' Ensure proper encoding
renderer.RenderingOptions.InputEncoding = Encoding.UTF8
$vbLabelText   $csharpLabel

Yardım Alma

Burada ele alınmayan sorunlarla karşılaşırsanız, IronPDF mükemmel destek kaynakları sunar:

  1. 7/24 Canlı Sohbet Desteği - 30 saniyelik yanıt süresi ile mühendislerle gerçek zamanlı konuşun
  2. Kapsamlı Dokümantasyon - Detaylı API referansları ve kılavuzlar
  3. Bilgi Tabanı - Sık karşılaşılan sorunlar için çözümler
  4. Kod Örnekleri - Kullanıma hazır kod parçacıkları

Destek talep ederken, ekleyin:

  • IronPDF versiyonu
  • .NET sürümü ve platformu
  • Sorunu tekrarlayan minimal kod örneği
    • Günlük dosyaları (varsa)
    • Yığın izi veya hata mesajları

Hangi Platformlar IronPDF için PDF Üretimini Destekler?

IronPDF'nin platformlar arası desteği, PDF üretim kodlarınızın çeşitli ortamlarda tutarlı bir şekilde çalışmasını sağlar. Windows sunuculara, Linux konteynerlerine veya bulut platformlarına dağıtırken, IronPDF, üretim dağıtımlarınızın C# PDF üreteci için gereken esneklik ve güvenilirliği sağlar. Bu evrensel uyumluluk, 50'den fazla ülkedeki organizasyonların, günlük milyonlarca PDF üretmesi için IronPDF'ye güvenmesinin nedenlerinden biridir. Fortune 500 şirketlerinin finansal raporlar oluşturmasından girişimlerin müşteri faturaları üretmesine kadar, IronPDF, .NET'te PDF oluşturma ihtiyaçını karşılamak için ölçeklenir. Platforma özgü konuların anlaşılması, altyapınız genelinde sorunsuz dağıtımlar sağlanmasına yardımcı olur - bu, dahili sunucular veya PDF'leri C# ile oluşturmanız gereken bulut ortamları olabilir.

.NET Sürüm Uyumluluğu

IronPDF tüm modern .NET sürümlerini destekler ve en yeni sürümlerle desteklenmeye devam eder:

  • .NET 8 - Tüm özelliklerle tam destek
  • .NET 9 - Tam destek (mevcut en yeni sürüm)
  • .NET 10 - Ön sürüm desteği mevcut (IronPDF, Kasım 2025 sürümü için zaten uyumludur)
  • .NET 7, 6, 5 - Tam destek
  • .NET Core 3.1+ - Tüm özelliklerle desteklenir
  • .NET Framework 4.6.2+ - Eski destek korunur

İşletim Sistemi Desteği

PDF oluşturma çözümünüzü herhangi bir büyük işletim sistemine dağıtın:

Windows

  • Windows 11, 10, 8, 7
  • Windows Server 2022, 2019, 2016, 2012

Linux

  • Ubuntu 20.04, 22.04, 24.04
  • Debian 10, 11, 12
  • CentOS 7, 8
  • Red Hat Enterprise Linux
  • Alpine Linux (ek yapılandırma ile)

macOS

  • macOS 13 (Ventura) ve üzeri
  • Apple Silicon (M1/M2/M3) yerel destek
  • Intel tabanlı Mac'ler tam desteklenir

Bulut Platformu Dağıtımı

IronPDF, tüm büyük bulut platformlarında sorunsuz çalışır:

Microsoft Azure

// Azure App Service configuration
// Use at least B1 tier for optimal performance
// Enable 64-bit platform in Configuration settings

// For Azure Functions
public static class PdfFunction
{
    [FunctionName("GeneratePdf")]
    public static async Task<IActionResult> Run(
        [HttpTrigger(AuthorizationLevel.Function, "post")] HttpRequest req)
    {
        var renderer = new ChromePdfRenderer();
        var html = await new StreamReader(req.Body).ReadToEndAsync();
        var pdf = await renderer.RenderHtmlAsPdfAsync(html);

        return new FileContentResult(pdf.BinaryData, "application/pdf");
    }
}
// Azure App Service configuration
// Use at least B1 tier for optimal performance
// Enable 64-bit platform in Configuration settings

// For Azure Functions
public static class PdfFunction
{
    [FunctionName("GeneratePdf")]
    public static async Task<IActionResult> Run(
        [HttpTrigger(AuthorizationLevel.Function, "post")] HttpRequest req)
    {
        var renderer = new ChromePdfRenderer();
        var html = await new StreamReader(req.Body).ReadToEndAsync();
        var pdf = await renderer.RenderHtmlAsPdfAsync(html);

        return new FileContentResult(pdf.BinaryData, "application/pdf");
    }
}
' Azure App Service configuration
' Use at least B1 tier for optimal performance
' Enable 64-bit platform in Configuration settings

' For Azure Functions
Public Module PdfFunction
	<FunctionName("GeneratePdf")>
	Public Async Function Run(<HttpTrigger(AuthorizationLevel.Function, "post")> ByVal req As HttpRequest) As Task(Of IActionResult)
		Dim renderer = New ChromePdfRenderer()
		Dim html = Await (New StreamReader(req.Body)).ReadToEndAsync()
		Dim pdf = Await renderer.RenderHtmlAsPdfAsync(html)

		Return New FileContentResult(pdf.BinaryData, "application/pdf")
	End Function
End Module
$vbLabelText   $csharpLabel

Amazon Web Services (AWS)

// AWS Lambda configuration
// Use custom runtime or container deployment
// Ensure Lambda has at least 512MB memory

public class PdfLambdaFunction
{
    private readonly ChromePdfRenderer _renderer;

    public PdfLambdaFunction()
    {
        _renderer = new ChromePdfRenderer();
        // Configure for Lambda environment
        IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled;
    }

    public async Task<APIGatewayProxyResponse> FunctionHandler(
        APIGatewayProxyRequest request, 
        ILambdaContext context)
    {
        var pdf = await _renderer.RenderHtmlAsPdfAsync(request.Body);

        return new APIGatewayProxyResponse
        {
            StatusCode = 200,
            Headers = new Dictionary<string, string> 
            { 
                { "Content-Type", "application/pdf" } 
            },
            Body = Convert.ToBase64String(pdf.BinaryData),
            IsBase64Encoded = true
        };
    }
}
// AWS Lambda configuration
// Use custom runtime or container deployment
// Ensure Lambda has at least 512MB memory

public class PdfLambdaFunction
{
    private readonly ChromePdfRenderer _renderer;

    public PdfLambdaFunction()
    {
        _renderer = new ChromePdfRenderer();
        // Configure for Lambda environment
        IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled;
    }

    public async Task<APIGatewayProxyResponse> FunctionHandler(
        APIGatewayProxyRequest request, 
        ILambdaContext context)
    {
        var pdf = await _renderer.RenderHtmlAsPdfAsync(request.Body);

        return new APIGatewayProxyResponse
        {
            StatusCode = 200,
            Headers = new Dictionary<string, string> 
            { 
                { "Content-Type", "application/pdf" } 
            },
            Body = Convert.ToBase64String(pdf.BinaryData),
            IsBase64Encoded = true
        };
    }
}
' AWS Lambda configuration
' Use custom runtime or container deployment
' Ensure Lambda has at least 512MB memory

Public Class PdfLambdaFunction
	Private ReadOnly _renderer As ChromePdfRenderer

	Public Sub New()
		_renderer = New ChromePdfRenderer()
		' Configure for Lambda environment
		IronPdf.Installation.ChromeGpuMode = IronPdf.Engines.Chrome.ChromeGpuModes.Disabled
	End Sub

	Public Async Function FunctionHandler(ByVal request As APIGatewayProxyRequest, ByVal context As ILambdaContext) As Task(Of APIGatewayProxyResponse)
		Dim pdf = Await _renderer.RenderHtmlAsPdfAsync(request.Body)

		Return New APIGatewayProxyResponse With {
			.StatusCode = 200,
			.Headers = New Dictionary(Of String, String) From {
				{"Content-Type", "application/pdf"}
			},
			.Body = Convert.ToBase64String(pdf.BinaryData),
			.IsBase64Encoded = True
		}
	End Function
End Class
$vbLabelText   $csharpLabel

Google Cloud Platform

# app.yaml for App Engine
runtime: aspnetcore
env: flex

# Use 2nd generation for Cloud Run
# Deploy with: gcloud run deploy --execution-environment gen2
# app.yaml for App Engine
runtime: aspnetcore
env: flex

# Use 2nd generation for Cloud Run
# Deploy with: gcloud run deploy --execution-environment gen2
YAML

Konteyner Dağıtımı (Docker/Kubernetes)

IronPDF, tam Docker ve Kubernetes desteğiyle konteyner kullanımına hazırdır:

# Multi-stage Dockerfile for optimal size
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
COPY ["YourApp.csproj", "./"]
RUN dotnet restore
COPY . .
RUN dotnet publish -c Release -o /app/publish

FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS final
WORKDIR /app

# Install IronPDF dependencies
RUN apt-get update && apt-get install -y \
    libglib2.0-0 libnss3 libatk1.0-0 libatk-bridge2.0-0 \
    libcups2 libxkbcommon0 libxcomposite1 libxdamage1 \
    libxrandr2 libgbm1 libpango-1.0-0 libcairo2 libasound2

COPY --from=build /app/publish .
ENTRYPOINT ["dotnet", "YourApp.dll"]

Masaüstü Uygulama Desteği

IronPDF, tüm büyük .NET masaüstü framework'leri ile çalışır:

WPF (Windows Presentation Foundation)

public partial class MainWindow : Window
{
    private async void GeneratePdfButton_Click(object sender, RoutedEventArgs e)
    {
        var renderer = new ChromePdfRenderer();
        var html = HtmlEditor.Text;

        var pdf = await renderer.RenderHtmlAsPdfAsync(html);

        var saveDialog = new SaveFileDialog
        {
            Filter = "PDF files (*.pdf)|*.pdf",
            DefaultExt = "pdf"
        };

        if (saveDialog.ShowDialog() == true)
        {
            pdf.SaveAs(saveDialog.FileName);
            MessageBox.Show("PDF saved successfully!");
        }
    }
}
public partial class MainWindow : Window
{
    private async void GeneratePdfButton_Click(object sender, RoutedEventArgs e)
    {
        var renderer = new ChromePdfRenderer();
        var html = HtmlEditor.Text;

        var pdf = await renderer.RenderHtmlAsPdfAsync(html);

        var saveDialog = new SaveFileDialog
        {
            Filter = "PDF files (*.pdf)|*.pdf",
            DefaultExt = "pdf"
        };

        if (saveDialog.ShowDialog() == true)
        {
            pdf.SaveAs(saveDialog.FileName);
            MessageBox.Show("PDF saved successfully!");
        }
    }
}
Partial Public Class MainWindow
	Inherits Window

	Private Async Sub GeneratePdfButton_Click(ByVal sender As Object, ByVal e As RoutedEventArgs)
		Dim renderer = New ChromePdfRenderer()
		Dim html = HtmlEditor.Text

		Dim pdf = Await renderer.RenderHtmlAsPdfAsync(html)

		Dim saveDialog = New SaveFileDialog With {
			.Filter = "PDF files (*.pdf)|*.pdf",
			.DefaultExt = "pdf"
		}

		If saveDialog.ShowDialog() = True Then
			pdf.SaveAs(saveDialog.FileName)
			MessageBox.Show("PDF saved successfully!")
		End If
	End Sub
End Class
$vbLabelText   $csharpLabel

Windows Forms

public partial class PdfGeneratorForm : Form
{
    private void btnGeneratePdf_Click(object sender, EventArgs e)
    {
        var renderer = new ChromePdfRenderer();
        var pdf = renderer.RenderHtmlAsPdf(txtHtml.Text);

        using (var saveDialog = new SaveFileDialog())
        {
            saveDialog.Filter = "PDF files|*.pdf";
            if (saveDialog.ShowDialog() == DialogResult.OK)
            {
                pdf.SaveAs(saveDialog.FileName);
                MessageBox.Show($"PDF saved to {saveDialog.FileName}");
            }
        }
    }
}
public partial class PdfGeneratorForm : Form
{
    private void btnGeneratePdf_Click(object sender, EventArgs e)
    {
        var renderer = new ChromePdfRenderer();
        var pdf = renderer.RenderHtmlAsPdf(txtHtml.Text);

        using (var saveDialog = new SaveFileDialog())
        {
            saveDialog.Filter = "PDF files|*.pdf";
            if (saveDialog.ShowDialog() == DialogResult.OK)
            {
                pdf.SaveAs(saveDialog.FileName);
                MessageBox.Show($"PDF saved to {saveDialog.FileName}");
            }
        }
    }
}
Partial Public Class PdfGeneratorForm
	Inherits Form

	Private Sub btnGeneratePdf_Click(ByVal sender As Object, ByVal e As EventArgs)
		Dim renderer = New ChromePdfRenderer()
		Dim pdf = renderer.RenderHtmlAsPdf(txtHtml.Text)

		Using saveDialog = New SaveFileDialog()
			saveDialog.Filter = "PDF files|*.pdf"
			If saveDialog.ShowDialog() = System.Windows.Forms.DialogResult.OK Then
				pdf.SaveAs(saveDialog.FileName)
				MessageBox.Show($"PDF saved to {saveDialog.FileName}")
			End If
		End Using
	End Sub
End Class
$vbLabelText   $csharpLabel

MAUI (Multi-platform App UI)

public partial class MainPage : ContentPage
{
    public async Task GeneratePdfAsync()
    {
        var renderer = new ChromePdfRenderer();
        var pdf = await renderer.RenderHtmlAsPdfAsync(HtmlContent);

        // Save to app's document directory
        var documentsPath = FileSystem.Current.AppDataDirectory;
        var filePath = Path.Combine(documentsPath, "output.pdf");

        await File.WriteAllBytesAsync(filePath, pdf.BinaryData);

        await DisplayAlert("Success", $"PDF saved to {filePath}", "OK");
    }
}
public partial class MainPage : ContentPage
{
    public async Task GeneratePdfAsync()
    {
        var renderer = new ChromePdfRenderer();
        var pdf = await renderer.RenderHtmlAsPdfAsync(HtmlContent);

        // Save to app's document directory
        var documentsPath = FileSystem.Current.AppDataDirectory;
        var filePath = Path.Combine(documentsPath, "output.pdf");

        await File.WriteAllBytesAsync(filePath, pdf.BinaryData);

        await DisplayAlert("Success", $"PDF saved to {filePath}", "OK");
    }
}
Partial Public Class MainPage
	Inherits ContentPage

	Public Async Function GeneratePdfAsync() As Task
		Dim renderer = New ChromePdfRenderer()
		Dim pdf = Await renderer.RenderHtmlAsPdfAsync(HtmlContent)

		' Save to app's document directory
		Dim documentsPath = FileSystem.Current.AppDataDirectory
		Dim filePath = Path.Combine(documentsPath, "output.pdf")

		Await File.WriteAllBytesAsync(filePath, pdf.BinaryData)

		Await DisplayAlert("Success", $"PDF saved to {filePath}", "OK")
	End Function
End Class
$vbLabelText   $csharpLabel

PDF Oluşturmaya Başlarken

C# uygulamanızda PDF oluşturmaya hazır mısınız? Kurulumdan ilk oluşturulan PDF'nize kadar adım adım kılavuzu takip edin. IronPDF, her adımda kapsamlı kaynaklar ve destek ile başlamayı kolaylaştırır.

Adım 1: IronPDF'i Kurun

Geliştirme ortamınıza en iyi uyan kurulum yöntemini seçin:

Visual Studio Package Manager** (Önerilen)

  1. Projenizi Visual Studio'da açın
  2. Solution Explorer'da projenize sağ tıklayın
  3. "Manage NuGet Packages"ı seçin
  4. "IronPDF" için arama yapın
  5. Iron Software tarafından sağlanan IronPdf paketini yükleyin

Paket Yöneticisi Konsolu**

Install-Package IronPdf

.NET CLI

dotnet add package IronPdf

NuGet paketi, Windows, Linux ve macOS'ta PDF oluşturma için gereken her şeyi içerir. Özel dağıtımlar için, boyut ve performansı optimize eden bu platforma özgü paketleri düşünün:

  • IronPdf.Linux - Linux ortamları için optimize edilmiştir
  • IronPdf.MacOs - Yerel Apple Silicon desteği
  • IronPdf.Slim - Çalışma zamanında bağımlılıkları indiren minimal paket

Adım 2: İlk PDF'inizi Oluşturun

Her şeyin çalıştığını doğrulamak için basit bir örnek ile başlayın:

using IronPdf;

class Program
{
    static void Main()
    {
        // Create a new PDF generator instance
        var renderer = new ChromePdfRenderer();

        // Generate PDF from HTML
        var pdf = renderer.RenderHtmlAsPdf(@"
            # Welcome to IronPDF!
            <p>This is your first generated PDF document.</p>
            <p>Created on: " + DateTime.Now + "</p>"
        );

        // Save the PDF
        pdf.SaveAs("my-first-pdf.pdf");

        Console.WriteLine("PDF created successfully!");
    }
}
using IronPdf;

class Program
{
    static void Main()
    {
        // Create a new PDF generator instance
        var renderer = new ChromePdfRenderer();

        // Generate PDF from HTML
        var pdf = renderer.RenderHtmlAsPdf(@"
            # Welcome to IronPDF!
            <p>This is your first generated PDF document.</p>
            <p>Created on: " + DateTime.Now + "</p>"
        );

        // Save the PDF
        pdf.SaveAs("my-first-pdf.pdf");

        Console.WriteLine("PDF created successfully!");
    }
}
Imports IronPdf

Class Program
    Shared Sub Main()
        ' Create a new PDF generator instance
        Dim renderer = New ChromePdfRenderer()

        ' Generate PDF from HTML
        Dim pdf = renderer.RenderHtmlAsPdf("
            # Welcome to IronPDF!
            <p>This is your first generated PDF document.</p>
            <p>Created on: " & DateTime.Now & "</p>"
        )

        ' Save the PDF
        pdf.SaveAs("my-first-pdf.pdf")

        Console.WriteLine("PDF created successfully!")
    End Sub
End Class
$vbLabelText   $csharpLabel

Adım 3: Örnekleri ve Eğitimleri Keşfedin

IronPDF, PDF oluşturmayı öğrenmenize yardımcı olacak geniş bir kaynak sunar:

  1. Kod Örnekleri - Yaygın senaryolar için kullanıma hazır kod parçacıkları
  2. Eğitimler - Belirli özellikler için adım adım kılavuzlar
  3. Nasıl Yapılır Kılavuzları - Gerçek dünyadaki sorunlara pratik çözümler
  4. API Referansı - Tüm sınıfların ve metodların kapsamlı dokümantasyonu

Adım 4: Gerektiğinde Yardım Alın

IronPDF, başarınızı sağlamak için birçok destek kanalı sunar:

Adım 5: Geliştirme ve Dağıtım

Ücretsiz Geliştirme Lisansı

IronPDF, geliştirme ve test için ücretsizdir. Geliştirirken hiçbir kısıtlama olmadan tüm özellikleri keşfedebilirsiniz. Geliştirme modunda oluşturulan PDF'lerde filigranlar bulunur ancak işlevselliği etkilemez.

Üretim Dağıtım Seçenekleri

Üretime dağıtmaya hazır olduğunuzda, IronPDF, esnek lisanslama seçenekleri sunar:

  1. Ücretsiz Deneme - Üretimde su işaretsiz test etmek için 30 günlük deneme lisansı alın
  2. Ticari Lisanslar - Tek proje dağıtımı için $799'dan başlayan fiyatlarla
  3. Kurumsal Çözümler - Büyük organizasyonlar için özel paketler

Kodunuza bir lisans uygulamak için:

IronPdf.License.LicenseKey = "YOUR-LICENSE-KEY";
IronPdf.License.LicenseKey = "YOUR-LICENSE-KEY";
IronPdf.License.LicenseKey = "YOUR-LICENSE-KEY"
$vbLabelText   $csharpLabel

Adım 6: Güncel Kalın

PDF oluşturmaya ilişkin yeteneklerinizi güncel tutun:

Düzenli güncellemeler, en son .NET sürümleriyle uyumluluğu sağlar ve performans iyileştirmeleri, yeni özellikler ve güvenlik güncellemeleri içerir.

C# ile PDF Oluşturma İçin Neden IronPDF Seçmelisiniz?

C#'da PDF oluşturmak için çeşitli yaklaşımlar araştırdıktan sonra, birçok geliştiricinin IronPDF'i neden tercih ettiği seçim olduğunu merak edebilirsiniz. Bu sadece özelliklerle ilgili değil - tüm geliştirici deneyimi ile ilgilidir; bu, ilk uygulamadan uzun süreli bakıma kadar gereklidir .NET içinde PDF oluşturduğunuzda. 14 milyonun üzerinde geliştirici küresel olarak IronPDF'i C# PDF üreticisi olarak kullanırken, bu, .NET uygulamalarında PDF oluşturma için fiili bir standart haline geldi. Gelin, geliştiricilerin C# ihtiyaçları için PDF oluşturma açısından neden IronPDF'i seçtiklerine bakalım.

Piksel-Doğru İşleme

HTML tasarımlarınızın tahminlerini üreten diğer PDF kütüphanelerinin aksine, IronPDF, PDF'lerinizin sizin bir modern web tarayıcısında olduğu gibi aynı görsellikte olmasına olanak sağlamak için gerçek bir Chromium motoru kullanır. Bu piksel-doğru işleme yeteneği, finansal kurumların hassas raporları güvenle oluşturmak için IronPDF'e güvendiği sebep. CSS Grid düzenleriniz, flexbox tasarımlarınız ve JavaScript-taranan içeriğiniz mükemmel çalışır. PDF belgeleri oluşturduğunuz zaman özelleştirilmiş düzen motorlarıyla savaşmaya ya da "yeterince yakın" sonuçlar kabullenmeye son.

Geliştirici-Dostu API

IronPDF'in API'si geliştiriciler tarafından, geliştiriciler için olarak tasarlandı. API'nin sadeliği, girişimlerin PDF oluşturmasını saatler içinde çalışır hale getirebilir. Karmaşık PDF spesifikasyonlarını öğrenmek yerine, tanıdık kavramlarla çalışıyorsunuz:

using IronPdf;

// Other libraries might require this:
// document.Add(new Paragraph("Hello World"));
// document.Add(new Table(3, 2));
// cell.SetBackgroundColor(ColorConstants.LIGHT_GRAY);

// With IronPDF, just use HTML:
var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf(@"
    # Hello World
    <table>
        <tr style='background: lightgray;'>
            <td>Simple</td>
            <td>Intuitive</td>
        </tr>
    </table>
");
using IronPdf;

// Other libraries might require this:
// document.Add(new Paragraph("Hello World"));
// document.Add(new Table(3, 2));
// cell.SetBackgroundColor(ColorConstants.LIGHT_GRAY);

// With IronPDF, just use HTML:
var renderer = new ChromePdfRenderer();
var pdf = renderer.RenderHtmlAsPdf(@"
    # Hello World
    <table>
        <tr style='background: lightgray;'>
            <td>Simple</td>
            <td>Intuitive</td>
        </tr>
    </table>
");
Imports IronPdf

' Other libraries might require this:
' document.Add(New Paragraph("Hello World"))
' document.Add(New Table(3, 2))
' cell.SetBackgroundColor(ColorConstants.LIGHT_GRAY)

' With IronPDF, just use HTML:
Dim renderer As New ChromePdfRenderer()
Dim pdf = renderer.RenderHtmlAsPdf("
    # Hello World
    <table>
        <tr style='background: lightgray;'>
            <td>Simple</td>
            <td>Intuitive</td>
        </tr>
    </table>
")
$vbLabelText   $csharpLabel

Kurumsal-Hazır Özellikler

IronPDF, Enterprise uygulamaların talep ettiği özellikleri içerir, bu yüzden Fortune 500 şirketleri, görev açısından kritik olan belge oluşturma için ona güvenmektedir:

  • Güvenlik: Şifreleme, dijital imzalar ve izin denetimleri hassas belgeleri korur
  • Uyumluluk: PDF/A ve PDF/UA desteği, oluşturduğunuz PDF'lerin yasal gereklilikleri karşıladığını garanti eder
  • Performans: Asenkron işlemler ve toplu işleme, milyonlarca belgeyi verimli bir şekilde işler
  • Güvenilirlik: Kapsamlı hata işleme ve günlük kaydı, üretim ortamında kesintisiz çalışma sağlar

Olağanüstü Destek

Yardıma ihtiyaçınız olduğunda, IronPDF'nin destek ekibinde gerçek mühendisler bulunur ve onlar sizin zorluklarınızı anlar. 24/7 canlı sohbet desteği ve tipik yanıt süreleri 30 saniyenin altında olduğunda, asla cevapsız kalmazsınız. Bu destek seviyesi, geliştiricilerin IronPDF'yi sürekli olarak sektördeki en iyi desteğe sahip olarak değerlendirmesinin nedeni. Destek ekibi, temel sorulardan karmaşık uygulama zorluklarına kadar her konuda yardımcı olabilir ve PDF oluşturma projelerinizin başarılı olmasını sağlar.

Şeffaf Fiyatlandırma

Gizli ücret yok, sürpriz maliyet yok, sunucu başına lisanslama karmaşası yok. IronPDF'nin sade lisanslama modeli sayesinde ne için ödeme yaptığınızı tam olarak bilirsiniz. Geliştirme her zaman ücretsizdir ve üretim lisansları süresizdir - onları sonsuza kadar sahip olursunuz. Bu şeffaflık, karmaşık lisanslama şemaları ile tanınan bir sektörde ferahlık sağlar.

Aktif Geliştirme

IronPDF, aylık güncellemelerle sürekli olarak iyileştirilir ve bu güncellemeler özellik ekler, performansı artırır ve en son .NET sürümleriyle uyumu sağlar. Ekip, müşteri geri bildirimlerini aktif olarak izler ve düzenli olarak istenen özellikleri uygular. Son eklemeler arasında gelişmiş form işleme, iyileştirilmiş PDF düzenleme yetenekleri ve bulut dağıtımlar için optimizasyonlar bulunur.

Gerçek Dünya Başarı Hikayeleri

Binden fazla şirket sektörde görev açısından kritik PDF oluşturma için IronPDF'ye güveniyor:

  • Finans: Bankalar, IronPDF'nin güvenli belge özelliklerini kullanarak her ay milyonlarca bildirim ve rapor oluşturur
  • Sağlık: Hastaneler, HIPAA uyumlu güvenlik ayarları ile hasta kayıtları ve laboratuvar sonuçları oluşturur
  • Elektronik Ticaret: Çevrimiçi perakendeciler, kolayca yükleri yükleyerek faturalar ve nakliye etiketleri üretir
  • Hükümet: Ajanslar, dijital imzalar ve şifreleme ile resmi belgeler ve formlar oluşturur

Bu kuruluşlar, IronPDF'yi seçiyor çünkü o, ister tek bir fatura oluşturma ister günde milyonlarca belge işleme olsun, ölçekli tutarlı sonuçlar sunar.

IronPDF, Diğer C# PDF Kütüphaneleriyle Nasıl Karşılaştırılır?

Doğru PDF kütüphanesini seçmek, C# ile PDF oluşturmanız gerektiğinde projenizin başarısı için çok önemlidir. .NET ekosistemindeki popüler seçeneklerle PDF oluşturma için IronPDF'nin nasıl karşılaştırıldığına bir bakalım. Bu karşılaştırma, .NET'te PDF oluşturmak isteyenler için gerçek dünya kullanımı, geliştirici geri bildirimleri ve teknik yetenekler temelindedir. Bu farklılıkları anlamak, özel ihtiyaçlarınız için en iyi C# PDF oluşturucusunu seçmenize yardımcı olur.

Karşılaştırma Tablosu

Ayrıntılı Karşılaştırmalar

IronPDF vs wkhtmltopdf

  • wkhtmltopdf ücretsizdir ancak 2020'de terk edilmiştir ve eski görünümlü PDF'ler üretir
  • Dağıtımı karmaşıklaştıran platforma özel çalışabilir dosyalar gerektirir
  • JavaScript desteği yoktur, bu da modern web uygulamalarının düzgün render edilmeyeceği anlamına gelir
  • IronPDF, herhangi bir harici bağımlılık olmadan modern render sunar

IronPDF vs QuestPDF

  • QuestPDF, tamamen C# kodunda PDF oluşturmayı gerektirir ve HTML desteği yoktur
  • Programatik PDF oluşturma için iyi ancak karmaşık düzenler için zaman alıcı
  • Yakın zamanda MIT'den ticari lisanslamaya geçiş yaptı
  • IronPDF, zaten sahip olduğunuz HTML/CSS becerilerini kullanmanıza olanak tanır

IronPDF vs iText 7

  • iText'in AGPL lisansı kod tabanınızı "bulaştırabilir"
  • Ticari lisanslar $1.999'dan başlar ve karmaşık fiyatlandırması vardır
  • Sınırlı HTML to PDF yetenekleri ile kötü CSS desteği
  • IronPDF, daha düşük bir fiyat noktasında üstün HTML render sağlar

IronPDF vs PdfSharp

  • PdfSharp, düşük seviyede PDF manipülasyonu için harikadır ancak sıfır HTML desteğine sahiptir
  • Sayfadaki her öğeyi manuel olarak yerleştirmeyi gerektirir
  • Ücretsiz ve açık kaynak ancak özellikleri çok sınırlıdır
  • IronPDF, hem yüksek seviyede HTML hem de düşük seviyede PDF işlemlerini işler

IronPDF vs Syncfusion/Aspose.PDF

  • İkisi de iyi özelliklere sahip kurumsal seçenekler ancak daha yüksek fiyatlandırmalara sahipler
  • Syncfusion $2.995, Aspose $2.499'dan başlıyor
  • Hiçbiri IronPDF'nin aynı pikselle mükemmel HTML renderına ulaşamıyor
  • IronPDF, karşılaştırılabilir kurumsal özelliklerle daha iyi bir değer sunar

Geçiş Yolları

Birçok geliştirici, diğer kütüphanelerden IronPDF'ye geçer. İşte nedenleri:

wkhtmltopdf'den

  • "Platforma özel ikili dosyalar ve eski render ile uğraşmaktan bıkmıştık"
  • "IronPDF bize modern CSS desteği verdi ve Docker sıkıntılarımızı ortadan kaldırdı"

iTextSharp/iText 7'den

  • "Öğrenme eğrisi üretkenliğimizi öldürüyordu - IronPDF HTML kullanmamıza izin verdi"
  • "AGPL lisansı ticari ürünümüz için bağlayıcıydı"

PdfSharp'tan

  • "PdfSharp'ın basitçe yapmadığı HTML to PDF dönüştürme ihtiyaçımız vardı"
  • "Her öğeyi manuel olarak yerleştirmek çok uzun sürüyordu"

QuestPDF'den

  • "C# kodunda düzen oluşturmak, HTML/CSS kullanmaya kıyasla sıkıcıydı"
  • "Son lisans değişikliği, seçeneklerimizi yeniden düşünmemizi sağladı"

Sonuç

C# ile PDF oluşturmak karmaşık olmak zorunda değil. IronPDF ile, zaten sahip olduğunuz HTML ve CSS becerilerini kullanarak profesyonel PDF belgeleri oluşturabilirsiniz. Basit raporlar veya grafikler ve formlar içeren karmaşık belgeler yapılandırıyorsanız, IronPDF ağır işleri üstlenir, böylece uygulama mantığınız üzerinde yoğunlaşabilirsiniz. Dünya çapında 14 milyon geliştiriciye katılın, IronPDF'ye C# PDF oluşturucusu olarak PDF'leri üretmek için güvenin ve güvenilir şekilde oluşturun.

Bu kılavuz boyunca, birden fazla yaklaşım kullanarak PDF belgeleri oluşturmayı keşfettik - HTML dizgilerinden ve URL'lerden, Word belgeleri ve Markdown gibi mevcut dosyaları dönüştürmeye kadar. IronPDF'nin modern Chromium tabanlı render motorunun pikselle mükemmel sonuçlar ürettiğini gördük, bu sonuçlar aslında web tasarımlarınıza benziyor, eski yazıcı çıktısına değil. PDF belgelerini programatik olarak manipüle etme yeteneği, güvenlik özellikleri ekleme ve performansı optimize etme, IronPDF'yi tüm PDF oluşturma görevleriniz için tam bir çözüm haline getirir.

IronPDF'yi ayrı kılan, geliştirici odaklı yaklaşımıdır. Sadece üç satır kodla ilk PDF'nizi oluşturabilirsiniz. Sezgisel API sayesinde, tescilli PDF sözdizimini öğrenmek için daha az zaman harcar ve özellikler oluşturmaya daha fazla zaman harcarsınız. Gerçek mühendislerden gelen mükemmel destek, şeffaf fiyatlandırma ve sürekli güncellemelerle (içerdiği .NET 10 için ön sürüm desteği) IronPDF, C# ile PDF oluşturma işlerinizin bugün ve gelecekte çalışacağından emin olmanıza olanak tanır.

Bugün PDF'ler oluşturmaya başlayın - ücretsiz deneme lisansınızı alın ve .NET'te PDF oluşturmanın uygulamalarınızda ne kadar kolay olabileceğini görün. IronPDF ile, dakikalar içinde profesyonel PDF'ler oluşturabilirsiniz, saatler değil.

İlk PDF'nizi oluşturmaya hazır mısınız? IronPDF ile başlayın - geliştirme için ücretsizdir ve dakikalar içinde C# ile PDF'ler oluşturmaya başlayacaksınız.

Lütfen dikkate alinAspose, iText, wkhtmltopdf, QuestPDF, PdfSharp ve SyncFusion kendi sahiplerinin tescilli markalarıdır. Bu site, Aspose, iText, wkhtmltopdf, QuestPDF, PdfSharp veya SyncFusion ile ilişkilendirilmemiş, onaylanmamış veya sponsor olunmamıştır. Tüm ürün adları, logoları ve markalar ilgili sahiplerinin malıdır. Karşılaştırmalar yalnızca bilgilendirme amaçlı sağlanmıştır ve yazım anında mevcut olan halka açık bilgilere dayanmaktadır.

Sıkça Sorulan Sorular

C#'ta HTML içeriğinden bir PDF nasıl oluşturabilirim?

IronPDF'nin RenderHtmlAsPdf yöntemi ile C#'ta HTML içeriğinden PDF oluşturabilirsiniz. Bu, HTML dizgilerini veya URL'leri doğrudan PDF belgelerine kolayca dönüştürmenize olanak tanır.

Ticari bir PDF kütüphanesini ücretsiz olana tercih etmenin avantajları nelerdir?

IronPDF gibi ticari PDF kütüphaneleri, JavaScript, CSS3 ve duyarlı mizanpajlar için tam destek gibi güçlü özellikler sunar. Güvenilir performans, düzenli güncellemeler, kapsamlı destek sağlarlar ve yüksek kaliteli PDF'ler oluşturmak için optimize edilmiştirler.

IronPDF, PDF'leri ASP.NET MVC uygulamalarında oluşturmak için kullanılabilir mi?

Evet, IronPDF, Razor görünümlerini veya HTML şablonlarını PDF'lere dönüştürmek için ASP.NET MVC uygulamalarında kullanılabilir ve bu sayede web uygulamalarınıza PDF oluşturma işlemini sorunsuz bir şekilde entegre etmenize olanak sağlar.

C# kullanarak PDF belgelerime resim ve CSS'yi nasıl entegre edebilirim?

IronPDF kullanarak, resimleri ve CSS'i PDF belgelerinize kolayca entegre edebilirsiniz. Bu, HTML içeriğinizde resim etiketlerini ve CSS stillerini içerecek şekilde, ardından IronPDF'nin render yeteneklerini kullanarak PDF'ye dönüştürerek başarılabilir.

C# dilinde PDF'lere başlıklar, altbilgiler ve sayfa numaraları eklemek mümkün mü?

Evet, IronPDF, PDF belgelerinize başlık, altbilgi ve sayfa numaralandırma eklemenize olanak tanıyan gelişmiş özellikler sunar. Bu, HTML içeriğinizi oluşturmadan önce PDF ayarlarını yapılandırarak yapılabilir.

C# ile PDF oluştururken XML verilerini nasıl işleyebilirim?

IronPDF ile, XML verilerinizi HTML'ye dönüştürerek veya XML'i biçimlendirmek için XSLT kullanarak ele alabilirsiniz. Bunun ardından, IronPDF'nin RenderHtmlAsPdf yöntemi kullanılarak bir PDF belgesine dönüştürülebilir.

C# ile PDF oluştururken karşılaşılan yaygın zorluklar nelerdir?

Yaygın zorluklar arasında düzen tutarlılığını koruma, karmaşık CSS ve JavaScript ile başa çıkma ve web teknolojilerinin doğru şekilde görüntülenmesini sağlama yer alır. IronPDF, bu zorlukların üstesinden modern Chromium motoru ve HTML5 ile CSS3 standartları için kapsamlı desteği ile gelir.

C# ile büyük PDF dosyalarini verimli bir şekilde nasıl oluşturabilirim?

IronPDF, büyük PDF oluşturma işlemlerini verimli bir şekilde yönetmek için tasarlanmistir. Yüksek performansli bir işleme motoru kullanir ve büyük dokümanlari rahatlikla yönetmek için asenkron işlemleri destekler.

IronPDF'yi ticari bir lisans olmadan test edebilir miyim?

Evet, IronPDF, geliştirme ve test amaclari için ücretsiz bir lisans sunar, bu da size uretim kullanımi için ticari bir lisans satın almadan önce özelliklerini degerlendirmenize olanak tanir.

.NET 10 Uyumluluğu: IronPDF'yi .NET 10 ile kullanabilir miyim ve özel dikkate alınması gereken bir şey var mı?

Evet, IronPDF, .NET 10 ile tamamen uyumludur. Windows, Linux, konteynerler ortamları ve web framework'leri hedefleyen projeler dahil .NET 10'u kutudan çıktığı gibi destekler. Özel bir yapılandırma gerektirmez—en son IronPDF NuGet paketini yüklemeniz yeterlidir ve .NET 10 ile sorunsuz çalışacaktır.

Jacob Mellor, Teknoloji Direktörü @ Team Iron
Chief Technology Officer

Jacob Mellor, Iron Software'in Teknoloji Müdürü ve C# PDF teknolojisinin öncüsü olan vizyoner bir mühendis. Iron Software’in temel kod tabanının ilk geliştiricisi olarak, şirketin ürün mimarisini kuruluşundan bu yana şekillendirdi ve CEO Cameron Rimington ile birlikte NASA, Tesla ve ...

Daha Fazlasını Oku

Iron Destek Ekibi

Haftanın 5 günü, 24 saat çevrimiçiyiz.
Sohbet
E-posta
Beni Ara