Page 1 of 1
Formulas in exel
Posted: Mon Jul 28, 2008 12:37 am
by Armando
Dear friends:
Have a nice day.
I am looking for a small sample to record formulas in a excel sheet using TOLE.
somebody can help me ?
Best regards
Re: Formulas in exel
Posted: Mon Jul 28, 2008 7:37 am
by Enrico Maria Giordano
Code: Select all | Expand
oSheet:Cells( nRow, nCol ):Value = "=your formula here"
Note the equal sign.
EMG
Posted: Mon Jul 28, 2008 1:35 pm
by Armando
Enrico:
Thanks so much, problem solved with your help (as usual)
Now another question !
Is there a way to know the version of excel that is being used ?
I mean, =SUM(), (English language) is not equal to =SUMA() (Spanish language) how to know when to use one and when to use an other one ?.
Best regards
Posted: Mon Jul 28, 2008 4:20 pm
by Enrico Maria Giordano
First try if the English version works in Spanish version too, at least using OLE.
EMG
Posted: Mon Jul 28, 2008 4:54 pm
by Armando
Enrico:
Thanks for your replay.
In Spanish versiĆ³n does not work a formula in English language
=SUM() <> =SUMA()
Regards
Posted: Mon Jul 28, 2008 8:04 pm
by Enrico Maria Giordano
Code: Select all | Expand
#define msoLanguageIDInstall 1
#define msoLanguageIDUI 2
#define msoLanguageIDHelp 3
FUNCTION MAIN()
LOCAL oExcel := CREATEOBJECT( "Excel.Application" )
LOCAL oApp := oExcel:CommandBars( "Standard" ):Application
? oApp:LanguageSettings:LanguageID( msoLanguageIDInstall )
? oApp:LanguageSettings:LanguageID( msoLanguageIDUI )
? oApp:LanguageSettings:LanguageID( msoLanguageIDHelp )
? oExcel:LanguageSettings:LanguageID( msoLanguageIDInstall )
INKEY( 0 )
RETURN NIL
EMG
Posted: Mon Jul 28, 2008 9:14 pm
by Armando
Thank you Mr. Enrico:
I'll try
Best regards