Sdk From A Web Service
Hi,
I am trying to run the Bartender SDK from a web service to generate label images. When i test this i get the follwoing error
Seagull.BarTender.Print.PrintEngineException: The BarTender engine could not be started. Possible reasons are:
1) BarTender is not properly installed.
2) BarTender is not properly registered on the computer (e.g bartend.exe /register).
3) There are too many process instances of BarTender running. Stop a few bartend.exe instances and try again. Also see SDK Engine.Start method documentation for information about how to allow more BarTender processes to run on your computer by increasing your "non-interactive" shared desktop heap. ---> System.UnauthorizedAccessException: Retrieving the COM class factory for component with CLSID {B9425246-4131-11D2-BE48-004005A04EDF} failed due to the following error: 80070005.
The error is being thrown on execution of the line
Dim btEngine As New Seagull.BarTender.Print.Engine(True)
i run almost identitcal code from a windows forms app and it generates fine. the only differences are the places it looks for files in is different between the two app(web service passed in, windows forms hard coded). There are no other bartend.exe apps running on the pc, as i checked task manager.
Is there anything i need to take into consideration to do this via a web service?
Thanks
Doug
-
What exact Edition, Version and Build of BarTender is in use?
If a Trial copy of BarTender is in use, do you've Trial days remaining?
0 -
Legacy Poster
★ BarTender Hero ★
Version is 9.2 SR2
build 2674
Enterprise Print Server edition
0 -
Michael Toupin (mtoupin
★ BarTender Hero ★
Is BarTender installed and licensed on the web server?
0 -
Legacy Poster
★ BarTender Hero ★
Yes, i am testing the web service and the win forms app on the same machine
0 -
You said: "the only differences are the places it looks for files in is different between the two app(web service passed in, windows forms hard coded)."
Does this occur before or after calling "Dim btEngine As New Seagull.BarTender.Print.Engine(True)"? What files are you refering to exactly, the BarTender documents (.btw).
Perhaps it would be good if you take a look at running our Web Label Print Sample, which can be found under "C:\Program Files (x86)\Seagull\BarTender Suite\SDK\Print Server SDK Samples\WebLabelPrint". Instructions on how to configure it are found in BarTender's Help, under the "Automating BarTender > Automation with the BarTender .NET SDKs > BarTender .NET Print Server SDK > Samples" topic.
0 -
Legacy Poster
★ BarTender Hero ★
the files that i am specifying are the output path and filename of the label preview that i am trying to generate. the error occurs on the line Dim btEngine As New Seagull.BarTender.Print.Engine(True), not before but right on the execution of that line. I will try to locate the sample.
0 -
Legacy Poster
★ BarTender Hero ★
After review of things i was able to determine that what i was missing was the line as follows in the web.config file
<identity impersonate="true" username="domain\user" password="thepassword"/>
thanks
doug
0 -
Thanks Doug for the feedback.
If your web application would be running under its own IIS application pool, I believe that this line will not be required.
0
請登入寫評論。
評論
8 條評論