Showing posts with label textbox. Show all posts
Showing posts with label textbox. Show all posts

Monday, March 19, 2012

Another SUM limitation problem

I am trying to simply do a rather simply you'd think.... SUM in my textbox on 3 COUNT fields in 3 tables...it's not possible, I get errors whatever way I try this. Look at the Grand Total, that's what I want....a sum of the 3 black fields that have COUNT in them. If this is not possible in SSRS 2005, then Microsoft missed something huge that totally degrades their entire platform, this sucks!

I'm so sick and tired in the past 2 months, very spent on battling SSRS 2005 limitations on Grand Totals like this on many occasions both in tables and freeform textboxes. If you can't do an aggregate on an aggregate then this interface is useless!

http://www.webfound.net/grand_total.jpg

You should be able to do this with a workaround and Code. On each count row, add a hidden cell that assigns a value to a private variable. In your text box, run the code to add up your values.

You should be able to do this with an array. But here is a quick and dirty, assuming you only have two count fields. For simplicity, they are called item1 and item2.

So the cell next to your first count would call code.SetItem1(ReportItems!item1.Value)

The next one would reference the SetItem2 function.

Your textbox then calls GrandTotal()

Code behind:

Dim private _item1 as Integer
Dim private _item2 as Integer

Public Function SetItem1(ByVal item1 As Object) As Integer

_item1 =item1
End Function


Public Function SetItem2(ByVal item2 As Object) As Integer

_item2 =item2
End Function

Public Function GrandTotal() as Object

Return _item1 + _item2

End Function

Sunday, February 19, 2012

Anchoring textbox to a page.

Hi,

In our project I have a matrix report. In that I need to anchor a textbox to the right end of the page, so that the textbox will always be at the right end of the report/page.

I also need to place the textbox at the page header. (but I am also open to solution / workarounds which does not include page header!!)

Thanks in advance

Arun.

any ideas?|||

If you just place a new textbox to the right hand side of your matrix control this will always display at the right hand side of the information displayed, also that textbox can live in the page header.....

Unless you are after something more complex it should be that simple, please provide more info if this is not quite what you are looking for.

|||

thanks for the reply,that works..

but we need soemthing more!!

| textbox | <-- textbox alligned here.

--|

Matrix |

|

--|

we need the matix report and the textbox right aligned to the right margin of the page. ( the textbox's right edge and the matrix right edge edge should align).

thanks in advance...

Arun

|||within the properties page of the matrix control you have an option to grow content right to left or left to right, the default is left to right so change this and it may give you what you are looking for, Otherwise you would have to code the position based on screen width less size of control but this is another task all together, I would assume the property should fix you issues, then the textbox place will be pushed out by the matrix.|||

sorry Andy.. that too doesnt work.. it give a mirror image of the matix that is what we dont need!!..

any other ideas?

thanks

arun

|||

Hi

After much time trying to get this to happen unfortuantely there is no automated way to right align your matrix automatically, It is certianly something i would like to see MS put in as a feature as i would find it useful, The onyl thing you can do is to place the matrix as far right as possible within the designer.

Sorry I dont have a better solution for you here.

Andy

|||

thanks Andy. i would also like to see that in SSRS as a feature!!..

for now i will try to anchor the textbox using some expression..

mean while if anyone comeacross any other ideas please keep me posted!!

thanks

Arun