IRONSOFTWAREHOME
Agregar adjuntos
using IronPdf;
using System.IO;

// Instantiate the Renderer and create PdfDocument from HTML
var renderer = new ChromePdfRenderer();
var myPdf = renderer.RenderHtmlFileAsPdf("my-content.html");

// Load your own attachment
byte[] attachment = File.ReadAllBytes("path/to/attachment");

// Here we can add an attachment with a name and a byte[]
PdfAttachment exampleAttachment = myPdf.Attachments.AddAttachment("exampleAttachment", attachment);

// And here is an example of removing an attachment
myPdf.Attachments.RemoveAttachment(exampleAttachment);

myPdf.SaveAs("my-content.pdf");
Imports IronPdf
Imports System.IO

' Instantiate the Renderer and create PdfDocument from HTML
Dim renderer As New ChromePdfRenderer()
Dim myPdf = renderer.RenderHtmlFileAsPdf("my-content.html")

' Load your own attachment
Dim attachment As Byte() = File.ReadAllBytes("path/to/attachment")

' Here we can add an attachment with a name and a byte()
Dim exampleAttachment As PdfAttachment = myPdf.Attachments.AddAttachment("exampleAttachment", attachment)

' And here is an example of removing an attachment
myPdf.Attachments.RemoveAttachment(exampleAttachment)

myPdf.SaveAs("my-content.pdf")
NuGet Download
PM > Install-Package IronPdf
Agregar adjuntos

Agregar adjuntos

IronPDF admite la adición y eliminación de adjuntos en sus documentos PDF.

Para más información, puedes explorar la Documentación de IronPDF donde guías detalladas y recursos están disponibles. Además, aprende sobre más características y capacidades en el Sitio Web de Iron Software.

En el contexto de la facturación electrónica española, adjuntar archivos a un PDF es una práctica habitual: el estándar Facturae permite incrustar el XML de la factura dentro del propio PDF, facilitando el envío conjunto a la AEAT o a FACe. Asimismo, es común adjuntar el certificado digital emitido por la FNMT para acreditar la firma PAdES conforme al reglamento eIDAS, o incluir documentación de soporte exigida por el SII en las declaraciones de IVA.

Aprenda a añadir/eliminar archivos adjuntos en PDF con IronPDF.
Ver en GitHub

¿Listo para empezar?

Nuget Downloads 20,809,720Versión:2026.9recién publicada

Key in blue circle

Obtenga su clave de prueba gratuita de 30 días al instante.

Your trial license will be sent to your email address

Sin limitaciones. 100 % desbloqueado. Sin tarjeta de crédito.

bullet_checkedNo se requiere tarjeta de crédito ni creación de cuentaSin limitaciones. 100 % desbloqueado. Sin tarjeta de crédito.
  • Logo Aetna
  • Logo NASA
  • Logo GE
  • Logo Porsche
  • Logo USDA
  • Logo Qatar
Join Millions of Engineers who’ve tried IronPDF
Reserve su Demostración en Vivo gratuita
Booking Badge

Confiado por millones de ingenieros en todo el mundo

Logos de clientes de Iron Software
Obtén tu Consulta Sin Compromiso
Completa el formulario a continuación o envía un correo a sales@ironsoftware.com
Tus detalles siempre serán mantenidos confidenciales.
Confiado por millones de ingenieros en todo el mundo
Logos de clientes de Iron Software
Obtenga su Clave de Prueba de 30 días gratis al instante.
No se requiere tarjeta de crédito ni creación de cuenta