How to change the SSRS input parameters position in report
Asked Answered
S

5

13

My SSRS report contains 7 input parameters and while running my report the size of the parameter(i.e. length) is increasing.

One of my input parameter(drop down list) may contain 100 characters so the size is not constant but i want to place all parameters in 2 lines or 3 lines(in a row).

Now it is coming 2 parameters per a row

Please advice

Shrewish answered 14/8, 2010 at 11:55 Comment(0)
M
8

As gbn indicates, it's not easy to change the built in report server method of presenting the parameters. SSRS likes to always use two parameters per line, presented in the order that they exist in the report (which must match the dependency order.)

So the alternatives that gbn mentions: Both involve building a "Wrapper" application: some custom code or a web page that you can code however you like to get the parameters. Then you call Reporting Services, either in code or by passing a formatted URL with your parameters. The report can be displayed in a frame, new window, or passed as a stream to where ever you'd like.

The URL access is pretty straightforward and reliable: I often use it either by hand (to create "favorites") or in code.

http://msdn.microsoft.com/en-us/library/ms153586.aspx

For what you are looking for, these might be more work than you expected, but they will be extremely flexible for your interface.

Jamie

Maxie answered 2/9, 2010 at 15:41 Comment(1)
Thank you! A great explanation about parameters.Whitcomb
B
6

You can certainly do that, just right click on the RDL file in the solution explorer and select view code. then move the XML tags named <ReportParameter Name="Nameofparameter"> under <ReportParameters> according to where ever you want to position. And then save it. thats it!!!

The report parameters are kind of floating in values of 2, so if u have 4 report parameters then it will be shown as 1,2 next line 3,4. Best of luck!!

Befool answered 26/4, 2012 at 15:7 Comment(3)
yes this works if you want to change the position of your parametersHomothallic
Bit pointless, surely? You can just click on the tiny arrows in design view next to parameters to move them up and down.Bondy
The original question is asking about a custom layout for parameters, not for the ordering in a default layout.Vernal
R
4

Use ASP.NET for the paramaters and a ReportViewer control or URL access to render. Seriously.

I don't know of any option to present parameters any way other then the default

Rahel answered 14/8, 2010 at 12:42 Comment(1)
could you guide me, how to use ASP.NET or URL access in SSRS for this senarioShrewish
Q
2

I believe you could try using jQuery. The report parameters are rendered in a table under a div tag with class sqlrv-ParameterContainer. Write a jQuery or JavaScript function that will extract the full innerHTML from this div ie. the table content and then extract the table row information like the <label> or <input> tags.

Create your desired table structure with <table><tr><td>{extracted sections}</td><td></td></tr></table> or leave it to your requirement...

Then just append this new HTML structure in place of the original default structure.

In jQuery it will be like

$(".sqlrv-ParameterContainer").html();

which will give you the entire table structure that comes inside the parameter. Use XML parsing and get the input controls and all. Extract these controls as-is, don't change anything.

$(".sqlrv-ParameterContainer table").remove(); // it will remove the SSRS rendered default table from DOM

$(".sqlrv-ParameterContainer table").appendChild('<table><tr>......</tr></table>'); // Append your custom html structure here....

This was something that came to my mind quickly... I would suggest you test it... :)

Quenby answered 6/5, 2011 at 5:39 Comment(2)
Please try to put more efford in the structure of your answer e.g. full sentences and less dots. Otherwise it's a bit hard to read.Adinaadine
This answer does not handle cascading, dependent parameters.Vernal
A
0

This doesn't help the OP with SSRS-2008 but in case it helps others - Microsoft have improved this in SSRS 2016 - parameters can now be easily managed via the GUI in Report Builder / Visual studio:

https://www.intertech.com/ssrs-parameters-2016-update/

Aluminum answered 2/12, 2020 at 15:9 Comment(1)
If this answer does not provide the answer to the question then your answer is not suitable for this question and should be raised in a more suitable question.Voyageur

© 2022 - 2024 — McMap. All rights reserved.