The Microsoft Forms 2.0 Object Library is an external library (stored in FM20.DLL) used in Visual Basic 6 (VB6) primarily to provide enhanced user interface controls. While VB6 has its own native controls, this library is often used because it supports Unicode (UTF-16) and provides specific features like transparent backgrounds that standard VB6 controls lack. 🛠️ How to Add it to Your VB6 Project
You can add the library to your project through the following steps: Open your project in the VB6 IDE. Go to the Project menu and select References.
Scroll through the list and check Microsoft Forms 2.0 Object Library.
If it is not listed, click Browse and navigate to your System32 (32-bit Windows) or SysWOW64 (64-bit Windows) folder to find FM20.DLL.
💡 Pro Tip: Adding a UserForm to your project in the VB Editor will often add this reference automatically. 📦 Key Controls Included Why do I not see the Microsoft Forms 2.0 Object Library?
Limitations
- UserForm objects cannot be used as MDI children
- No native data binding (unlike VB6 controls)
- Some properties behave differently than standard VB6 controls
- Event signatures may differ from VB6 controls
Distribution & compatibility notes
- FM20.DLL is installed with Office and some Windows components; it is not officially redistributable with third-party apps.
- Dependency can cause deployment issues on machines without the DLL — consider using native VB6 controls or custom user controls for redistributable projects.
- Using Microsoft Forms controls in non-Office apps can create licensing or versioning mismatches.
Key Components
When you add a reference to Microsoft Forms 2.0 Object Library in VB6 (via Project → References), you gain access to several powerful objects and controls, including:
- UserForm – The container object (similar to a VB6 Form) but optimized for Office integration.
- Controls:
CommandButton
TextBox
MultiPage
TabStrip
CheckBox
OptionButton
ListBox
ComboBox
Image
SpinButton
ScrollBar
Label
Creating Controls at Runtime
Dim fm As MSForms.UserForm
Dim txtBox As MSForms.TextBox
Dim btn As MSForms.CommandButton
' Create UserForm
Set fm = New MSForms.UserForm
fm.Caption = "Dynamic Form"
fm.Width = 300
fm.Height = 200
' Add TextBox
Set txtBox = fm.Controls.Add("Forms.TextBox.1")
txtBox.Name = "txtInput"
txtBox.Width = 150
txtBox.Left = 20
txtBox.Top = 20
' Add CommandButton
Set btn = fm.Controls.Add("Forms.CommandButton.1")
btn.Caption = "Click Me"
btn.Width = 80
btn.Left = 20
btn.Top = 60
' Show form
fm.Show
Microsoft Forms 20 Object Library Vb6 =link= -
The Microsoft Forms 2.0 Object Library is an external library (stored in FM20.DLL) used in Visual Basic 6 (VB6) primarily to provide enhanced user interface controls. While VB6 has its own native controls, this library is often used because it supports Unicode (UTF-16) and provides specific features like transparent backgrounds that standard VB6 controls lack. 🛠️ How to Add it to Your VB6 Project
You can add the library to your project through the following steps: Open your project in the VB6 IDE. Go to the Project menu and select References.
Scroll through the list and check Microsoft Forms 2.0 Object Library.
If it is not listed, click Browse and navigate to your System32 (32-bit Windows) or SysWOW64 (64-bit Windows) folder to find FM20.DLL.
💡 Pro Tip: Adding a UserForm to your project in the VB Editor will often add this reference automatically. 📦 Key Controls Included Why do I not see the Microsoft Forms 2.0 Object Library?
Limitations
- UserForm objects cannot be used as MDI children
- No native data binding (unlike VB6 controls)
- Some properties behave differently than standard VB6 controls
- Event signatures may differ from VB6 controls
Distribution & compatibility notes
- FM20.DLL is installed with Office and some Windows components; it is not officially redistributable with third-party apps.
- Dependency can cause deployment issues on machines without the DLL — consider using native VB6 controls or custom user controls for redistributable projects.
- Using Microsoft Forms controls in non-Office apps can create licensing or versioning mismatches.
Key Components
When you add a reference to Microsoft Forms 2.0 Object Library in VB6 (via Project → References), you gain access to several powerful objects and controls, including:
- UserForm – The container object (similar to a VB6 Form) but optimized for Office integration.
- Controls:
CommandButton
TextBox
MultiPage
TabStrip
CheckBox
OptionButton
ListBox
ComboBox
Image
SpinButton
ScrollBar
Label
Creating Controls at Runtime
Dim fm As MSForms.UserForm
Dim txtBox As MSForms.TextBox
Dim btn As MSForms.CommandButton
' Create UserForm
Set fm = New MSForms.UserForm
fm.Caption = "Dynamic Form"
fm.Width = 300
fm.Height = 200
' Add TextBox
Set txtBox = fm.Controls.Add("Forms.TextBox.1")
txtBox.Name = "txtInput"
txtBox.Width = 150
txtBox.Left = 20
txtBox.Top = 20
' Add CommandButton
Set btn = fm.Controls.Add("Forms.CommandButton.1")
btn.Caption = "Click Me"
btn.Width = 80
btn.Left = 20
btn.Top = 60
' Show form
fm.Show