[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User nn changed the following: What|Old value |New value CC|''|'ufi' --- Additional comments from [EMAIL PROTECTED] Fri Apr 20 11:57:07 + 2007 --- To get a locale-independent string, you have to use the Str() function. That's the way it's supposed to be (compatibility and all, you know). The help text is a bit misleading, as Format() without a format string is not exactly the same as Str() – Format() is always locale-aware. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 15:49:15 + 2007 --- Thank you. You are right. But i tried it with Format(3.45) instead of Str(3.45). (I use format() rather then str().) The help file says: Format Function [Runtime] [...] Format (Number [, Format As String]) [...] If Format is omitted, the Format function works like the Str function. Or in german: "Wird Format nicht angegeben, so verhält sich die Funktion Format so wie die Funktion Str." But now i must learn, that Str(3.45) <> Format(3.45) in german ... but it seems "" & 3.45 = Format(3.45) but i'm not sure ... So this isn't what i would expect. I have had expected that "" & 3.45 = "3.45" (= Str(3.45)). And i think every (english) programmer don't think about this problem because there isn't any description for this behavior. Thank you. - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User fst changed the following: What|Old value |New value Status|RESOLVED |CLOSED --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 14:59:21 + 2007 --- closed invalid - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User fst changed the following: What|Old value |New value Status|UNCONFIRMED |RESOLVED Resolution| |INVALID --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 14:58:49 + 2007 --- hi, it's not a defect ! But it's a support request, such questions are answered on the mailinglists, especially users@ or api@ . The problem in your case is the '&' sign which converts your double to a string and this is locale dependent. You may use the STR() function to convert your value to a string like oCell.setFormula( "=SECOND(" & Str( dValue ) & ")" ) Frank - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User mroe changed the following: What|Old value |New value Status|CLOSED|UNCONFIRMED Resolution|INVALID | --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 14:18:12 + 2007 --- Thank you for your quick reply. But it doesn't resolve the problem. First: dValue (= 3.45) has (IMHO) internal the point as decimal separator. And variable values should work on all platforms indepent from the locale setting. So it isn't a solution to test the configuration before every calculation ... Sub TestLocalValue Dim oCell As Object Dim dValue As Double oCell = ThisComponent.getCurrentSelection() dValue = 3.45 print "1 Value: " & dValue 'de: 3,45i. O. 'en: 3.45ok oCell.setValue( dValue ) print "2 Value: " & oCell.getValue() 'de: 3,45i. O. 'en: 3.45ok oCell.setFormula( "=" & dValue ) print "3 Value: " & oCell.getValue() 'de: 0 Fehler 'en: 3.45ok oCell.setFormula( "=NOW()" ) dValue = oCell.getValue() print "4 Value: " & dValue 'de: i. O. 'en: ok oCell.FormulaLocal = "=JETZT()" print "5 Value: " & oCell.getValue() 'de: i. O. 'en: 0 error oCell.setFormula( "=SECOND(" & dValue & ")" ) print "6 Value: " & oCell.getValue() 'de: 0 Fehler 'en: ok oCell.FormulaLocal = "=SEKUNDE(" & dValue & ")" print "7 Value: " & oCell.getValue() 'de: i. O. 'en: 0 error End Sub What is the "right" way? - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User fst changed the following: What|Old value |New value Status|RESOLVED |CLOSED --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 13:32:38 + 2007 --- closed invalid - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 User fst changed the following: What|Old value |New value Status|UNCONFIRMED |RESOLVED Priority|P2|P3 Resolution| |INVALID --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 13:32:10 + 2007 --- Hi, not a P2 task and not a defect. oCell.setFormula() requires an English value. Use oCell.FormulaLocal = "=" & dValue instead. Frank - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[sc-issues] [Issue 76510] (api, calc, de/german) ins erting formulas into cells with decimal values failed
To comment on the following update, log in, then open the issue: http://www.openoffice.org/issues/show_bug.cgi?id=76510 Issue #|76510 Summary|(api, calc, de/german) inserting formulas into cells w |ith decimal values failed Component|Spreadsheet Version|OOo 2.2 Platform|PC URL| OS/Version|Linux Status|UNCONFIRMED Status whiteboard| Keywords| Resolution| Issue type|DEFECT Priority|P2 Subcomponent|programming Assigned to|spreadsheet Reported by|mroe --- Additional comments from [EMAIL PROTECTED] Thu Apr 19 11:02:33 + 2007 --- On a german OOo it gives a error if you want to insert formulas with decimal values in it into a cell. So it isn't possible to read a value from one cell and insert a formula with this value into any cell. Try the following code at a new calc document with a german locale setting: Sub TestValue Dim oCell As Object Dim dValue As Double oCell = ThisComponent.getCurrentSelection() dValue = 3.45 print "Value: " & dValue 'de: 3,45 'en: 3.45 oCell.setValue( dValue ) print "Value: " & oCell.getValue() 'de: 3,45 'en: 3.45 print "String: " & oCell.getString() 'de: 3,45 'en: 3.45 oCell.setFormula( "=" & dValue ) print "Value: " & oCell.getValue() 'de: 0 'en: 3.45 print "String: " & oCell.getString() 'de: #NAME? 'en: 3.45 End Sub - Please do not reply to this automatically generated notification from Issue Tracker. Please log onto the website and enter your comments. http://qa.openoffice.org/issue_handling/project_issues.html#notification - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]