Prev: My Apps Died
Next: Help 2 file conversion
From: Bee on 17 Apr 2010 20:03 So am I correct that based on the lack of response that I cannot determine what caused the error? i.e. FSO vs something else? Does that mean that I have to put in line numbers at all possible places so I will know what code did it or put a wrapper around each call? Educate me please. "Bee" wrote: > Hope this does not double post. I waited and saw nothing post. > I had trouble getting into the MS website and loggin in. > THis time it was easy. Fortunately I made a Notepad copy before hitting > Post. Anyway ... > > I installed camera software from Trendnet that did not work so after an hour > on the phoine with their tech support i uninstalled it from my Vista PC. > Now many of my VB6 apps crash on startup. > > Question has two parts. > (1) i opend the IDE to find that one of the apps loaded fine but crashed on > a line using FSO. > So I looked at the References and found that the Microsoft Scripting Runtime > was checked but down below there was no path or file. > I believe that means that the file is gone, probably removed by the Trendnet > uninstall. Thanks a lot TrendNet. > > So, where do I get this file and how do I put it back in? > I do not remember the name of the file either. > > (2) other than trapping error 429 what is the best way to handle this type > of problem. the messages says ActiveX component can't create object. > > Is there a way to get the name of the object so an error message can say > what is missing? >
From: Bee on 17 Apr 2010 20:05 P.S. what was very confusing was that there was a post with a date of 4/20/2010. "Bee" wrote: > Hope this does not double post. I waited and saw nothing post. > I had trouble getting into the MS website and loggin in. > THis time it was easy. Fortunately I made a Notepad copy before hitting > Post. Anyway ... > > I installed camera software from Trendnet that did not work so after an hour > on the phoine with their tech support i uninstalled it from my Vista PC. > Now many of my VB6 apps crash on startup. > > Question has two parts. > (1) i opend the IDE to find that one of the apps loaded fine but crashed on > a line using FSO. > So I looked at the References and found that the Microsoft Scripting Runtime > was checked but down below there was no path or file. > I believe that means that the file is gone, probably removed by the Trendnet > uninstall. Thanks a lot TrendNet. > > So, where do I get this file and how do I put it back in? > I do not remember the name of the file either. > > (2) other than trapping error 429 what is the best way to handle this type > of problem. the messages says ActiveX component can't create object. > > Is there a way to get the name of the object so an error message can say > what is missing? >
From: GS on 17 Apr 2010 22:32 Bee presented the following explanation : > I would stop using FSO if I knew how. > I have written around almost all FSO handy code but there are parts that I > cannot do without. > FSO very quickly gets drives and folders with all the associated properties. > I have also found cases where i think that the Delete API does not work and > the FSO delete file does work. You might do yourself some good if you F1 and look up the following VB statements: ChDir ChDrive FileCopy Kill Name MkDir RmDir You might also want to look at using WMI to work with drives and their properties (and tonnes of other system info). There's so much more WMI can do over FSO, and you'll find lots of code examples here for this. HTH Garry
From: ralph on 18 Apr 2010 10:40 On Sat, 17 Apr 2010 17:03:01 -0700, Bee <Bee(a)discussions.microsoft.com> wrote: >So am I correct that based on the lack of response that I cannot determine >what caused the error? >i.e. FSO vs something else? >Does that mean that I have to put in line numbers at all possible places so >I will know what code did it or put a wrapper around each call? >Educate me please. > > ... >> >> (2) other than trapping error 429 what is the best way to handle this type >> of problem. the messages says ActiveX component can't create object. >> >> Is there a way to get the name of the object so an error message can say >> what is missing? >> Normal VB Error Handling can be used to catch this error. If using CreateObject or GetObject the parameter passed is a string, the AppId or ProgId. Error handling will not report the parameter. So to provide better information you can simply store the AppId to a string variable and use that variable in both the call and the Error Routine. If you are using New via a Reference, Error Messages can report the component on initial launch However, be aware that Windows loader (not VB's fault) will only report the top or initial component it could not "find" or "load", not the name of any dependent components that may cause the failure. -ralph
From: Karl E. Peterson on 19 Apr 2010 12:48
Bee wrote on 4/17/2010 : > I would stop using FSO if I knew how. > I have written around almost all FSO handy code but there are parts that I > cannot do without. So ask! (Google first, of course.) > FSO very quickly gets drives and folders with all the associated properties. See http://vb.mvps.org/samples/FileInfo and http://vb.mvps.org/samples/DrvInfo, then. > I have also found cases where i think that the Delete API does not work and > the FSO delete file does work. Such as? -- ..NET: It's About Trust! http://vfred.mvps.org |