473,405 Members | 2,176 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,405 software developers and data experts.

Calling a Visual Basic Component Subroutine from ASP

Not sure if this is the right group for this but anyways...

I've got an ASP web application that uses a Visual Basic component to do
some work. I instantiate the component in asp and then attempt to call the
subroutine. The subroutine is actually invoked maybe 2 out of 10 times run.
What could possibly be the reason for this?? Why the inconsistency in
running the subroutine?

Cheers
Jul 19 '05 #1
4 4939
Do you have On Error Resume Next in the ASP?
Is the VB routine throwing an error.
Is the VB DLL compiled as 'Apartment Threaded' and 'Unattended Execution'?

How do you know that the routine is not being called? Have you run the DLL
in debug mode?

Chris.

"Michael Farber" <mf*****@iiac.com> wrote in message
news:Os**************@TK2MSFTNGP12.phx.gbl...
Not sure if this is the right group for this but anyways...

I've got an ASP web application that uses a Visual Basic component to do
some work. I instantiate the component in asp and then attempt to call the subroutine. The subroutine is actually invoked maybe 2 out of 10 times run. What could possibly be the reason for this?? Why the inconsistency in
running the subroutine?

Cheers

Jul 19 '05 #2
Hi, thanks for the reply.

1. ASP does have On Error Resume Next. I have disabled this to see what
happens. Nothing happens.
2. No errors are being thrown in VB
3. Apartment threaded

I have the component running in the VB debugger and breakpoints in the
subroutine are not being trapped. Breakpoints in other routines are
consistently trapped.

After a bunch of tries, the breakpoint is trapped and the subroutine runs as
it should. Very wierd.


"Chris Barber" <ch***@blue-canoe.co.uk.NOSPAM> wrote in message
news:el**************@TK2MSFTNGP12.phx.gbl...
Do you have On Error Resume Next in the ASP?
Is the VB routine throwing an error.
Is the VB DLL compiled as 'Apartment Threaded' and 'Unattended Execution'?

How do you know that the routine is not being called? Have you run the DLL
in debug mode?

Chris.

"Michael Farber" <mf*****@iiac.com> wrote in message
news:Os**************@TK2MSFTNGP12.phx.gbl...
Not sure if this is the right group for this but anyways...

I've got an ASP web application that uses a Visual Basic component to do
some work. I instantiate the component in asp and then attempt to call

the
subroutine. The subroutine is actually invoked maybe 2 out of 10 times

run.
What could possibly be the reason for this?? Why the inconsistency in
running the subroutine?

Cheers


Jul 19 '05 #3
Are you certain that the call is being made (eg. run the web ASP code in
debug as well)?
Maybe its in an IF statement that is not being entered or you have a url
misnamed?

I've *never* come across an ASP page calling a VB routine that does not at
least attempt the call and either throw an error in the ASP or in the VB.

Chris.
"Michael Farber" <mf*****@iiac.com> wrote in message
news:OJ**************@tk2msftngp13.phx.gbl...
Hi, thanks for the reply.

1. ASP does have On Error Resume Next. I have disabled this to see what
happens. Nothing happens.
2. No errors are being thrown in VB
3. Apartment threaded

I have the component running in the VB debugger and breakpoints in the
subroutine are not being trapped. Breakpoints in other routines are
consistently trapped.

After a bunch of tries, the breakpoint is trapped and the subroutine runs as it should. Very wierd.


"Chris Barber" <ch***@blue-canoe.co.uk.NOSPAM> wrote in message
news:el**************@TK2MSFTNGP12.phx.gbl...
Do you have On Error Resume Next in the ASP?
Is the VB routine throwing an error.
Is the VB DLL compiled as 'Apartment Threaded' and 'Unattended Execution'?
How do you know that the routine is not being called? Have you run the DLL in debug mode?

Chris.

"Michael Farber" <mf*****@iiac.com> wrote in message
news:Os**************@TK2MSFTNGP12.phx.gbl...
Not sure if this is the right group for this but anyways...

I've got an ASP web application that uses a Visual Basic component to do some work. I instantiate the component in asp and then attempt to
call the
subroutine. The subroutine is actually invoked maybe 2 out of 10
times run.
What could possibly be the reason for this?? Why the inconsistency in
running the subroutine?

Cheers



Jul 19 '05 #4
In article <el**************@TK2MSFTNGP12.phx.gbl>, chris@blue-
canoe.co.uk.NOSPAM says...
Do you have On Error Resume Next in the ASP?
Is the VB routine throwing an error.
Is the VB DLL compiled as 'Apartment Threaded' and 'Unattended Execution'?

How do you know that the routine is not being called? Have you run the DLL
in debug mode?

Chris.

"Michael Farber" <mf*****@iiac.com> wrote in message
news:Os**************@TK2MSFTNGP12.phx.gbl...
Not sure if this is the right group for this but anyways...

I've got an ASP web application that uses a Visual Basic component to do
some work. I instantiate the component in asp and then attempt to call

the
subroutine. The subroutine is actually invoked maybe 2 out of 10 times

run.
What could possibly be the reason for this?? Why the inconsistency in
running the subroutine?


Just a thought. You mention that you are running the code in VB debug
mode to test it. Is it possible you have the compiled DLL in memory as
well at the same time? Make sure you unregister the DLL (assuming you
are not using COM+) and reboot.

--

Remove NOT from email address to reply. AntiSpam in action.
Jul 19 '05 #5

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

Similar topics

3
by: Raja | last post by:
Dear Members, Has anyone used the Vector Draw (www.vdraw.com) Component in Visual Basic. I need to create an application to be able to draw the plan view of a building. Any help in this regard...
54
by: seberino | last post by:
Many people I know ask why Python does slicing the way it does..... Can anyone /please/ give me a good defense/justification??? I'm referring to why mystring gives me elements 0, 1, 2 and 3...
4
by: Cyde Weys | last post by:
I'm currently working on converting a simulator program from Visual Basic 6.0 to Visual C++ .NET. I've figured out most of the stuff, but there's still one thing I haven't gotten to and I've never...
12
by: Bigdakine | last post by:
I don't know if this is the right forum for this, and if not please suggest one which fits. I have to call a fortran sub routine from a C main program. The fortran subroutine statement is ...
5
by: Amit | last post by:
I tried calling a subroutine in a fortran module from C ,but couldn't.I always get the error: undefined reference in the main.o file (main is in C calling the subroutine). for calling the...
2
by: Ray J. | last post by:
I have a C++ program written and compiled on Solaris 8 with gcc. With gcc lets me compile fortran code along with the C++ program to be able to call the fortran code as a subroutine. The...
11
by: RichN | last post by:
I am developing a c program in Visual Studio .NET 2003. I also have an Intel(R) Fortran compiler for MVS .NET My fortran sourcecode already existed. I started a new fortran project and chose to...
3
by: Alpesh Parmar | last post by:
Hi Frens, I've made a class library project in Visual Basic using visual studio.net 2003. Now after i m done I copy the dll from the \bin dir. of this project to my web application project using...
9
by: Terry | last post by:
I am trying to test out the ability of VB6 (VBA access) to instanciate a VB.net Object and call its methods. I came accross the following article in my vs2005 help search:...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

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.