Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Form1 not showing in delphi editor

1,246 views
Skip to first unread message

nobody

unread,
May 15, 2009, 11:28:08 PM5/15/09
to
I've got a delphi project that I created that has worked fine for years
but now when I'm in the delphi editor and say "view->Forms->Form1 it
doesn't show the form in the editor. All the other forms seem to show
okay. Please help.

Unit1.pas, Unit1.dfm,l Unit1.dcu still exist.

alang...@aol.com

unread,
May 17, 2009, 7:29:05 AM5/17/09
to

Does Form1 show in the Object Inspector. Check the Left & Top
properties. If they are off screen (ie < 0 or > 800), change them to
50 for each.

Alan Lloyd

nobody

unread,
May 17, 2009, 8:03:31 AM5/17/09
to
Thanks for the reply. If I go into Delphi 7 and load my project and
select view->Forms->Form1 the form doesn't get displayed and in the
"Object Inspector" box, it just says "(nothing selected)" and doesn't
show any details or properties from form1 and you can select Form1 in
the object inspector.

If I exit Delphi and in windows explorer I double click on unit1.dfm, it
loads delphi and has a tab that has unit1.dfm in it and in that it says:

object Form1: TForm1
Left = 72
Top = 72
Width = 921
Height = 650

etc.

nobody

unread,
May 17, 2009, 8:06:38 AM5/17/09
to
correction - I meant to say "and doesn't show any details or properties
from form1 and you CAN'T select Form1 in the object inspector."

Jamie

unread,
May 17, 2009, 11:02:10 AM5/17/09
to
Try this.

Select the unit1.pas file in the editor so that it's in
view (source code) and then press the F12 key.
If the unit1.pas is not loading when you start the project then
open it via the file menu and do a save all.

http://webpages.charter.net/jamie_5"

nobody

unread,
May 17, 2009, 11:36:44 AM5/17/09
to
Thanks, though pressing F12 didn't seem to affect things. The unit1.pas
source code shows up okay, it's just the form1 itself that isn't showing
in the editor. I tried Save All (after adding a <Cr> to the source code
so the save all option is enabled) but that still doesn't make it
display form1 in the editor :(.

alang...@aol.com

unread,
May 17, 2009, 12:12:52 PM5/17/09
to
> display form1 in the editor :(.- Hide quoted text -
>
> - Show quoted text -

Do you have Autosave Desktop set in your Tools | Environment Options
(or whatever gets the options in Delphi 7 - I'm using D3).

If so clear the option, rename the .dsk & try again.

You might also rename the .res file to force Delphi to re-create it.
Also check that the .dpr file is OK i Wordpad (ie specifying
"unit1.pas" & "{Form1}").

Of course your files in D7 may be totally different.

Alan Lloyd

nobody

unread,
May 17, 2009, 12:50:36 PM5/17/09
to
alang...@aol.com wrote:

> Do you have Autosave Desktop set in your Tools | Environment Options
> (or whatever gets the options in Delphi 7 - I'm using D3).
>
> If so clear the option, rename the .dsk & try again.
>
> You might also rename the .res file to force Delphi to re-create it.
> Also check that the .dpr file is OK i Wordpad (ie specifying
> "unit1.pas" & "{Form1}").
>
> Of course your files in D7 may be totally different.
>
> Alan Lloyd

Thanks that fixed it!

I was about to post saying it didn't work, but I was just re-checking
everything you said, and suddenly noticed that Form1 is now showing
again :). Thanks a lot!

I didn't have the autosave options checked and I didn't have a .dsk file.

I did rename the .res file like you said and it did re-create the file
and I think the first time I tried opening the project afterwards it
might not have shown form1 but somehow after re-loading the project
(maybe a couple of times) - it's somehow now showing form1 properly. I
think it might have been the recreating the .res file that could have
fixed it.

Whatever the problem was thanks a lot for everyone's help and I'll now
back up the whole project properly just to be safe.

0 new messages