Sage 100

 View Only
  • 1.  Sage Intelligence Hide Zero Row Macro

    Posted 02-11-2019 17:50
    Hello,

    For many years I have been using a macro that I got from someone here to Unhide/Hide zero rows in Sage Intelligence workbooks and it has always worked great. I have recently had an issue with it acting unexpectedly for one client and wanted to see if anyone has run into similar issues with macros. It seems to unexpectedly not hide rows that it should be hiding and the client is also telling me that it is hiding rows it shouldn't be. I can't replicate this on the clients system consistently. It really seems to do something different each time. Has anyone run into this before? Any thoughts or suggestions on why?

    Sub UnhideRows()

        Dim sh As Worksheet

        Application.Calculation = xlCalculationManual

        Application.ScreenUpdating = False

        For Each sh In ThisWorkbook.Worksheets

               sh.Cells.EntireRow.Hidden = False

        Next sh

        Application.Calculation = xlCalculationAutomatic

        Application.ScreenUpdating = True

    End Sub

    Sub HideZeroRows()

        Dim sh As Worksheet

        Dim i As Long

        On Error Resume Next

        Application.Calculation = xlCalculationManual

        Application.ScreenUpdating = False

        For Each sh In ThisWorkbook.Worksheets

            For i = 9 To 327

                If Not IsEmpty(Range("T" & i)) Then

                    If IsNumeric(Range("T" & i)) Then

                        sh.Rows(i).Hidden = Application.Sum(sh.Range("T" & i).Resize(, 36)) = 0

                    End If

                End If

            Next i

        Next sh

        Application.Calculation = xlCalculationAutomatic

        Application.ScreenUpdating = True

    End Sub



    ------------------------------
    Jesse Braun
    Vrakas/Blum Computer Consulting, Inc.
    ------------------------------


  • 2.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 08:36
    FWIW, I have this link in my notes. http://www.sagedl.com/sage-email/PDFs/Excel%20VBA.txt  I don't write much code and I don't know what would make it behave differently different times, but I notice this your code applies to each sheet in workbook and this one refers to each cell in the range. 

    For Each cell In rng

    If (Not IsEmpty(cell) And cell.Value = 0) Then

    cell.EntireRow.Hidden = True

    ------------------------------
    ==================
    Rhonda McNamara
    Customer Success Manager
    Stewart Technologies, Inc.
    rsm@stewarttechnologies.com
    ------------------------------



  • 3.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 09:35
    Can't you use the Add-in included with <g class="gr_ gr_42 gr-alert gr_gramm gr_inline_cards gr_run_anim Style multiReplace" id="42" data-gr-id="42">SI ?</g>  They briefly reviewed this in the recent SI for financials course.

    Alchemex Add-in 1
    ZeroingII




    ------------------------------
    Wayne Schulz - Schulz Consulting - 860-516-8990
    ------------------------------



  • 4.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 10:23
    The last time I tried to use ZeroingII I could only get it to apply to one worksheet in the workbook.  I have generally had to tweak he macro for each client to get it to work. properly.

    ------------------------------
    Phil McIntosh
    President
    Friendly Systems, Inc.
    Asheville NC
    678.273.4010 ext 5
    ------------------------------



  • 5.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 10:41
    Edited by Erin Oldaker 02-12-2019 14:37
    This took me a bit to figure out, since Sage gives no information on this.

    The SMI plug-in works on multiple sheets but you have to repeat the function for example and you must use the setting below for the add-in to update correctly while the user is in the report and they want to change the parameters.

    PLPLUGA.A.ZeroingII(Income Statement,A,0,1,0,0,0,0,1,1,=);PLPLUGA.A.ZeroingII(Balance Sheet,A,0,1,0,0,0,0,1,1,=);PLPLUGA.A.ZeroingII(HCI,A,0,1,0,0,0,0,1,1,=);PLPLUGA.A.ZeroingII(HCO,A,0,1,0,0,0,0,1,1,=);                                                      ***** an issue with this logic is the space to enter all the text is not big enough, so you can probably fit about 15 sheets of Add-in logic MAX.  Sage didn't think about this one 

    One thing that took me a while to get right that makes a huge difference. If you choose the "default options" for the plug-in that Sage gives you, one setting is VERY important to change.   If you do not change this setting the plug-in will not update or refresh if you change the parameters in the worksheet after the report has been run. (this has caused me too much frustration and has led me to also use the macro)

    This setting will hide all zero rows at the time it is run, then if the user changes the period, it will unhide all rows first, change the period/year, then hide the zero rows again.   Seems like a no-brainer, but this setting defaults to NO, If this is not changed, it will hide the zero rows at run time, if the user changes the period/year, it will now hide any additional zero rows... which does not help anybody.

    Hope this helps some people some time.






    ------------------------------
    Erin Oldaker
    Senior Consultant
    SWK Technologies Inc.
    Huntington Beach CA
    858-244-5040
    ------------------------------



  • 6.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 12:58
    This might be kind of low tech, but I avoid the macros and add-ins, with all their moving parts that can break, and do a simple manual filter.
    Let me know if anyone finds problems with this concept. I've only used it once so far.
    --------------------------------------
    How to filter out zero rows
    Create a column at the end of your financial. 
    Sum the absolute values of all the columns in the row.
    This way you don't have a neg/pos cancel each other out.
     
    To sum by absolute value =SUMPRODUCT(ABS(A1:A10))
     
    Format the column with white color font so it doesn't show.
    Do a standard filter on that column and select <> zero.
    blank values for headings, etc still show.

    ------------------------------
    Clark Walliser
    Senior Consultant
    DSD Business Systems
    San Jose CA
    Clark
    ------------------------------



  • 7.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 13:22
    I agree and have used that technique with BizNet. Low tech, straight forward, easy to understand (for the End User).

    ------------------------------
    Greg Stiles
    S & W Microsystems
    Torrance CA
    310.787.1010
    ------------------------------



  • 8.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 13:28
    Hi
    I've used that method and it does work except it has to be applied manually and refreshed manually for each worksheet tab.  Not bad for 1-5 tabs but for customers with 5-100, it's a bit of a PIA.

    ------------------------------
    Nancy Hanson
    Blytheco LLC
    Eagan MN
    ------------------------------



  • 9.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-12-2019 15:08

    My solution to that, so far, is to do all my formatting/filtering on the primary sheet, and copy the sheet for my other sheets.

    This way the filtering is included.

    Then I make my modifications per sheet.

    As long as I insert columns / rows within the body, the sum function should work.

     

    This has worked great... the one time I have done it ��

     

     

    DSD Email Signature

     



    ------Original Message------

    Hi
    I've used that method and it does work except it has to be applied manually and refreshed manually for each worksheet tab.  Not bad for 1-5 tabs but for customers with 5-100, it's a bit of a PIA.

    ------------------------------
    Nancy Hanson
    Blytheco LLC
    Eagan MN
    ------------------------------


  • 10.  RE: Sage Intelligence Hide Zero Row Macro

    Posted 02-14-2019 15:26
    These are all such great suggestions and a great discussion overall. Interestingly, I tried the Zeroing Add In and that also acted unexpectedly! It was hiding weird rows that it shouldn't be. I discovered today with another client that it may be related to the way I converted them over from FrX. Both of these clients recently converted from FrX and I used the instructions from Sage on how to do this. This includes exporting the report from FrX then specifically moving the tab to your newly saved SI report, instead of copying the data. I found that for ones where I moved the sheet I had issues with macros. Sheets where I copied and pasted the data over did not have macro problems. Could it be that the newer versions of Excel are having a hard time converting/working with these old FrX sheets? Just a theory but I am intending to test this out with my original client and see if it works. Thanks again everyone for the interesting discussion and all the ideas to try!

    ------------------------------
    Jesse Braun
    Vrakas/Blum Computer Consulting, Inc.
    ------------------------------