Solved

Call a dll function build with delphi from asp .net

Posted on 2008-10-22
2
345 Views
Last Modified: 2013-11-23
Hello.

I´m migrating a software build with delphi 7 to .net winforms and asp.

There are some cryptography and authentication issues that is really hard to port from delphi to .net so I decided to build a dll with some "service" functions.

The dll functions basically connect to a sql db using ado, retrieve and write some data (tadodataset, tadocommand).

To see if the dll is fully functional, I made a simple winform with some textboxes and buttons and call all those functions. All the functions are ok.

But when I use the same dll functions into an asp solution they doesnt work.

There are no error messages but the functions always return that an exception was catch by a Try-Except block.

Finally... the questions:
- is it possible to call this kind of dll function inside an asp project?
- why the functions are ok with the win application and fails with asp?

Thanks.
0
Comment
Question by:eduardopxavier
2 Comments
 
LVL 26

Accepted Solution

by:
Anurag Thakur earned 500 total points
ID: 22784485
asp.net normally run under aspnet use account which have very restricted access security wise where as the windows application runs under the user account who is currently logged in
you can overcome this by using impersonation following sample from Microsoft shows you how to do that
http://support.microsoft.com/kb/306158

also what exception you are getting will also be helpful
0
 

Author Closing Comment

by:eduardopxavier
ID: 31508957
ragi0017,

the functions started to work using impersonation with my user account (the same that runs the windows test).

Thanks.

Eduardo
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
The viewer will learn how to synchronize PHP projects with a remote server in NetBeans IDE 8.0 for Windows.
The viewer will learn how to use and create new code templates in NetBeans IDE 8.0 for Windows.

808 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question