473,408 Members | 2,402 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,408 software developers and data experts.

Use Ghostscript from C#

Hello,
Can someone tell me if it is possible to use Ghostscript from C#?
I would like to create thumbnails from several PDFs.

TIA
May 10 '06 #1
4 6608
Sjaakie <ke**@secret.it> wrote:
Can someone tell me if it is possible to use Ghostscript from C#?
I would like to create thumbnails from several PDFs.


You can always invoke the gs.exe process, I suppose.

-- Barry
May 10 '06 #2
Barry Kelly schreef:
Sjaakie <ke**@secret.it> wrote:
Can someone tell me if it is possible to use Ghostscript from C#?
I would like to create thumbnails from several PDFs.


You can always invoke the gs.exe process, I suppose.

-- Barry


Already thought of that, but I'd like to put the PDF-to-JPG result
directly into an Image object in order to customize the output.

If there's no other solution that using gs.exe and reading the created
file from disk, I'll try your solution.

cheers
May 10 '06 #3
I use GS quite a lot for presentations and the only way I've found is to
start a process with the correct command line and then load the image again
later. To save on having to store a million images use the GetTempFileneme
method and delete it after you load it via a stream.

--
Bob Powell [MVP]
Visual C#, System.Drawing

Ramuseco Limited .NET consulting
http://www.ramuseco.com

Find great Windows Forms articles in Windows Forms Tips and Tricks
http://www.bobpowell.net/tipstricks.htm

Answer those GDI+ questions with the GDI+ FAQ
http://www.bobpowell.net/faqmain.htm

All new articles provide code in C# and VB.NET.
Subscribe to the RSS feeds provided and never miss a new article.

"Sjaakie" <ke**@secret.it> wrote in message
news:44***********************@news.xs4all.nl...
Barry Kelly schreef:
Sjaakie <ke**@secret.it> wrote:
Can someone tell me if it is possible to use Ghostscript from C#?
I would like to create thumbnails from several PDFs.


You can always invoke the gs.exe process, I suppose.

-- Barry


Already thought of that, but I'd like to put the PDF-to-JPG result
directly into an Image object in order to customize the output.

If there's no other solution that using gs.exe and reading the created
file from disk, I'll try your solution.

cheers

May 10 '06 #4
Bob Powell [MVP] schreef:
I use GS quite a lot for presentations and the only way I've found is to
start a process with the correct command line and then load the image again
later. To save on having to store a million images use the GetTempFileneme
method and delete it after you load it via a stream.


Ok, thanks, I'll proceed with that method then.
May 11 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Chris Jankowski | last post by:
Hi all, I am still fairly new to the Python community and world of Python programming. I am having some trouble changing the output directory when I call Ghostscript. Any sugguestions would be...
1
by: Adam Twardoch | last post by:
I've written a simple commanline wrapper for calling GhostScript from Python. It uses os.system under Windows and os.popen under unixes. The call looks basically like this: gs -q -dNODISPLAY...
1
by: tc | last post by:
Does GhostScript provide any library so that we can reference it in our C# project to programmatically handle printing of ps / pdf files? I have tried to use the gs command (call by process) in...
0
by: Roel | last post by:
Hello I try to pint a pdf from a .net webapplication. Therefore I use GhostScript. When I execute the following line via "start - run", the pdf is printed correctly:...
1
by: Christopher Campbell | last post by:
I am calling Ghostscript 8.00 from and ASP.NET application (VB) to create ..JPG thumbnails of .PDF files. I have created a class module for Ghostscript and I am creating an instance of the class...
2
by: SpamProof | last post by:
I'm using the ps2pdf.bat file that ghostscript provides through my vb.net code to convert word documents to pdf. After each conversion, a winword process is left runnning in the task manager. ...
0
by: Sjaakie | last post by:
Is there a Ghostscript ASP.NET wrapper available? Preferrably with an example... Thanks
2
by: defcon8 | last post by:
Does a ghostscript interface for python exist? I have searched google quite a bit and all I have been able to find are command line hacks from within python. Thanks in advance for any useful help.
18
Ciary
by: Ciary | last post by:
hi all, it's my second question of today but since i'm stuck with this problem, i'm going to ask it anyway. i'm trying to convert an uploaded pdf file to a jpg, gif or png file. i want to use it...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.