?
Solved

How to make a VFP code to obtain the .exe version that is running ?

Posted on 2011-05-09
10
Medium Priority
?
811 Views
Last Modified: 2012-05-11
Hi Experts

How to make a VFP code to obtain the .exe version that is running ?

(I mean: the code obtains the version of the exe where itself is embeded)

Thanks in advance !
0
Comment
Question by:Eduardo Fuerte
  • 4
  • 3
  • 2
  • +1
10 Comments
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 35722974
? VERSION()
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 35722993
? VERSION(4)
0
 

Author Comment

by:Eduardo Fuerte
ID: 35723073
I'm going to check later....
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 12

Expert Comment

by:jrbbldr
ID: 35723105
The above is the correct code to use....

Unless you are looking for the version of the application (one interpretation of your statement - "the .exe version"), not just the version of the VFP EXE.

Note that there are typically at least 2 EXE's involved in your VFP application.
  1.  The VFP EXE used to compile the application
  2.  The Application EXE that resulted from your compilation

If you are trying to display the application version you first have to have that value managed and stored somewhere for reference purposes and then your VFP code can access it for display purposes.  

Alternatively you can acquire the application EXE's Date Time from its Windows file properties and use it for the purposes of a version designator.   Your VFP application can do this as well.

Good Luck
0
 
LVL 27

Expert Comment

by:CaptainCyril
ID: 35723461
0
 

Author Comment

by:Eduardo Fuerte
ID: 35723628
Hello

What I need is

"2.  The Application EXE that resulted from your compilation"

obtained via VFP code.


0
 
LVL 12

Expert Comment

by:jrbbldr
ID: 35724212
As I indicated above, where are you going to get this version number from?

If it will be created from the EXE File Date/Time, then you can use the VFP ADIR() function to get this data (see your VFP Help).

If you will be creating this version number/designator in some other manner by your code development and/or compilation process or just manually, then you will need to save off this information somewhere (maybe into something like a Config data table??) and then have your VFP application acquire that information and display it in whatever manner you wish.

Good Luck
0
 
LVL 30

Accepted Solution

by:
Olaf Doschke earned 2000 total points
ID: 35728435
AGETFILEVERSION() is giving you the version of an EXE.

You can set the version number in the build dialog via the Version Button, and AGETFILEVERSION(aInfo,"your.exe") reads this version besides into aInfo[11] besides other infos in the result array.

Example to get the foxpro version number:
AGETFILEVERSION(aInfo,HOME()+"vfp9.exe")
? aInfo(11)

Open in new window


Bye, Olaf.
0
 

Author Comment

by:Eduardo Fuerte
ID: 35732347
Hello, Olaf

I'm going to check later....
0
 

Author Closing Comment

by:Eduardo Fuerte
ID: 35733600
Exactly what I need
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

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

Microsoft Visual FoxPro (short VFP) is a programming language with it’s own IDE and database, ranking somewhat between Access and VB.NET + SQL Server (Express). Product Description: http://msdn.microsoft.com/en-us/vfoxpro/default.aspx (http://msd…
Exchange administrators are always vigilant about Exchange crashes and disasters that are possible any time. It is quite essential to identify the symptoms of a possible Exchange issue and be prepared with a proper recovery plan. There are multiple…
This lesson discusses how to use a Mainform + Subforms in Microsoft Access to find and enter data for payments on orders. The sample data comes from a custom shop that builds and sells movable storage structures that are delivered to your property. …
Screencast - Getting to Know the Pipeline
Suggested Courses

850 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