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

Using registry.prg 1

Status
Not open for further replies.

coldan

Programmer
Oct 19, 2008
98
AU
In my app I need to access the registry.

On my dev PC all works fine but I need to make it available on any PC.

I have copied registry.prg to my dev folder but it fails on any other PC without VFP.

The line is loRegistry = NEWOBJECT('registry',HOME(2)+'classes\registry.prg')

What would the form of this be to use the file in my dev folder?

Thanks

Coldan.
 
Coldan,

You need to make sure that Registry.PRG is either bound into the executable, or available on your VFP search path.

The easiest way is to include Registry.PRG in your project when you build the executable. Then, in your code, remove the path to Registry.PRG. In other words, do this:

Code:
loRegistry = NEWOBJECT('registry','registry.prg')

After you have built the executable, it should run fine.

Mike

__________________________________
Mike Lewis (Edinburgh, Scotland)

Visual FoxPro tips, advice, training, consultancy
Custom software for your business
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top