Solved

form has disappeared... vb6

Posted on 2004-09-12
10
297 Views
Last Modified: 2010-05-02
After adding a timer control as Timer1, when I ran the application.  All of the controls on the form (there was only one form) was gone.  frmFormat(Form1.frm) was changed to frmFormat(Form1Backup.frm).  frmFormat(Form1Backup.frm) is a blank form.

Did I loose the form for good?  How this can happen?

0
Comment
Question by:Mike Eghtebas
  • 3
  • 2
  • 2
  • +3
10 Comments
 
LVL 76

Accepted Solution

by:
GrahamSkan earned 100 total points
ID: 12041432
Don't know what happened, but is it that Form1.frm still on your computer, but not included in your project? If so you should be able to load it back into your project. (Project/Add File)
0
 
LVL 26

Assisted Solution

by:Rejojohny
Rejojohny earned 100 total points
ID: 12041440
search for the Form1.frm in ur computer .. then as "GrahamSkan" suggested .. add it to ur project .. do u see the form in the design-view?
0
 
LVL 76

Expert Comment

by:GrahamSkan
ID: 12041480
Mind you, if your computer is anything like mine, you could have many Form1.frm files.
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 
LVL 10

Assisted Solution

by:anv
anv earned 100 total points
ID: 12041550
did u add any code to the timer event of the timer??

check if ur forms AutoRedraw Property..

set it to True
0
 
LVL 76

Expert Comment

by:GrahamSkan
ID: 12041609
You could also check in your recycle bin.
0
 
LVL 7

Assisted Solution

by:_agj_
_agj_ earned 100 total points
ID: 12041725
more detls pls.

wat is frmFormat?

is it a function that returns a form?
0
 
LVL 32

Assisted Solution

by:Erick37
Erick37 earned 100 total points
ID: 12043874
If you ran the application without first saving your work and the application crashes the VB IDE, then all your work done after your last save may be lost.

Check your settings in:

Tools->Options->[Environment]

There is an option to automatically save your project before running the application, or prompt to save, or don't save.


Are you running any 3rd party backup tools or add-ins for VB?

0
 
LVL 33

Author Comment

by:Mike Eghtebas
ID: 12045340
Correction...

1. frmFormat(Form1Backup.frm) was there and still it is there.  I compared it with a backup copy (5 days old).
---------------
2. Code behind is still there butt all controls are gone.  In propertysheet or form's code window, none of the controls' name showing in controls/objects drop box.
----------
3. GrahamSkan,        Project/Add File just adds the same form on top of existing identical form.

Re:> You could also check in your recycle bin

It is not there.
---------
4. Rejojohny,          Sorry, Form1.frm is not missing.  See line 1 above.

Re:> do u see the form in the design-view      No, the controls are gone, also see line 2 above
---------
4. anv ,      

Re:> did u add any code to the timer event of the timer , per question Q_21128127, I was adding timer control when all these happened.  Affter adding the control it stop working (form disapeared.  Maybe not related to it at all).

Re:> check if ur forms AutoRedraw Property…  Yes it is True

did u add any code to the timer event of the timer??

check if ur forms AutoRedraw Property..

set it to True

5. agj,

RE:> is it a function that returns a form?      It is a typical form.
6. Erick37
Ihaven’t lost the unsaved portion but all of the controls.  No, I am not using any backup software.  Once in a while, I copy the entire folder under a different name.
----------
Sorry for the delay in my response.  I had lost my internet connection.

This form in Form Load event has a routine like:

Me.Width=lstNames.Left+lstNames.Width +600
Me.Height=...

But, when I added the timer control, it was put on the form beyond this width.  And, when I ran the form, it errored on the above lines and after that I lost my controls.  Meaning, the timer control should have been within me.width and me.height, possibly.

I have caoppied and pasted the 5-days old form and its .frx to the new project foder and running okay for now (not loosing the code behind the corrups form was helpful to restore all).

It is nice to know if putting a timer in a wrong place could cause all these.

Regards,

Mike
0
 
LVL 26

Expert Comment

by:Rejojohny
ID: 12051618
just curious . is this problem u r facing in vb.net or VB6?
0
 
LVL 33

Author Comment

by:Mike Eghtebas
ID: 12059618
Rejojohny,

vb 6.
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In a recent article (http://www.experts-exchange.com/A_7811-A-Better-Concatenate-Function.html) for the Excel community, I showed an improved version of the Excel Concatenate() function.  While writing that article I realized that no o…
Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

810 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question