{"id":2239,"date":"2024-10-17T12:55:00","date_gmt":"2024-10-17T12:55:00","guid":{"rendered":"http:\/\/localhost:10003\/?p=2239"},"modified":"2025-08-04T13:56:23","modified_gmt":"2025-08-04T13:56:23","slug":"ouverture-rapide-et-facile-de-documents-xlsx-excel-en-c","status":"publish","type":"post","link":"https:\/\/xceed.com\/fr\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/","title":{"rendered":"Ouverture rapide et facile des documents Excel xlsx dans C#"},"content":{"rendered":"\n<p>Manipulating xlsx files in .NET can appear complicated and tedious however, doing so only requires a few lines of codes while using Xceed Workbooks for .NET. Let&#8217;s look at a quick example :<\/p>\n\n\n\n<p><br>To Open an existing xlsx :<\/p>\n\n\n\n<p><code>using( var doc = Workbook.Load( \"test.xlsx\") ) \/\/ Loads an existing Workbook named \u201ctest.xlsx\u201d.<\/code><br><code>{<\/code><br><code>var worksheet = doc.Worksheets[ 1 ]; \/\/ Gets the second worksheet.<\/code><br><code>worksheet.Cells[ \u201cA2\u201d ].Value = 12; \/\/ Sets a value in \u201cA2\u201d.<\/code><br><code>var stream = new MemoryStream();<\/code><br><code>doc.SaveAs( stream); \/\/ Saves the result in a stream.<\/code><br><code>}<\/code><\/p>\n\n\n\n<p><code>var stream = new MemoryStream();<\/code><br><code>using( var doc = Workbook.Create( stream ) ) \/\/ Creates a workbook in a stream.<\/code><br><code>{<\/code><br><code>var worksheet = doc.Worksheets[ 1 ]; \/\/ Gets the second worksheet.<\/code><br><code>worksheet.Cells[ \u201cA2\u201d ].Value = 12; \/\/ Sets a value in \u201cA2\u201d.<\/code><br><code>worksheet.Columns[ 1 ].Cells[ 0 ].Formula = \u201c=SUM(A1:A2)\u201d; \/\/Sets a formula in \u201cB1\u201d.<\/code><br><code>doc.CalculateFormulas(); \/\/ Calculate the Value of \u201cB1\u201d, which contains a formula and for all other Worksheets containing cells with formulas.<\/code><br><code>doc.Save(); \/\/ Saves the Workbook in the stream.<\/code><br><code>}<\/code><\/p>\n\n\n\n<p>As you can see, with just a few lines of codes you&#8217;ll be able to create\/modify\/load workbooks. We offer a trial version of the product should you want to try it for yourself. We&#8217;re available on both Nuget and directly on our website :&nbsp;<a href=\"http:\/\/xceed.com\/en\/our-products\/product\/workbooks-for-net\">http:\/\/xceed.com\/en\/our-products\/product\/workbooks-for-net<\/a>&nbsp;(click on try it now).<\/p>\n\n\n\n<p>Have questions or issues? Drop us an email at&nbsp;<a href=\"mailto:support@xceed.com\">support@xceed.com<\/a>.<\/p>\n\n\n\n<p>Have fun!<\/p>\n\n\n\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>La manipulation des fichiers xlsx dans .NET peut sembler compliqu\u00e9e et fastidieuse, mais elle ne n\u00e9cessite que quelques lignes de code \u00e0 l'aide de Xceed Workbooks for .NET.<\/p>","protected":false},"author":2,"featured_media":2235,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[141,60],"tags":[],"class_list":["post-2239","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-all","category-tutorials"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.7 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Quick and Easy Way of Opening xlsx excel documents in C# - Xceed<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/xceed.com\/fr\/blog\/tutoriels\/ouverture-rapide-et-facile-de-documents-xlsx-excel-en-c\/\" \/>\n<meta property=\"og:locale\" content=\"fr_CA\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Quick and Easy Way of Opening xlsx excel documents in C# - Xceed\" \/>\n<meta property=\"og:description\" content=\"Manipulating xlsx files in .NET can appear complicated and tedious however, doing so only requires a few lines of codes while using Xceed Workbooks for .NET.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/xceed.com\/fr\/blog\/tutoriels\/ouverture-rapide-et-facile-de-documents-xlsx-excel-en-c\/\" \/>\n<meta property=\"og:site_name\" content=\"Xceed\" \/>\n<meta property=\"article:published_time\" content=\"2024-10-17T12:55:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-08-04T13:56:23+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png\" \/>\n\t<meta property=\"og:image:width\" content=\"393\" \/>\n\t<meta property=\"og:image:height\" content=\"392\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Alain Jreij\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alain Jreij\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/\"},\"author\":{\"name\":\"Alain Jreij\",\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#\\\/schema\\\/person\\\/2d9169e6fd8ae4a8f58a9e1cc9a73778\"},\"headline\":\"Quick and Easy Way of Opening xlsx excel documents in C#\",\"datePublished\":\"2024-10-17T12:55:00+00:00\",\"dateModified\":\"2025-08-04T13:56:23+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/\"},\"wordCount\":125,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/blog_WBN.png\",\"articleSection\":[\"All\",\"Tutorials\"],\"inLanguage\":\"fr-CA\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/\",\"url\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/\",\"name\":\"Quick and Easy Way of Opening xlsx excel documents in C# - Xceed\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/blog_WBN.png\",\"datePublished\":\"2024-10-17T12:55:00+00:00\",\"dateModified\":\"2025-08-04T13:56:23+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#breadcrumb\"},\"inLanguage\":\"fr-CA\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"fr-CA\",\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#primaryimage\",\"url\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/blog_WBN.png\",\"contentUrl\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/10\\\/blog_WBN.png\",\"width\":393,\"height\":392},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/xceed.com\\\/blog\\\/tutorials\\\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/xceed.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Quick and Easy Way of Opening xlsx excel documents in C#\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#website\",\"url\":\"https:\\\/\\\/xceed.com\\\/fr\\\/\",\"name\":\"Xceed\",\"description\":\"Provides tools for .NET, Windows Forms, WPF, Silverlight, and ASP.NET developers to create better applications.\",\"publisher\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/xceed.com\\\/fr\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"fr-CA\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#organization\",\"name\":\"Xceed\",\"url\":\"https:\\\/\\\/xceed.com\\\/fr\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"fr-CA\",\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/cropped-xceed-logo.png\",\"contentUrl\":\"https:\\\/\\\/xceed.com\\\/wp-content\\\/uploads\\\/2024\\\/04\\\/cropped-xceed-logo.png\",\"width\":609,\"height\":150,\"caption\":\"Xceed\"},\"image\":{\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/xceed.com\\\/fr\\\/#\\\/schema\\\/person\\\/2d9169e6fd8ae4a8f58a9e1cc9a73778\",\"name\":\"Alain Jreij\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"fr-CA\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g\",\"caption\":\"Alain Jreij\"},\"url\":\"https:\\\/\\\/xceed.com\\\/fr\\\/blog\\\/author\\\/jreijaxceed-com\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Ouverture rapide et facile des documents Excel xlsx dans C# - Xceed","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/xceed.com\/fr\/blog\/tutoriels\/ouverture-rapide-et-facile-de-documents-xlsx-excel-en-c\/","og_locale":"fr_CA","og_type":"article","og_title":"Quick and Easy Way of Opening xlsx excel documents in C# - Xceed","og_description":"Manipulating xlsx files in .NET can appear complicated and tedious however, doing so only requires a few lines of codes while using Xceed Workbooks for .NET.","og_url":"https:\/\/xceed.com\/fr\/blog\/tutoriels\/ouverture-rapide-et-facile-de-documents-xlsx-excel-en-c\/","og_site_name":"Xceed","article_published_time":"2024-10-17T12:55:00+00:00","article_modified_time":"2025-08-04T13:56:23+00:00","og_image":[{"width":393,"height":392,"url":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png","type":"image\/png"}],"author":"Alain Jreij","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alain Jreij","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#article","isPartOf":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/"},"author":{"name":"Alain Jreij","@id":"https:\/\/xceed.com\/fr\/#\/schema\/person\/2d9169e6fd8ae4a8f58a9e1cc9a73778"},"headline":"Quick and Easy Way of Opening xlsx excel documents in C#","datePublished":"2024-10-17T12:55:00+00:00","dateModified":"2025-08-04T13:56:23+00:00","mainEntityOfPage":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/"},"wordCount":125,"commentCount":0,"publisher":{"@id":"https:\/\/xceed.com\/fr\/#organization"},"image":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#primaryimage"},"thumbnailUrl":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png","articleSection":["All","Tutorials"],"inLanguage":"fr-CA","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/","url":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/","name":"Ouverture rapide et facile des documents Excel xlsx dans C# - Xceed","isPartOf":{"@id":"https:\/\/xceed.com\/fr\/#website"},"primaryImageOfPage":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#primaryimage"},"image":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#primaryimage"},"thumbnailUrl":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png","datePublished":"2024-10-17T12:55:00+00:00","dateModified":"2025-08-04T13:56:23+00:00","breadcrumb":{"@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#breadcrumb"},"inLanguage":"fr-CA","potentialAction":[{"@type":"ReadAction","target":["https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/"]}]},{"@type":"ImageObject","inLanguage":"fr-CA","@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#primaryimage","url":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png","contentUrl":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/10\/blog_WBN.png","width":393,"height":392},{"@type":"BreadcrumbList","@id":"https:\/\/xceed.com\/blog\/tutorials\/quick-and-easy-way-of-opening-xlsx-excel-documents-in-c\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/xceed.com\/"},{"@type":"ListItem","position":2,"name":"Quick and Easy Way of Opening xlsx excel documents in C#"}]},{"@type":"WebSite","@id":"https:\/\/xceed.com\/fr\/#website","url":"https:\/\/xceed.com\/fr\/","name":"Xceed","description":"Fournit des outils aux d\u00e9veloppeurs .NET, Windows Forms, WPF, Silverlight et ASP.NET pour cr\u00e9er de meilleures applications.","publisher":{"@id":"https:\/\/xceed.com\/fr\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/xceed.com\/fr\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"fr-CA"},{"@type":"Organization","@id":"https:\/\/xceed.com\/fr\/#organization","name":"Xceed","url":"https:\/\/xceed.com\/fr\/","logo":{"@type":"ImageObject","inLanguage":"fr-CA","@id":"https:\/\/xceed.com\/fr\/#\/schema\/logo\/image\/","url":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/04\/cropped-xceed-logo.png","contentUrl":"https:\/\/xceed.com\/wp-content\/uploads\/2024\/04\/cropped-xceed-logo.png","width":609,"height":150,"caption":"Xceed"},"image":{"@id":"https:\/\/xceed.com\/fr\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/xceed.com\/fr\/#\/schema\/person\/2d9169e6fd8ae4a8f58a9e1cc9a73778","name":"Alain Jreij","image":{"@type":"ImageObject","inLanguage":"fr-CA","@id":"https:\/\/secure.gravatar.com\/avatar\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/87ff2d1efbe1a868809d8d554724877b76941f668176489a42238d867ab8bf06?s=96&d=mm&r=g","caption":"Alain Jreij"},"url":"https:\/\/xceed.com\/fr\/blog\/author\/jreijaxceed-com\/"}]}},"_links":{"self":[{"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/posts\/2239","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/comments?post=2239"}],"version-history":[{"count":0,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/posts\/2239\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/media\/2235"}],"wp:attachment":[{"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/media?parent=2239"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/categories?post=2239"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xceed.com\/fr\/wp-json\/wp\/v2\/tags?post=2239"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}