Reply to topic  [ 2 posts ] 
Win32Exception (0x80004005): Class already exists 
Author Message

Joined: Sun Apr 27, 2008 4:40 pm
Posts: 1
Reply with quote
Post Win32Exception (0x80004005): Class already exists
Hello,

I'm evaluating the EasyXLS and sometimes the following error occurs:

Line 75: Dim xls As New ExcelDocument
Line 76: Dim xlsWorksheet As New ExcelWorksheet("CLIENTES")
Line 77: xls.easy_addWorksheet(xlsWorksheet)

Source File: C:\sites\NetStoreManager2007\web\IEclientes.aspx.vb Line: 76

Stack Trace:

[Win32Exception (0x80004005): Class already exists]
System.Windows.Forms.WindowClass.RegisterClass() +1091
System.Windows.Forms.WindowClass.Create(String className, Int32 classStyle) +181
System.Windows.Forms.NativeWindow.CreateHandle(CreateParams cp) +215
System.Windows.Forms.Control.CreateHandle() +213
System.Windows.Forms.Control.get_Handle() +60
System.Windows.Forms.Control.CreateHandle() +200
System.Windows.Forms.Control.get_Handle() +60
System.Windows.Forms.Control.CreateGraphicsInternal() +5
System.Windows.Forms.Control.CreateGraphics() +36
EasyXLS.Util.Conversion.b..cctor() +202

[TypeInitializationException: The type initializer for "EasyXLS.Util.Conversion.b" threw an exception.]
EasyXLS.Util.Conversion.b.a(Int32 A_0, Int16[] A_1, String A_2, Boolean A_3) +20
EasyXLS.ExcelSheet.setSheetName(String sheetName) +602
EasyXLS.ExcelSheet..ctor() +136
EasyXLS.ExcelWorksheet..ctor(String sheetName) +46
IEclientes.exportarBtn_Click(Object sender, EventArgs e) in C:\sites\NetStoreManager2007\web\IEclientes.aspx.vb:76
System.Web.UI.WebControls.Button.OnClick(EventArgs e) +108
PeterBlum.VAM.Button.OnClick(EventArgs pE) +71
System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +57
System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +18
System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +33
System.Web.UI.Page.ProcessRequestMain() +1292



The vb source is:

Code:
Private Sub exportarBtn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles exportarBtn.Click

Dim xls As New ExcelDocument

Dim xlsWorksheet As New ExcelWorksheet("CLIENTES")

xls.easy_addWorksheet(xlsWorksheet)

xlsWorksheet.easy_insertDataSet(GetClientesDataset, 0, 0, True)

Try
   xls.easy_WriteXLSFile(Server.MapPath("files/clientesLoja.xls"))
Catch exc As Exception
   exportMsg.Text = exc.Message
End Try

xls.Dispose()

End Sub



What I am doing wrong?

Regards,
Newton


Sun Apr 27, 2008 5:02 pm
Profile

Joined: Fri Feb 03, 2006 12:23 pm
Posts: 189
Location: Brasov, Romania
Reply with quote
Post 
This is a .Net Framework defect. It is a recognized Microsoft bug and it occurs because a form may not be correctly disposed. It usually happens for a web application and only in the Visual Studio .NET development environment. Restarting IIS solves the problem. Please install the latest patch for .NET Framework. This may fix your problem.


Tue May 06, 2008 3:16 am
Profile WWW
Display posts from previous:  Sort by  
Reply to topic   [ 2 posts ] 

Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by STSoftware for PTF.