teixeira Posted May 25, 2005 Posted May 25, 2005 Hi all, Does anyone knows how can I avoid a messagebox to appear? I mean, i've an active-x that check the lpt1 port to see if the hardlock is present, and if not it displays an messagebox, Is it possible to kill this messagebox? Thanks in advance, Teixeira Quote
EFileTahi-A Posted May 31, 2005 Posted May 31, 2005 What kind of message is that? An error message? If so you, you could add a "TRY - CATCH" block to prevent this message from appearing... PS: Como está o tempo por ai? ;) Quote
teixeira Posted May 31, 2005 Author Posted May 31, 2005 Hey neighbour, About the suggestion it would work fine if this messagebox was generated by an error caught by the jit, but this is an messagebox that appears because the app uses an activeX that has an hardware Key, and for this app we don't need to use the main features of the AX , so the Hardlock isn't necessary, anyway we need to access to some functions that the AX has, and it's no good the message box "Please Check Printer Port... Hardlock not present" appears, so I tried to implement a Timer with Interval Property set to 1 ms and in the Timer_Tick() I use the SendKeys Method and I send an ENTER, and the message box disapears. - If U need to use some thing like this try a timer, in a fast computer I goes very good, no msgbox seen ;-) Sobre o tempo, tá mesmo muito calor.... estou a 20 km da praia mais perto e tá mesmo a apetecer, se não fosse o Ar Condicionado, não sei não..... Umas cervejinhas e tal... já marchava.... LOL ;-) Fico contente por ver pessoal de Portugal por aqui mas fico triste por outro lado, por não termos uma comunidade .NET tão activa como por exemplo esta. Mas devo destacar os esforços feitos pela comunidade PONTONETPT em levar pra frente o peso TUGA.NET ;-) Cumps, Greetings, Teixeira Quote
EFileTahi-A Posted May 31, 2005 Posted May 31, 2005 My bad, yes, the TRY - CATCH block is totaly useless for your problem. Anyway I do must admit that you found and interesting and clever way of walking around the problem. All in all I wish I could have more skills to help you out... PS: Temos comunidade .NET em tuguês? Nem sabia :) Quote
teixeira Posted May 31, 2005 Author Posted May 31, 2005 Skills are something that we continuously construct.... with the help of the good people that doesn't matters in share the knowledge with the others. :) PS. http://www.pontonetpt.com Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.