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 SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

compile error in C:\myprog\myprog.app

Status
Not open for further replies.

JRB-Bldr

Programmer
May 17, 2001
3,281
0
0
US
When you try to make the new EXE in the VFP Project and get the error message, have you gone into the Project - Errors... top-level menu pull-down to view the specific errors that were encountered?

If not, then please do so.
If so, then what were the errors listed.

Good Luck,
JRB-Bldr
 
program has been in use for over 5 years.

What changed?

Or are you saying the existing exe has been in use for five years but nobody has tried compiling it in all that time?
 
@MikeLewis the "Display Errors" is marked

@jrbbldr For my first time ever, I went to "Project - Errors... top-level menu pull-down ". The ERRORS option was grayed out and not available. I recomplied with a known error in place. An error box was displayed, as expected. I could then go to "Project - Errors... top-level menu pull-down " and the ERRORS option was enabled. The ERRORS option displayed the same info about the known error that was displayed during compiling.

 
@DanFreeman This is the software we use at our medical practice. I modify it as needed. After editing some accounting functions/procedures/forms (I forget which), it refused to compile. I have been going along with no updates for a few months, but it's time to get it fixed.

Is there a way to isolate the prg or frm files and compile them individually and check for errors??
 
@DanFreeman To answer the question,"has it been compied during the 5 years?", I checked out the VERSION info under the BUILD OPTIONS. I'm on revision 264.

In the past, VFP would tell me what's wrong, but now I'm not getting a specific error message, just the "compile error in C:\myprog\myprog.app".
 
Your version number doesn't tell me a danged thing. When was the last time this exe built properly? Was it on the same computer? The same OS? (Back to what changed?)

Have you tried building with the debugger open?

Errors mentioning the .app specifically can often mean the exe has been marked read-only or otherwise protected. If VFP can't delete it or recreate it, your build will not succeed.

(A VFP EXE is an .app with the .exe loader tacked on the top, so the .app gets built first.)
 
@DanFreeman thanks for the suggestions

last succesfull compile 3-28-2011

opened debugger, ran build, same error, no info from debugger.(I am unfamiliar with running DEBUGER and BUILD at the same time)

The app does run in development mode.

Tried building EXE in a new subdirectory (so deleting old EXE would not be an issue), same error came up.

Tried building 2 other projects, to confirm VFP could still create a project, both EXEs were created with no errors.

I beleive I have a bug in my code. I am hoping for a way to isolate it.
 
I doubt it's a bug in your code. VFP is pretty good at pointing out that stuff.

What it CANNOT point out is the stuff it just can't find, and this is sounding more and more like a problem with a relative path that's gone wonky. VFP just can't find the pits and pieces the project points to. (If your working directory, any mapped drives, or the location of any code portions have changed, you've got some housekeeping to do!)

Create a new project with a different name, add JUST the top-level program and build. See where it burps.
 
Not sure if this would help in this scenario, but IIRC it displays a list of all errors encountered in compilation, not just "cannot update cursor".

Has proven very handy for me in the past - from Mike Lewis' website(!) -


I like work. It fascinates me. I can sit and look at it for hours...
 
@DanFreeman Thank you for the insight

@FatSlug I could not find "IIRC it ", but your link took me to a program called "whichone". The program crashed due to a bad directory name for the project, just as DanFreeman suggested above.

I will research the bad directory name. It has a directory name from my home computer. This may be my problem. I will report later.

 
Is it the home directory for the project? That's pretty easy to fix. (Project menu, Project Info option, change the Home folder.)

If it's a directory for any of the files in the project, just remove the files. VFP will either add the first one it can find or prompt you to locate any files not listed in the project. It self-repairs that way.
 
IIRC is not a vfp command, it's an acronym for "if I remeber correctly".

In regard to the compilation problem, like Dan says, it looks like you're opn the right way to solve the problem.

Normally just opening the project will prompt for missing files and ask you to either locate them or remove them from the project. Did you have such messages and ignored them? Then that does not repair the project and is the reason for the build fail.

Bye, Olaf.
 
Thanks again for all the quidance and education.

The program "whichone" from Mike Lewis' website is now working after I corrected the project directory name and made a minor correction to the program ( the include file did not recognise a reserved word because a "(" was next to it)

"whichone.prg" has spit out a list of compile errors for me to fix. I will report later. Other job duties call me now.
 
Sad report

The program "whichone" was listing errors because DELETED was OFF. Once DELETED was set to ON, the report came back NO ERRORS.

I will start looking for other answers.
 
Is there any chance that you accidentally added the APP file to the project?

Tamar
 
@TamaraGranor Thank you for the suggestion.
Under the CODE tab of the project manager, if I expand everything, I see nothing under APPLICATION nor API LIBRARIES, only under PROGRAMS. I will continue troubleshooting.
 
Problem resolved.

Quick to the point. After various attempts, I made a new subdirectory, copied over my MAIN.PRG and FIRST.FRM and started a new project.

To my surprize, FoxPro then coppied 95% of the files I needed from my old project without asking me. I can compile again.

This process did weed out a lot of unneeded or orphaned files that I had collected over the last 5 years. I also used my first active X component from the VFP library to replace a calendar program. The new EXE is 2.12 megs, the old EXE was 3.52 megs.

I'm happy now and I consider this problen solved.
 
Thanks for posting back. It seemed you already had solved the problem via fixing the list of errors you got from Mike's whichone.

I can give you another thing to do in the future: Before BUILD, open the debugger, especially the Debug Output window, then build. VFP will then do a verbose listing of things he does during compiling. If VFP does not spit out errors you will at least see on which file vfp stopped compiling.

Also, as you say the error is reported about an APP file: If you compile a project to an exe or dll, at first foxpro genereates an APP always and then adds something making it a DLL or EXE and changes file extension. If that fails the problem could be as simple as the EXE was still in memory, started. Or it was readonly. Simply delete the old EXE or DLL before BUILD and that should go away.

Bye, Olaf.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top