简体   繁体   English

Lazarus - 如何更改启动表单的顺序

[英]Lazarus - How to change the order of a start up form

My project was started with a certain form named Form1 . 我的项目是从名为Form1的某个表单开始的。 Now I have many forms. 现在我有很多形式。 Now I need to make a new form (ie, my login form- frmLogin ) the start up form. 现在我需要创建一个新表单(即我的登录表单-frmLogin )启动表单。

I went to project options and under forms, I used the arrow (on the side of the forms list) and moved the login form to the top. 我去了项目选项并在表单下,我使用箭头(在表单列表的一侧)并将登录表单移动到顶部。

Now the login form starts fine. 现在登录表单开始正常。 But BEFORE I can input a username, a message box I use on the next form (ie, Form1) gets shown. 但是在我输入用户名之前,我会在下一个表单(即Form1)上显示一个消息框。 The messagebox is in the FormCreate procedure of Form1. 消息框位于Form1的FormCreate过程中。

I'm confused about this. 我对此感到困惑。 Am I missing something? 我错过了什么吗? How can I prevent the FormCreate's code from running. 如何防止FormCreate的代码运行。 Form1 is only called by frmLogin AFTER the user has clicked login and successfully entered a password. Form1仅在用户单击登录并成功输入密码后由frmLogin调用。

In your project settings: check which forms are auto-created. 在项目设置中:检查自动创建的表单。 Normally when you create a new form it is auto-created. 通常,当您创建新表单时,它会自动创建。 I think you don't want that in your app. 我想你不希望在你的应用程序中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM