Put a formula to a cell with macro and it doesent calculate. (Excel localisation problem?)
Hello NG,
I want to put a formula to a cell:
oWorksheet.Cells(2, 2).FormulaR1C1 =
"=VLOOKUP(RC[-1],Table2!A:B,2,FALSE)"
If I excecute this line and look at the cell than there is written
"#Name?". If I click in the cell I see the formula translated to
German. (The German word for VLOOKUP is SVERWEIS.) If I press Return
the correct value is displayed. The formula is still in the cell. The
result of the formula is written in the sheet.
How can I refresh the cells automitcally?
I think the problem is the translation to the German Excel language. If
I take this formula:
oWorksheet.Cells(2, 2).FormulaR1C1 = "=A1*100"
The correct value is displayed immediatly...
Regards
Peter
|