Star - Discover Gists · GitHub
Có thể bạn quan tâm
Skip to content All gists Back to GitHub Sign in Sign up Sign in Sign up You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert {{ message }}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment You can’t perform that action at this time.
Instantly share code, notes, and snippets.
groupdocs-com-kb/How to Convert SVG to PNG using C#.cs Last active May 21, 2022 08:12 Show Gist options- Download ZIP
- Star ( ) You must be signed in to star a gist
- Fork ( ) You must be signed in to fork a gist
- Embed Clone this repository at <script src="https://gist.github.com/groupdocs-com-kb/c2e40e87f27c5cb392d4a92569a68578.js"></script>
- Save groupdocs-com-kb/c2e40e87f27c5cb392d4a92569a68578 to your computer and use it in GitHub Desktop.
using System; |
using GroupDocs.Conversion.Options.Convert; |
namespace ConvertSvgToPngUsingCSharp |
{ |
class Program |
{ |
public static void Main(string[] args) // Main function to convert SVG to PNG using C# |
{ |
// Remove the watermark in output PNG by adding license |
string licensePath = "GroupDocs.Conversion.lic"; |
GroupDocs.Conversion.License lic = new GroupDocs.Conversion.License(); |
lic.SetLicense(licensePath); |
// Load the source SVG file for conversion to PNG |
var converter = new GroupDocs.Conversion.Converter("sample.svg"); |
// Set the convert options for the output PNG |
ImageConvertOptions convertOptions = new ImageConvertOptions { Format = GroupDocs.Conversion.FileTypes.ImageFileType.Png }; |
// Convert and save the SVG in PNG format |
converter.Convert("converted.png", convertOptions); |
Console.WriteLine("Done"); |
} |
} |
} |
Từ khóa » Svg To Png C#
-
Converting SVG To PNG Using C# [closed] - Stack Overflow
-
C# Convert SVG To PNG, JPEG, BMP, TIFF, GIF - Aspose Blog
-
Convert SVG To PNG | C# | Documentation
-
[Fork] Convert SVG To PNG Using NuGet Package Svg -.NET Fiddle
-
Convert SVG Files To PNG Or JPEG Using .NET - Meziantou's Blog
-
Converting Svg File To Image - MSDN - Microsoft
-
How To Convert SVG To PNG In C# | SVG To PNG Online
-
How To Convert SVG To PNG | Telerik Reporting
-
Svg To Image Converter Using C# .NET - YouTube
-
Convert SVG To PNG Or JPEG Using C# In ASP.Net - ASPsnippets
-
C# Program To Convert SVG Image To PNG ... - Coding Diksha
-
C# Program To Convert SVG Image To PNG Converter GUI Desktop ...
-
SVG To PNG Converter In C# - Conversion - GroupDocs
-
Converting SVG To PNG Using C# - Newbedev