Issue 52179 - Formula starting with '+' or '-'
Summary: Formula starting with '+' or '-'
Status: CLOSED DUPLICATE of issue 20496
Alias: None
Product: Calc
Classification: Application
Component: code (show other issues)
Version: 680m90
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: spreadsheet
QA Contact: issues@sc
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-07-19 17:03 UTC by muthusuba
Modified: 2005-07-20 09:09 UTC (History)
3 users (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description muthusuba 2005-07-19 17:03:08 UTC
Formula cells should be allowed to start with '+' or '-' along with '='
This would help in ease of use. Many excel or gnumeric users find it easier to
start a formula cell by using '+' or '-' (because the number pad contains these
and its tough to press '=' every time a formula is to be entered).

Proposed patch: 
--- sc/source/ui/view/viewfunc.cxx	2005-07-17 21:30:12.000000000 +0530
+++ sc/source/ui/view/viewfunc.cxx	2005-07-17 21:36:50.786937728 +0530
@@ -451,7 +451,8 @@ void ScViewFunc::EnterData( SCCOL nCol, 
 
 		BOOL bNumFmtChanged = FALSE;
 		// einzelnes '=' ist String (wird fuer Spezialfilter so gebraucht)
-		if ( rString.GetChar(0) == '=' && rString.Len() > 1 )
+		if ( ( rString.GetChar(0) == '=' || rString.GetChar(0) == '+' ||
rString.GetChar(0) == '-' )
+			   && rString.Len() > 1 )
 		{	// Formel, compile mit AutoCorrection
 			for (i=0; i<nTabCount; i++)
 				if (rMark.GetTableSelect(i))
Comment 1 frank 2005-07-20 09:07:41 UTC
Hi,

this is a double to Issue 20496 .

Please attach your patch to this Issue.

Frank

*** This issue has been marked as a duplicate of 20496 ***
Comment 2 frank 2005-07-20 09:09:31 UTC
closed double