Message 1 of 19
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello together,
I have a form which I open with an add-in. When the user trys to open the form again and the form is open and minimized the form should came back to it's original size and normal.
Public Function FormIsLoaded(ByVal sName As String) As Boolean Dim bResult As Boolean = False ' alle geöffneten Forms durchlauden For Each oForm As Form In System.Windows.Forms.Application.OpenForms If oForm.Name.ToLower = sName.ToLower Then bResult = True : Exit For End If Next Return (bResult) End Function
Private Sub oButtonDefinition287_Vault_OnExecute(Context As NameValueMap) Handles oButtonDefinition287_Vault.OnExecute Dim MyLocalForm As New Form_Vault If Not FormIsLoaded("Form_Vault") Then MyLocalForm.Show(New WindowWrapper(m_inventorApplication.MainFrameHWND)) 'Das Form wird an das Fenster von Inventor gebunden Else ShowWindow(MyLocalForm.WindowState, SHOW_WINDOW.SW_NORMAL) End If End Sub
How could I do this?
Thanks
Georg
Solved! Go to Solution.