Microsoft Visual FoxPro Professional Edition 7.0 for PC Logo
Posted on Mar 17, 2011
Answered by a Fixya Expert

Trustworthy Expert Solutions

At Fixya.com, our trusted experts are meticulously vetted and possess extensive experience in their respective fields. Backed by a community of knowledgeable professionals, our platform ensures that the solutions provided are thoroughly researched and validated.

View Our Top Experts

Can you give sample source code of visual foxpro program using mySql as database flatform

1 Answer

Anonymous

Level 2:

An expert who has achieved level 2 by getting 100 points

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

Sniper:

An expert who has posted more than 50 answers, of which 90% or more were rated as helpful.

  • Expert 64 Answers
  • Posted on Mar 20, 2011
Anonymous
Expert
Level 2:

An expert who has achieved level 2 by getting 100 points

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

Sniper:

An expert who has posted more than 50 answers, of which 90% or more were rated as helpful.

Joined: May 23, 2010
Answers
64
Questions
0
Helped
23548
Points
260

Create a connection: lcStringCnxRemoto = "DRIVER={MySQL ODBC 3.51 Driver};" + ; "SERVER=200.1.1.1;" + ; "PORT=3333;" + ; "UID=booking;" + ; "PWD=booking;" + ; "DATABASE=booking;" + ; "OPTIONS=131329;" lcStringCnxLocal = "DRIVER={MySQL ODBC 3.51 Driver};" + ; "SERVER=localhost;" + ; "UID=root;" + ; "PWD=clave;" + ; "DATABASE=booking;" + ; "OPTIONS=131329;" SQLSETPROP(0,"DispLogin" , 3 ) lnHandle = SQLSTRINGCONNECT(lcStringCnxLocal)
Accesing data:
SQLSETPROP(0,"DispLogin" , 3 ) lnHandle = SQLSTRINGCONNECT(lcStringCnxLocal) IF lnHandle > 0 cmd = SQLEXEC(lnHandle,"select QuantityRooms from roomtype","cur_roomtype") IF cmd > 0 BROWSE ELSE AERROR(laErr) MESSAGEBOX("Can't connect to mySQL. Error: " + CHR(13) + laErr[2]) ENDIF USE IN cur_roomtype SQLDISCONNECT(lnHandle) ELSE AERROR(laErr) MESSAGEBOX("Can't connect to mySQL. Error: " + CHR(13) + laErr[2])
ENDIF
Creating complex sentences:
TEXT TO lcSQLcommand NOSHOW SELECT Inventory.inventoryid, Inventory.date, Inventory.roomtypeid, Inventory.sold, Roomtype.descrip, Roomtype.rooms FROM inventory Inventory INNER JOIN roomtype Roomtype ON Inventory.roomtypeid = Roomtype.roomTypeID ORDER BY Inventory.date DESC ENDTEXT cmd = SQLEXEC(lnHandle,lcSQLcommand)
Passing parameters to a query:
nValor = 12 cmd = SQLEXEC(lnHandle,"select QuantityRooms from roomtype where roomtypeid = ?nValor","cur_roomtype")
Calling a Stored Procedure:
SQLEXEC(lnHandle, "call myStoreProcedure(@param1)")
GOOD LUCK!

Add Your Answer

×

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

0helpful
1answer

How to move one mysql database to another machine

After logging into MySQL via command prompt, use the below commands.
Backup :
databasename > dumpfile.sql
Restore :
source dumpfile.sql

If you have an IDE like HeidiSQL or SQL Yog, they can make tasks easier through visual interfaces.
0helpful
1answer

Please give me the procedure how to import foxpro files in tally 7.2

To import data from a FoxPro database, use the Microsoft Visual FoxPro ODBC driver. To do so, follow these steps:
1) Click Start, and then click Control Panel.
2) In Control Panel, double-click Administrative Tools.
3) In the Administrative Tools window, double-click Data Sources (ODBC), and then add a new ODBC data source for your FoxPro database or tables by selecting the appropriate Visual FoxPro driver.
4) Start Access, and then open your Access database. 5) On the File menu, point to Get External Data, and then click Import. 6) In the Import dialog box, click ODBC Databases in the Files of type list. 7) In the Select Data Source dialog box, click the Visual FoxPro data source that you created in step 3, and then click OK. 8) In the Import Objects dialog box, click the tables that you want to import, and then click OK.

1helpful
1answer

How to install foxpro

You can install this version of Visual FoxPro from a CD-ROM or anetwork to a local hard drive. You must install Visual FoxPro on alocal drive, not a mapped drive. There is no other preparation requiredbefore installing Visual FoxPro. You must have administrator privilegesto install Visual FoxPro. It is recommended that you run withpower-user privileges to use all the provided tools effectively.
Youcan safely install or uninstall using Visual FoxPro Setup. If you areupgrading Visual FoxPro, you must first uninstall the previous versionof of the program. Though both versions of Visual FoxPro can exist onthe same computer, you cannot install the current version of VisualFoxPro in the same directory as the previous version.
If you planto publish XML Web services using Visual FoxPro, you might want to setup Internet Information Services (IIS) on a Windows 2000, Windows XP orWindows Server 2003 computer. Refer to your operating systemdocumentation for instructions on how to set up and configure IIS.
030c41d9079671d09a62d8e2c1db6973.gifNote VisualFoxPro setup no longer installs any Windows operating system ServicePacks or versions of Internet Explorer. It is highly recommended thatyou install the latest versions of these components before installingVisual FoxPro. Additionally, Visual FoxPro 9.0 is supported only onWindows 2000 Service Pack 3 or later. For details about installing thelatest Service Pack, visit the following Microsoft Web page at http://www.microsoft.com/windows2000/.
Full installation includes all Visual FoxPro program files, online help, and samples files.
To install Visual FoxPro
  1. Quit all open applications.
    030c41d9079671d09a62d8e2c1db6973.gifNote Ifyou use a virus protection program on your computer, override it orturn it off before running the Installation wizard. The Installationwizard might not run properly with virus protection turned on. Afterinstallation, be sure to restart your virus protection program.
  2. Insert the Visual FoxPro CD.
    The Visual FoxPro Setup start page appears automatically.
  3. Click Install Visual FoxPro to launch Visual FoxPro Setup.
  4. To determine if you need additional components, click Prerequisites to display any necessary components.
  5. Click Install Now! to install any new components. If Visual FoxPro Prerequisites needs to only update components, click Update Now!
  6. You might need to restart your computer. When finished, click Done.
    Visual FoxPro Setup reappears.
  7. To continue installation, click Visual FoxPro.
  8. After accepting the End User License Agreement and entering the Product Key and your name, click Continue.
    030c41d9079671d09a62d8e2c1db6973.gifNote Visual FoxPro cannot be installed on a mapped drive. You must install Visual FoxPro on a local drive. Do not attempt to use the Map Network Drive functionality in Setup.
  9. On the Options page, select the features you want to install and click Install Now! to continue.
  10. When finished, click Done to return to Visual FoxPro Setup. Click Exit to return to the Visual FoxPro Setup start page.
Ifyou uninstall Visual FoxPro while the previous version of Visual FoxProexists on your computer, certain shared registry keys used by theprevious version of Visual FoxPro are removed. You must reinstall thesecritical shared registry keys.
If you run Visual FoxPro fromthe Start menu, Visual FoxPro Setup automatically reinstalls thesekeys. If you start Visual FoxPro using other means, such as running theapplication executable directly, the setup program does not startautomatically. You should use Add/Remove Programs in the Control Paneland the following steps to reinstall the registry keys manually:
To manually reinstall Visual FoxPro 9.0 registry keys
  1. From the Start menu, click Control Panel.
  2. Click Add/Remove Programs.
  3. Click Change/Remove for Microsoft Visual FoxPro 9.0.
  4. Click Visual FoxPro and Repair/Reinstall.
Good Luck
0helpful
4answers

HOW TO SOLVE VFP FILE CURRUPT WHEN POWER FAILURE

At times, you may view that your MS Visual FoxPro 9.0 database is behaving abnormally. Some of the abnormal symptoms could be an error message while opening any database table, invalid characters in place of pre-defined values, and and more. The main reason for abnormal behavior of the database is its corruption due some logical crash. Few common reasons for corruption of MS Visual FoxPro 9.0 database are abnormal termination, faulty network devices, simultaneous modifications, conflicting third-party software, and incompatible service packs.
To overcome such database corruption scenarios, the user can use an up-to-date backup and perform restoration. However, restoration fails in cases where the user either forgets to create a database or the database backup itself gets damaged. In such cases, the database users can use a third-party DBF File Repair application to repair his/her corrupted database.
To illustrate the above case, consider a real-time scenario wherein you execute a query to modify your MS Visual FoxPro 9.0 database. While the query was performing the modification, the system shutdown due to power failure. However, the next time you tried to mount the database, you encountered an error message that did not allow you to access the database records. Moreover, the same error message appears every time you try to access the database.
Cause:
The root cause for the error message is MS Visual FoxPro 9.0 database corruption due to improper system shutdown.
Resolution:
The database corruption error message can be surmounted by following the below steps:
Use a complete database backup and perform restoration. However, in case of database backup unavailability, you will need to search for a commercial DBF File Repair utility.
A third-party DBF Repair application uses effective repair techniques to repair logically damaged MS Visual FoxPro 9.0 database and restore it at a new and safe location. The original database during the repair process remains intact. The tool is easy-to-understand and allows even a non-technical person to perform repair.
DBF Recovery Software is a comprehensive solution to repair databases created in MS Visual FoxPro 9.0, MS Visual FoxPro 8.0, and MS Visual FoxPro 7.0. The tool also repairs databases built in dBase III, dBase IV, and dBase V. Supported by Windows 7, Vista, 2003, XP, and 2000, the DBF Repair tool creates a new repaired file that can be attached to existing database.
Tanvi Sharma is a self employed Internet entrepreneur and product reviewer. This DBF Repair utility is extremely useful when the dBase and Foxpro database gets corrupted due to internal program errors, hardware malfunctioning, accidental deletion of data and more. This DBF Repair software repairs all types of database components including table name, column name, column data type, indexes and primary keys.
0helpful
1answer

Program code for a bar code in the supermarkets

All what you need is a Barcode Scanner.

I develop this type of software with Visual Fox Pro and Oracle (using ODBC drivers) or where are not big budgets i use MySQL (with ODBC drivers).

Also you can use a php page with mysql.
0helpful
1answer

I want connet foxpro databse to visiual basic

Using a DSN-less connection to open a free table
'
cn.Connect = "SourceType=DBF;" _
& "SourceDB=C:\Vfp\Samples\Data;" _
& "Driver={Microsoft Visual FoxPro Driver}"
1helpful
2answers

Convert my database from dpf to mdb

Use access to import external data. It can read dbf and create mdb
0helpful
2answers

Visual foxpro to access

hi
you need to use a ODBC conexion to trasport your tables into table .dbf in fox

or

you need to copy tur tables to excel documents an then import in vfp

bye
0helpful
2answers

Foxpro dos application exe obfuscation

you need the re-fox or fox shell

is works good

an from mexico
Not finding what you are looking for?

1,382 views

Ask a Question

Usually answered in minutes!

Top Microsoft Computers & Internet Experts

Grand Canyon Tech
Grand Canyon Tech

Level 3 Expert

3867 Answers

k24674

Level 3 Expert

8093 Answers

Brad Brown

Level 3 Expert

19187 Answers

Are you a Microsoft Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...