Problem description: This is very Basically Function to View numbers of selected cells, NOT sum, Count Of cells. Steps to reproduce: 1. Count Cells 2. view in status bar 3. this is very simple :( Current behavior: Expected behavior: Operating System: All Version: 4.1.0.0.alpha0+ Master
Hi, Thanks for reporting. I mark this as an enhancement request and NEW because I can't find any duplicates for this request. Kind regards, Joren
Shouldn't be so hard to implement; the existing pop-up combo box in the status bar that changes 'Sum=0' to something else, could easily have a 'Selection' entry. svx/source/stbctrls/stbctrls.src has: // Choice of functions on the SvxPosSizeStatusBarControl for Calc Menu RID_SVXMNU_PSZ_FUNC svx/source/stbctrls/pszctrl.cxx has the relevant code to render that string which comes into there via the SID_TABLE_CELL property I think cf. sc/source/ui/view/cellsh.cxx /SID_TABLE_CELL/ and sc/source/ui/view/tabvwsha.cxx:sal_Bool ScTabViewShell::GetFunction( String& rFuncStr, sal_uInt16 nErrCode ) And Eike might be a good person to review this ;-)
Hi, This was a thing I too wished there to be in LO calc. Got a good chance now to implement it myself. :-) Thanks and Regards, Prashant
Rough sketch: Add a new enum constant to ScSubTotalFunc in sc/inc/global.hxx, e.g. SUBTOTAL_FUNC_SELECTION_COUNT In svx/source/stbctrls/stbctrls.h define a new PSZ_FUNC_SELECTION_COUNT with the same numeric value. In svx/inc/helpid.hrc define HID_MNU_FUNC_SELECTION_COUNT In svx/source/stbctrls/stbctrls.src add a MenuItem resource with Text [ en-US ] = "Selection count"; and the defined constants. In sc/inc/globstr.hrc define STR_FUN_TEXT_SELECTION_COUNT In sc/source/ui/src/globstr.src add a String resource for STR_FUN_TEXT_SELECTION_COUNT In sc/source/ui/view/tabvwsha.cxx Add SUBTOTAL_FUNC_SELECTION_COUNT to the switch(eFunc). Add (eFunc != SUBTOTAL_FUNC_SELECTION_COUNT) to the if below. In sc/source/core/data/documen4.cxx ScDocument::GetSelectionFunction() handle the SUBTOTAL_FUNC_SELECTION_COUNT case. In sc/source/core/data/column2.cxx ScColumn::UpdateSelectionFunction() and ScColumn::UpdateAreaFunction() treat the rData.eFunc==SUBTOTAL_FUNC_SELECTION_COUNT case special such that it does not call lcl_UpdateSubTotal(0 with a cell but instead calculates the selection count. Hope I didn't forget anything ;-)
Hi Eike, So, that was a lot to write and guide. Thanks a lot :-) Many thanks Michael and Eike for the code pointers and rough draft. A simple easyhack but a lot more to learn and understand the flow of structure ;-) I've submitted a patch for the same: https://gerrit.libreoffice.org/#/c/3213/ Thanks and Regards, Prashant
Prashant Pandey committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=e7a5f5ef80c3e66101cfb063cbed0527c0559319 fdo#61541 : Count Number of selected Cells in calc The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.
Created attachment 80655 [details] Screenshot Something weird here, I cannot see this feature on 4.1.0b2 on OS X. SS attached. Could someone confirm this please?
(In reply to comment #7) > Created attachment 80655 [details] > Screenshot > > Something weird here, I cannot see this feature on 4.1.0b2 on OS X. > > SS attached. > > Could someone confirm this please? You have to 'enable' it by right clicking on the 'sum' count in your status bar (right bottom). Once you clicked it, you can choose 'selection count' in that list :-). Works here using Mac OSX 10.8.3. Kind regards, Joren
Created attachment 80664 [details] Screenshot2
(In reply to comment #8) > You have to 'enable' it by right clicking on the 'sum' count in your status > bar (right bottom). Once you clicked it, you can choose 'selection count' in > that list :-). > > Works here using Mac OSX 10.8.3. > > Kind regards, > Joren Oops! Thanks for the info, I should have dug this further before posting. Best regards, Emir
@ Reza Heidari : Khafe shooooo
(In reply to comment #11) > @ Reza Heidari : > > > Khafe shooooo NOTABUG is _NOT_ a correct status for this bug.
Migrating Whiteboard tags to Keywords: (EasyHack,DifficultyBeginner,SkillCpp,TopicCleanup) [NinjaEdit]