Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to get all the settings in IDE vs. run-time?
Message
From
01/02/2017 12:22:58
 
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 10
Database:
MS SQL Server
Miscellaneous
Thread ID:
01647262
Message ID:
01647264
Views:
89
This message has been marked as the solution to the initial question of the thread.
Likes (1)
>Hi everybody,
>
>I got this email from my former boss:
>
>I did some more testing and here is the interesting point.
>
>If I take the program xlsxfile and run it from the command window I get the correct results. If I make the routine a project and call it from my main program it returns the first column label in all the fields.
>
>There must be some setting that is causing the routines not to retrieve the correct values in the individual cells.

>
>I suspect it may be 'SET EXACT and SET ANSI' settings, but I think there is a way to get all these settings somehow saved, but I just don't remember how.
>
>Do you know how to get all the settings from IDE vs. run-time?
>
>Thanks in advance.

Going just a step further from the Help file (but I'll be really embarrassed if there is a simpler solution...):
LOCAL regfile, oReg
LOCAL ARRAY aFoxOptions[1,2]
LOCAL Option

m.regfile = HOME(2)+"classes\registry.prg"
SET PROCEDURE TO (m.regfile) ADDITIVE
m.oReg = CreateObject("FoxReg")
m.nErrNum = m.oReg.EnumFoxOptions(@m.aFoxOptions) 

SET ALTERNATE TO "Settings.txt"
SET ALTERNATE ON

FOR m.Option = 1 TO ALEN(m.aFoxOptions, 1)
	? m.aFoxOptions[m.Option, 1],"=",m.aFoxOptions[m.Option, 2]
ENDFOR

SET ALTERNATE OFF
SET ALTERNATE TO

MODIFY FILE Settings.txt
----------------------------------
António Tavares Lopes
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform