AxInterop.Microsoft.Vbe.Interop.Forms is not working

Premashis Das 0 Reputation points
2023-07-31T04:32:33.5766667+00:00

Hi,

I have used following code in our VB .Net Project Visual Studio 2017. Dll ".Forms.AxFrame.dll" added in Referance.

Public WithEvents Frame5 As AxMicrosoft.Vbe.Interop.Forms.AxFrame
----------
Me.Frame5 = New AxMicrosoft.Vbe.Interop.Forms.AxFrame()
----------
CType(Me.Frame5, System.ComponentModel.ISupportInitialize).BeginInit()
----------
''Frame5
Me.Frame5.Location = New System.Drawing.Point(168, 64)
Me.Frame5.Name = "Frame5"
Me.Frame5.OcxState = CType(resources.GetObject("Frame5.OcxState"), System.Windows.Forms.AxHost.State)
Me.Frame5.Size = New System.Drawing.Size(30, 5)
Me.Frame5.TabIndex = 33
----------
Me.Controls.Add(Me.Frame5)
----------
CType(Me.Frame5, System.ComponentModel.ISupportInitialize).EndInit()
----------
When I am trying to debug above code it is showing following Error:

System.Runtime.InteropServices.COMException
  HResult=0x80040154
  Message=Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
  Source=System.Windows.Forms
  StackTrace:
   at System.Windows.Forms.UnsafeNativeMethods.CoCreateInstance(Guid& clsid, Object punkOuter, Int32 context, Guid& iid)
   at System.Windows.Forms.AxHost.CreateWithLicense(String license, Guid clsid)
   at System.Windows.Forms.AxHost.CreateInstanceCore(Guid clsid)
   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.Control.CreateControl()
   at System.Windows.Forms.Control.WmShowWindow(Message& m)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
   at System.Windows.Forms.Form.WmShowWindow(Message& m)
   at System.Windows.Forms.Form.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
System.InvalidOperationException
  HResult=0x80131509

  Message=An error occurred creating the form. See Exception.InnerException for details.  The error is: Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
  Source=eEditor
  StackTrace:
   at eEditorDLA.My.MyProject.MyForms.Create__Instance__[T](T Instance) in :line 190
   at eEditorDLA.My.MyProject.MyForms.get_frmMain()
   at eEditorDLA.frmMain.Main()
Inner Exception 1:
COMException: Class not registered (Exception from HRESULT: 0x80040154 (REGDB_E_CLASSNOTREG))
VB
VB
An object-oriented programming language developed by Microsoft that is implemented on the .NET Framework. Previously known as Visual Basic .NET.
2,508 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Premashis Das 0 Reputation points
    2023-08-01T14:02:28.05+00:00

    Not able to registerAxMicrosoft-Registration

    Please suggest me what to do next.

    0 comments No comments

  2. Castorix31 80,916 Reputation points
    2023-08-02T12:10:27.8066667+00:00

    AxInterop.Microsoft.Vbe.Interop.Forms.dll is an assembly and is not registered with RegSvr32

    If it is an old project, did you try to remove/add the Reference ?

    I just downloaded it from Google, then I added it as Reference (in a new VS 2022 project) and it worked, the Frame was created :

    User's image

    User's image

    0 comments No comments