Board index » delphi » App won't start w/out Delphi [help]

App won't start w/out Delphi [help]

   I have a really strange problem here. I've been working on a program for a
few weeks now. As long as I run the program while Delphi 2.0 is running,
everything works fine, whether I run it from in the IDE or from outside of
Delphi. However, once I exit from Delphi, the program will not run. If I double
click on the app's icon from Explorer, the cursor changes to the arrow with the
hourglass by it, it appears in the taskbar for about a second, and then nothing
else happens. I'm stumped. I've tried other Delphi 2.0 programs of mine, and
they work normally. Just to see where the problem occurred, I tried this in my
project source:

program Winpac;

uses
  Forms, Dialogs,
  Main in 'Main.pas' {MainForm},
  Globals in 'Globals.pas',
  ... (all other form units)
  Messaging in 'Messaging.pas' {MessageForm};

{$R *.RES}

begin
  Application.MessageBox('Starting program', 'WinPac 2', 0);
  Application.Initialize;
  Application.MessageBox('Initialized', 'WinPac 2', 0);
  Application.Title := 'WinPac 2';
  Application.MessageBox('Titled', 'WinPac 2', 0);
  Application.CreateForm(TMainForm, MainForm);
  ... (create all other forms)
  Application.CreateForm(TMessageForm, MessageForm);
  Application.MessageBox('Forms Created', 'WinPac 2', 0);
  Application.Run;
  Application.MessageBox('Run', 'WinPac 2', 0);
end.

When I run the program while Delphi 2.0 is running, the Message Boxes appear
when they should. When I try to run the program when Delphi 2.0 is not running,
however, none of them ever show. For that reason, I'm assuming that none of my
code is being run at all. Any ideas?

--
              _   __   ---------------------------------------------
  .,,        ( `-'  \  | Tyler Dauwalder                           |
 C:::]|||||||||() | |  | dauwa...@televar.com                      |
  `'`        (_.-.__/  | http://www.adsnet.net/tyler_d/default.htm |
                       ---------------------------------------------

 

Re:App won't start w/out Delphi [help]


Are you using one of those shareware components which will only run
inside Delphi? If you don't but did, did you remove any references to it
in the uses-clause(s)?

--
Bent Tranberg, Agder College, Grimstad
Grooseveien 36, 4890 Grimstad, Norway
e-mail: Bent.Tranb...@hia.no

Re:App won't start w/out Delphi [help]


Quote
dauwa...@adsnet.net (Tyler Dauwalder) wrote:
>    I have a really strange problem here. I've been working on a program for a
> few weeks now. As long as I run the program while Delphi 2.0 is running,
> everything works fine, whether I run it from in the IDE or from outside of
> Delphi. However, once I exit from Delphi, the program will not run. If I double
> click on the app's icon from Explorer, the cursor changes to the arrow with the
> hourglass by it, it appears in the taskbar for about a second, and then nothing
> else happens. I'm stumped. I've tried other Delphi 2.0 programs of mine, and
> they work normally. Just to see where the problem occurred, I tried this in my
> project source:

<source snipped>

Quote
> When I run the program while Delphi 2.0 is running, the Message Boxes appear
> when they should. When I try to run the program when Delphi 2.0 is not running,
> however, none of them ever show. For that reason, I'm assuming that none of my
> code is being run at all. Any ideas?

Here's just a guess - I'm not much on dirty details of 95.  However, I had
the exact same problem running NT 3.51; I could run the thing from Delphi,
just not from the Program Manager.  The problem?  It seems you can't add
parantheses  "(" or ")" to the name of your program.  In progman I had
added a little bit to the App title - Myprog (Beta) and that just hosed
it all up...  Got rid of the (Beta) and everything was just hunky-dory!

I'm just guessing that something similar could be happening to you?

-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Chris Kasten
Programmer/Analyst

#include <std/disclaimer.h>
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

Other Threads