In my code bellow, only get err.number (-2147024894, 0x80070002), the
err.Description is empty.
dim objComponent
On Error Resume Next
Set objComponent =
CreateObject("VBNET.HowTo.CreateEnterpriseServicesComponents.Supplier")
if Err then
msgbox(Err.number & ":" & Err.Description)
End if
If the Description property of the Err object is blank, there is no way to
retrieve it. You might check the Source property of the Err object. That's
the only other information I know of.
--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--
The Err.Source is blank as well. Would you know why they are blank?
Perhaps in your case the require object is installed on your machine, but it
is not designed to be accessed by a script so no error information is
returned. Just a guess.
--
Richard Mueller
Microsoft MVP Scripting and ADSI
Hilltop Lab - http://www.rlmueller.net
--
"Andrew HUANG" <Andre...@discussions.microsoft.com> wrote in message
news:ECCF8F89-51DF-4B25...@microsoft.com...
If error description is empty then likely because the text
isn't promoted by the raising component or because no text is
defined, which is not actually unusual.
The err-code 0x80070002 is the HRESULT COR_E_FILENOTFOUND
which maps to the Win32-error ERROR_FILE_NOT_FOUND and of
course means "file not found".
It doesn't say file isn't found of course ;-)
MfG,
Alex
Should read
It doesn't say, which file isn't found of course ;-)
Maybe the component
"VBNET.HowTo.CreateEnterpriseServicesComponents.Supplier"
isn't installed properly. Or a resource it relies on is missing.
MfG,
Alex
You're right, the component didn't install properly.
But my question focus on how to get the error description, because some
error descriptions are blank. My work is just to find which component didn't
registered properly.
Regards,
-Andrew
If the description is blank, it is blank, so all you have is the number.
You can check the documentation, if there is one, for the number, or
google, where a convertion to hex is likely to return more hits.
Most common practice is to reinstall or at least reregister the
component and hope it'll fix it.
> My work is just to find which component didn't
> registered properly.
>
Probably the one that goes by the ProgID
"VBNET.HowTo.CreateEnterpriseServicesComponents.Supplier"
or did i miss something?
MfG,
Alex