Re: API calls fail in ASP.Net
From: bruce barker (nospam_brubar_at_safeco.com)
Date: 01/06/05
- Next message: bruce barker: "Re: Zip File Download Error!!!"
- Previous message: tshad: "Re: Set dropdownlist from static data"
- In reply to: howard dierking: "API calls fail in ASP.Net"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 6 Jan 2005 15:23:29 -0800
the library may not be thread safe, which is required for asp.net. also
notmally asp.net does not have access to c:\, so it may be a permission
problem.
-- bruce (sqlwork.com)
"howard dierking" <howarddierking@discussions.microsoft.com> wrote in
message news:3886180B-BBF6-425A-8707-A1C40CC8C1A3@microsoft.com...
| I have an unmanaged library that i'm using to generate a .tif image from a
| .pdf file. When I run the following code in a console application,
| everything works fine. However, when I run it from ASP.Net, I get a stack
| overflow exception. If anything, I would have expected a CAS exception -
but
| am stumped as to the stack overflow exception. Below is the code used to
| call the native API.
|
| TIA,
|
| _howard
|
| Private Declare Function SetXY Lib "CP2T.dll" (ByVal resx As Integer,
| ByVal resy As Integer) As Integer
| Private Declare Function SetBPP Lib "CP2T.dll" (ByVal bpp As Integer)
As
| Integer
| Private Declare Function SetCompress Lib "CP2T.dll" (ByVal compress As
| Integer) As Integer
| Private Declare Function SetSize Lib "CP2T.dll" (ByVal sizewidth As
| Integer, ByVal sizeheight As Integer) As Integer
| Private Declare Function PageRange Lib "CP2T.dll" (ByVal firstpage As
| Integer, ByVal lastpage As Integer) As Integer
| Private Declare Function Convert Lib "CP2T.dll" (ByVal srcPDF As
String,
| ByVal dstTIFF As String) As Integer
|
| ....
|
| Dim result As Integer
| Dim inputfile As String
| Dim outputfile As String
| result = SetXY(2 * 204, 2 * 98)
| result = SetSize(2 * 1728, 2 * 1051)
| 'Run the conversion
| inputfile = "c:\817.pdf"
| outputfile = "c:\817.tif"
| result = Convert(inputfile, outputfile)
- Next message: bruce barker: "Re: Zip File Download Error!!!"
- Previous message: tshad: "Re: Set dropdownlist from static data"
- In reply to: howard dierking: "API calls fail in ASP.Net"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|