Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. Database & SysAdmin
  3. Database
  4. Working with SSRS-2005 Reports in C# Web Applications..

Working with SSRS-2005 Reports in C# Web Applications..

Scheduled Pinned Locked Moved Database
csharpsql-serverhelpquestion
4 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    Aswanth
    wrote on last edited by
    #1

    I'm Working with SSRS-2005 Reports in C# Web Applications.. I'm having One Doubt regarding Division.. In Chart Control (Pie-Chart Type) (Properties--> Data--> Values--> (Select Edit)--> EditChartValues--> PointLabels-->Label-Expression) I'm Using the Following expression.. =Floor((Fields!Price.Value*100)/Sum(Fields! CPU.Value, "DataSet1_AmountDetails")) & "%" In Chart Control(Pie-Chart Type).. I'm getting Output as.. 10%, 15%, 12%, 7%, 27%, 14%, 14% ... If I'm Using the Following Expression in Chart Control (ie I'm Not Including FLOOR here).. =((Fields!Price.Value*100)/Sum(Fields!CPU.Value, "DataSet1_AmountDetails")) & "%" In Chart Control(Pie-Chart Type).. I'm getting Output as.. 10.2564789456%, 15.457893652145%, 12.877895632%, 7.9845678987%, 27.12348532%, 14.6547863254%, 14.7550103026% ... Even I Used ROUND Instead of FLOOR in My expression.. I'm getting my Output as.. 10%, 15%, 13%, 8%, 27%, 15%, 15%.. which gives me the Total Percentage is More than 100%.. I want to show my Reports for Only 100%... This is the Problem i'm facing when i'm Using Round --------------------------------------------------------------------------------------------------------------- But I Want the OutPut as 10.25%, 15.45%, 12.87%, 7.98%, 27.12%, 14.65%, 14.75%... How can I do this... Please give me the Suggestions for doing this... Thank You..

    P 1 Reply Last reply
    0
    • A Aswanth

      I'm Working with SSRS-2005 Reports in C# Web Applications.. I'm having One Doubt regarding Division.. In Chart Control (Pie-Chart Type) (Properties--> Data--> Values--> (Select Edit)--> EditChartValues--> PointLabels-->Label-Expression) I'm Using the Following expression.. =Floor((Fields!Price.Value*100)/Sum(Fields! CPU.Value, "DataSet1_AmountDetails")) & "%" In Chart Control(Pie-Chart Type).. I'm getting Output as.. 10%, 15%, 12%, 7%, 27%, 14%, 14% ... If I'm Using the Following Expression in Chart Control (ie I'm Not Including FLOOR here).. =((Fields!Price.Value*100)/Sum(Fields!CPU.Value, "DataSet1_AmountDetails")) & "%" In Chart Control(Pie-Chart Type).. I'm getting Output as.. 10.2564789456%, 15.457893652145%, 12.877895632%, 7.9845678987%, 27.12348532%, 14.6547863254%, 14.7550103026% ... Even I Used ROUND Instead of FLOOR in My expression.. I'm getting my Output as.. 10%, 15%, 13%, 8%, 27%, 15%, 15%.. which gives me the Total Percentage is More than 100%.. I want to show my Reports for Only 100%... This is the Problem i'm facing when i'm Using Round --------------------------------------------------------------------------------------------------------------- But I Want the OutPut as 10.25%, 15.45%, 12.87%, 7.98%, 27.12%, 14.65%, 14.75%... How can I do this... Please give me the Suggestions for doing this... Thank You..

      P Offline
      P Offline
      pmarfleet
      wrote on last edited by
      #2

      Specify the number of dps you want to round to. With SSRS, I think the number of dps to round to is passed as the 2nd argument to the Round() function.

      Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush

      A 1 Reply Last reply
      0
      • P pmarfleet

        Specify the number of dps you want to round to. With SSRS, I think the number of dps to round to is passed as the 2nd argument to the Round() function.

        Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush

        A Offline
        A Offline
        Aswanth
        wrote on last edited by
        #3

        Thank You for Replying Me.. How to do this.. This is the Expression i'm using for Round.. =Round((Fields!Price.Value*100)/Sum(Fields! CPU.Value, "DataSet1_AmountDetails")) & "%" Now how can I specify the Number of dps to round..

        P 1 Reply Last reply
        0
        • A Aswanth

          Thank You for Replying Me.. How to do this.. This is the Expression i'm using for Round.. =Round((Fields!Price.Value*100)/Sum(Fields! CPU.Value, "DataSet1_AmountDetails")) & "%" Now how can I specify the Number of dps to round..

          P Offline
          P Offline
          pmarfleet
          wrote on last edited by
          #4

          I already told you how to do this. SSRS provides intellisense for expressions, so you should be able to see what arguments a function accepts.

          Paul Marfleet "No, his mind is not for rent To any God or government" Tom Sawyer - Rush

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups