• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 139
  • Last Modified:

Formless application!

I have to create an application which doesn't show form when it starts!
1 Solution
TPAKTOPAuthor Commented:

You can one of the following:

1) Delete all the forms from your application and write all the code in the begin... end. statements of the DPR file (the project's source)

2) If you want your application to have forms, but you don't want them to show at the program start, you can use TApplication.ShowMainForm. To hide the main form at startup, set ShowMainForm to False in the main project file before the call to Application.Run, and make sure that the Visible property of the form is also False.

All that can be done in the project source, which can be seen in the Project | View Source menu.


btw:the mainform's visible property should also be false
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.


Take a look at the last line of my suggestion #2:

>and make sure that the Visible property of the form is
>also False

A caveat:
You can make a formless application.  Then you may wish to use a Windows API function that requires you to pass the handle of the calling application (ie. your app).  Normally this is the handle of the parent window - Application.Handle.  You don't have a parent window, so what do you pass?

I don't have a solution to this one as yet.
Well, for once, you can pass NULL/NIL/0, whatever, if the command is not directed at your application (i.e., it's supposed to be OK if you're just supposed to get some info in a structure, or make windows itself do something).

Plus, as much as I understand, you can also pass the application's handle, Application.Hanlde (of course), or even the required object's handle.

Anyone else?
Yeah, spelling mistake there. Application.Handle (again, of course).
This question was awarded, but never cleared due to the JSP-500 errors of that time.  It was "stuck" against userID -1 versus the intended expert whom you awarded.  This corrects the problem and the expert will now receive these points; points verified.

Please click on your Member Profile and select "View Question History" to navigate through any open or locked questions you may have to update and finalize them.  If you are an EE Pro user, you can also choose Power Search to find all your open questions.

This is the Community Support link, if help is needed, along with the link to All Topics which reflects many TAs recently added.

Thank you,
Moderator @ Experts Exchange
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now