Hi
i have .NET app wrotten in VB.NET which uses Access COM object through
Interop ... on my machine i have Access Xp installed (version 10) and all
runs perfectly, however when i run this application on machine with Access
2000 (version 9) installed there is some weird behaviour :
accessobj = New Access.Application
MsgBox(accessobj.ProductCode) 'runs OK
MsgBox(accessobj.Version) ' Null Pointer Exception !
why .Version gives Null Pointer Exception when .ProductCode runs OK ???? ...
i'm copying generated by VS.NET interop dlls (i'm not using Office XP PIAs,
because i don't want my app to be version specific)
to the .exe directory on target machine ...
here is part of Interop.Access.dll MANIFEST :
.assembly Interop.Access
{
.custom instance void
[mscorlib]System.Runtime.InteropServices.ImportedFromTypeLibAttribute::.ctor
(string) = ( 01 00 06 41 63 63 65 73 73 00 00 ) //
...Access..
.custom instance void
[mscorlib]System.Runtime.InteropServices.GuidAttribute::.ctor(string) = ( 01
00 24 34 61 66 66 63 39 61 30 2D 35 66 39 39 // ..$4affc9a0-5f99
2D 31 30 31 62 2D 61 66 34 65 2D 30 30 61 61 30 // -101b-af4e-00aa0
30 33 66 30 66 30 37 00 00 ) // 03f0f07..
.hash algorithm 0x00008004
.ver 9:0:0:0
}
.module Access.dll
// MVID: {0967E183-881C-4032-BAA3-E2CCA1196A2B}
.imagebase 0x00400000
.subsystem 0x00000003
.file alignment 4096
.corflags 0x00000001
// Image base: 0x06ef0000
any help ... ?
regards, Konrad
Konrad Rotuski - 05 Jul 2004 10:50 GMT
> accessobj = New Access.Application
> MsgBox(accessobj.ProductCode) 'runs OK
> MsgBox(accessobj.Version) ' Null Pointer Exception !
this one is solved .. ver 9 of Access COM interfaces does not have
Application.Version member