An outgoing call cannot be made since the application is dispatching an input-synchronous call.

I have a visual basic.net program that prints two different labels to two Zebra printers. One of the labels prints fine. But the other label on and off throws an error.

Here is the error message:

An outgoing call cannot be made since the application is dispatching an input-synchronous call.

Here is where I get the error in VB program:

btApplicationRL = New BarTender.Application

Before this line I do a lot of database reads and writes. What should I do to fix the problem? And why am I getting this error? The other thing I dont understand is why I am getting the error sometimes and other times it works fine.

shamifAsked:
Who is Participating?
 
Vee_ModCommented:
Closed, 250 points refunded.
Vee_Mod
Community Support Moderator
0
 
multithreadingCommented:
Programmed directly, without using any third-party drivers, the Zebra works great. The problem isn't the printer, and it may not be your software. From your description and sample it sounds like the problem rests with the BarTender application itself. Your best bet would be to contact Seagull Scientific with this question.
0
 
shamifAuthor Commented:
I talked to Seagull tech support and their answer was we dont support automation. I can write to a small program just to print labels and it will work fine.

Now what I have done is put a button on the screen to manually print the label. So I clear the error, press the MANUALY PRINT LABEL button and will print the label fine.

But for some reason I cannot get it to print when I what it to print.
0
 
multithreadingCommented:
Bypass the Seagul driver. If you look at the underlying (Zebra) protocol, you will be amazed how simple it is.
0
 
shamifAuthor Commented:
I fix the problem. I called the first label pinting from one thred and other label printing from another thread and now the program works fine.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.