Discussion:
MEMBER NOT FOUND" error HRESULT : 0x80020003 (DISP_E_MEMBERNOTFOUN
(too old to reply)
Pallvi
2007-12-27 06:52:00 UTC
Permalink
Hello friends,

I am facing this problem("MEMBER NOT FOUND" error HRESULT : 0x80020003
(DISP_E_MEMBERNOTFOUND) ) in Visual Basic 2005 (i.e. VB .NET) for the fourth
statement(ObjWb = AppXls.Workbooks.Add) in the following code. I searched ,
but couldn't get relevent solution.

Imports Excel

Dim AppXls As Excel.Application
Dim ObjWb As Excel.Workbook

AppXls = CreateObject("Excel.Application")
ObjWb = AppXls.Workbooks.Add
ObjWb.Worksheets().Items("Sheet1").range("A1").value = "1"

ObjWb.SaveAs("C\pp\test.xls")
ObjWb.Close()
AppXls.Quit()
Could anybody plz help me? Would be appriciable.
Thanks and regards.
Family Tree Mike
2007-12-27 11:46:02 UTC
Permalink
Post by Pallvi
Hello friends,
I am facing this problem("MEMBER NOT FOUND" error HRESULT : 0x80020003
(DISP_E_MEMBERNOTFOUND) ) in Visual Basic 2005 (i.e. VB .NET) for the fourth
statement(ObjWb = AppXls.Workbooks.Add) in the following code. I searched ,
but couldn't get relevent solution.
Imports Excel
Dim AppXls As Excel.Application
Dim ObjWb As Excel.Workbook
AppXls = CreateObject("Excel.Application")
ObjWb = AppXls.Workbooks.Add
All the examples I have found show:
ObjWb = AppXls.Workbooks.Add(true)
Post by Pallvi
ObjWb.Worksheets().Items("Sheet1").range("A1").value = "1"
ObjWb.SaveAs("C\pp\test.xls")
ObjWb.Close()
AppXls.Quit()
Could anybody plz help me? Would be appriciable.
Thanks and regards.
Loading...