我从另一个代码编写器继承了一个项目。在项目中这段代码:
Dim culture_info As 新 System.Globalization.CultureInfo(locale_name) Dim manager As New ComponentResourceManager(form_cur。 GetType ) manager.ApplyResources(form_cur, $ this,culture_info)导致调整大小的主窗体(变小)。 我知道这与表单的原始大小有关。但是,当我在派生的新项目上实现此方法时,主窗体不会改变大小。 我尝试过: 在新项目中,我尝试调整表单大小并关闭项目。假设新的大小将通过Me.Settings调用保存。 但是在重新启动新项目时,表单的大小仍保持编程状态。 有人可以解释原始项目中发生的事情吗?谢谢。
解决方案这个,culture_info)
导致调整大小的主窗体(变小)。 我知道这与表单的原始大小有关。但是当我实现这个时派生新项目的方法,主要形式不会改变大小。 我尝试过: 在新项目中,我尝试调整表单大小并关闭项目。假设新的大小将通过Me.Settings调用保存。 但是在重新启动新项目时,表单的大小仍保持编程状态。 有人可以解释原始项目中发生了什么吗?谢谢。
I have inherited a project from another code writer. In the project this code:
Dim culture_info As New System.Globalization.CultureInfo(locale_name) Dim manager As New ComponentResourceManager(form_cur.GetType) manager.ApplyResources(form_cur, "$this", culture_info)Leads to the main form being resized (becomes smaller). I understand that this has something to do with the original size of the form. However when I implement this method on a derived new project, the main form does not change size. What I have tried: In the new project, I have tried resizing the form and closing the project. Assuming that the new size would be saved through the Me.Settings call. However on restarting the new project the form's size remains as programmed. Can someone explain what is happening in the original project? Thanks.
解决方案 this", culture_info)Leads to the main form being resized (becomes smaller). I understand that this has something to do with the original size of the form. However when I implement this method on a derived new project, the main form does not change size. What I have tried: In the new project, I have tried resizing the form and closing the project. Assuming that the new size would be saved through the Me.Settings call. However on restarting the new project the form's size remains as programmed. Can someone explain what is happening in the original project? Thanks.
更多推荐
Componentresourcemanager applyresources更改表单大小
发布评论