Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to Unregister OCX
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
01659093
Message ID:
01659106
Vues:
43
>Hi,
>
>I use DBITech List bar OCX control at the top of the application. That is, I have a VFP toolbar which includes the OCX control. The problem is when some customers do not register the OCX and run the app. This caused the error
>
>OLE error code 0x80040154: Class not registered
>
>So, I need to unregister this OCX on my development PC, so that I can test and come up with a strategy to show a message instead of an error. The only place where I see on my PC this ocx (ctlstbar.ocx) is where I keep the source of the files.
>Where and how do I un-register it?
>
>TIA

I tried to unregister the toolbar OCX - no error on un-registerng. But my VFP 9 app that uses this OCX still works. So, I can't test a condition when the OCX is not registered.

So, my question is, will TRY CATCH around the line that instantiates this toolbar show the error in CATCH?

My line of code is as follows (including the TRY CATCH that I am thinking of adding:
TRY
    oApp.oToolBar = createobject( 'application_list_bar', cParameter1, cParameter2 ) 	
CATCH to oError
   Messagebox("Problem loading the list bar.  Error: " + oError.message )
ENDTRY
Note that currently I don't have the TRY/CATCH but before I add it, I want to be sure that I won't break something.

TIA
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform