Hi,I have a main MDI form and I have setup the following properties:
- RegistryRepositoryKey = HKEY_CURRENT_USER\Software\Progytech\Card Tracking System\MainDialog
- RememberFormLocation = True
- RememberFormMaximizedState = True
- RememberFormSize = True
Now when I open this form, it will update the registry as follow:
Without doing any change to the Main Form size, I close the application and run it again, then new values are being saved in the registry, causing the form to keep showing up with the wrong height value.
Notice that the SF_FormHeight and SF_FormY values are the one that changed without me resizing the form. Now this form has an UltraToolbarsManager acting as a RibbonBar and an UltraStatusBar which I believe may be causing this effect, since I do have other projects using the same Main Form without the infragistics controls and does not show this behavior.
I have the following code in the OnLoad method of the form:
Protected Overrides Sub OnLoad(ByVal e As System.EventArgs) MyBase.OnLoad(e) Dim applicationTitle As String = "Card Tracking System" Me.Text = String.Format("{0} ({1})", applicationTitle, My.Application.Info.Version.ToString) '-- Set the MDI backcolor to white _MDIClient.BackColor = System.Drawing.Color.White
'-- Add the MDI Me.Controls.Add(_MDIClient) '-- Create a handle to the CurrentUserChanged event to update the user information shown in main form. AddHandler MicroFour.StrataFrame.Security.SecurityBasics.CurrentUserChanged, AddressOf UpdateCurrentUserInfo Me.UpdateCurrentUserInfo() '-- Set the Connection label on the status bar Me.UltraStatusBar1.Panels("sbConnectedTo").Text = "Connected to: " & GetApplicationActiveConnectionStringTitle(ConnectionManager.ApplicationKey, "")End Sub
This Main Form was created based on the Main Form in the StrataFlix sample, you can see the MainFormSample.png file attached for a reference.
Is there any recommendation to solve this situation?