Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Success, almost, hiding the runtime...

Status
Not open for further replies.

sjpatrick

Programmer
Sep 4, 2001
54
US
Following the instructions in thread #184-142470, I have been having luck getting my forms to run on the Windows desktop with the runtime window nicely hidden away, but I have run into a snag. Text boxes et al do not seem to hold on to their control source.
They work fine in the foxpro window, but show up blank and do not refresh when the form runs on the desktop. The same is true for combo boxes and edit boxes, no matter what the control source is.
Oddly, the grid control works correctly.
Any ideas?
 
I suspect that the problem is in where the tables are with respect to where the executable is. How do you set your path in your program, and where is the executable running from? You might want to do a CD in the program when it starts and see if it's where you expect it to be. Then see how your tables are addressed.

I know I always have a Dave.prg which I use to set up my directories and path when I work on a project Then I have a shortcut in my projects folder run it I modify it for each project to start things in the proper directory and give the shortcut a useful label and icon. But it isn't necessarily *included* in my project so it would need to be placed in my MAIN program or somewhere similar before I'd create an .exe.

Dave Dardinger
 
If you have included the tables in the executable, you can have them in the project, but exclude them. Recompile and let us know, if it still has the problem.

Hope this helps :) ramani :-9
(Subramanian.G)
FoxAcc
ramani_g@yahoo.com
LET KNOW IF THIS HELPED. ENOUGH EXPERTS ARE HERE TO HELP YOU OUT! BEST OF LUCK :)
 
As with every project, I start with my usual set default to (directory in question) and set path to (blank) statements. I am having no trouble opening and accessing the files other than to get them to display in text boxes correctly. Setting the text box init event to "this.value=table.field" and setting the form's activate event to "this.label.caption=table.field" both yield the expected results. But doing this for every text box and including calls to every text box's init event whenever I do something that changes fields would be extremely cumbersome.
Plus, that isn't the way it's supposed to work.
I never include tables in my executables, so I know that isn't it. (I just checked again to be sure... ;-) )
Also, a combo box that has an array as the controlsourcetype shows up blank, so it isn't related just to data locations.
Thanks guys, but I'm still in a spot.
 
Well, object init events happen before the form init event, so I'd suspect something there... except that you claim things work ok in the FoxPro window. I don't know what to say except to show us the code and let us see if we can see something.

Dave Dardinger
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top