School Assignment? Project Due Tomorrow? Chat LIVE With A Programming Expert!
Welcome to Dream.In.Code
Become an Expert!

Join 340,079 Programmers for FREE! Get instant access to thousands of experts, tutorials, code snippets, and more! There are 4,787 people online right now. Registration is fast and FREE... Join Now!



System.Runtime.InteropServices.COMException (0x80040154): Class not

Page 1 of 1

System.Runtime.InteropServices.COMException (0x80040154): Class not System.Runtime.InteropServices.COMException (0x80040154): Class not Rate Topic: -----

#1 imesh  Icon User is offline

  • New D.I.C Head
  • Pip
  • Group: New Members
  • Posts: 1
  • Joined: 28-February 09


Dream Kudos: 0

Post icon  Posted 01 March 2009 - 12:10 AM

************** Exception Text **************
System.Runtime.InteropServices.COMException (0x80040154): Class not registered
   at System.Windows.Forms.AxHost.CreateInstance()
   at System.Windows.Forms.AxHost.GetOcxCreate()
   at System.Windows.Forms.AxHost.TransitionUpTo(Int32 state)
   at System.Windows.Forms.AxHost.CreateHandle()
   at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
   at System.Windows.Forms.AxHost.EndInit()
   at Stcock.frmDeleveryOrder.InitializeComponent()
   at Stcock.frmDeleveryOrder..ctor()
   at Stcock.frmMain.mnuDeliverOrder_Click(Object sender, EventArgs e)
   at System.Windows.Forms.MenuItem.onclick(EventArgs e)
   at System.Windows.Forms.MenuItemData.Execute()
   at System.Windows.Forms.Command.Invoke()
   at System.Windows.Forms.Control.WmCommand(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.ContainerControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.ControlNativewindow.OnMessage(Message& m)
   at System.Windows.Forms.ControlNativewindow.WndProc(Message& m)
   at System.Windows.Forms.Nativewindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


I have put the exe which is in bin folder to my client place. I have installed .net framework there. and some forms are working fine. But I 'm getting above error for some forms. it has specially status bar, flexgird. I have copied the AxInterop.MSFlexGridLib.dll and Interop.MSFlexGridLib.dll file in to the same place where the exe is.

Please Advice.
Imesh
Was This Post Helpful? 0
  • +
  • -


#2 PsychoCoder  Icon User is offline

  • apt-get install DIC.bin
  • Icon
  • View blog
  • Group: Admins
  • Posts: 16,211
  • Joined: 26-July 07


Dream Kudos: 12400

Expert In: VB, VB.Net, C#, SQL, ASP, ASP.Net, Web Development, HTML, CSS, Win32 API, Javascript, mySQL, J#, Boo.Net, jQuery

Posted 01 March 2009 - 12:47 AM

Well since you're programming VB.NET now, you should stay away from the legacy COM Controls and stick with the native .Net libraries, such as the DataGridView and other controls for displaying data in a tabular way. You could even look at the DataRepeater Control.

You could also use the ListBox Class and finally7 the Repeater Control.

All of which are excellent for displaying data in any number of formats, thus making your life easier than using old COM objects instead of the native libraries found in the .Net Framework.

Hope that helps :)
Was This Post Helpful? 0
  • +
  • -

#3 WinBase  Icon User is offline

  • D.I.C Head
  • PipPip
  • Group: Members
  • Posts: 93
  • Joined: 27-January 09


Dream Kudos: 0

Posted 01 March 2009 - 03:24 AM

imesh, i gotta agree with PsychoCoder, you should always use the new .NET equivalents instead of COM. i went through a period when i needed to quickly convert VB6 code and thought it would be quicker and easier to use the interops (to save me learning new stuff) but in the long run it just aint worth it, not only is the performance generally worse but it makes for messier installation programs & u aint advancing your knowledge, however there will be occasions when u have no choice but to use activex components, (such as hooking into MS office libraries), but its best to keep these to a minimum imho.

GL

Bob
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1


Fast Reply

  

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users



Live Help!

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter Fan Us On Facebook

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month