I am working on a SSRS report which has From & To date as input parameters and it has to be validated such that From date can't be more than To date.
I was successful in creating a custom VB code which takes care of validation but the problem is when the validation fails i need to display a user friendly pop up alert which i am not able to do. I tried giving the alert using MsgBox (VB.NET) and also tried calling Response.Write inside javascript, but none of these works.
Help me in getting this done.
Following are the steps that you can follow to achieve this.
In the code section of the report add the following code.
Public Function SelectedMore( ParamCnt As Integer ) As Boolean
Dim Cnt As Boolean
Cnt = IIf(ParamCnt < 4 , 1, 0)
Return Cnt
End Function
Add a text box on the report layout page and add contents to it saying user has selected more than 3 parameter values. You can make this bold and red if you want.
Then go to the properties of the above text box and go to ‘visibility’ tab. Select ‘Show or hide based on the expression’ and add the following expression in the box ‘=Code.SelectedMore(Parameters!HeatMapList.Count)’. This will make this textbox visible only when more than 3 values are selected.
Now go to the parameters of the main dataset ( the onw which fetches the results for you), go to the parameters tab and next to parameter HeatList, click the expression button (fx). In the expression box type in the following code, =IIf(Parameters!HeatMapList.Count > 3, Nothing, Parameters!HeatMapList.Value). This will not pass any value to your main dataset for the parameter and results would return empty. You can alternately add the visibility expression inverse to that of the above textbox, for the main tablix. This will hide the table when textbox is displayed and vise-versa.
Related
Is there a good visual tutorial that takes through the various steps on how to create radio buttons in Apex 19.2? This tutorial Creating a Classic Report having radio button on each row helped me and I’m looking for a similar one..
In my case, I would like to add a radio button to each row of my classic report which when selected would add some of the informations selected by the radio button in a text field in the same page.
Any advice is much appreciated.
Thank you
Install Sample Reporting application on your APEX instance (preferably on apex.oracle.com as Dan suggested).
Navigate to the Classic Report page.
Change the query to the report to the following:
select rowid,
ID,
PROJECT,
TASK_NAME,
START_DATE,
END_DATE,
STATUS,
ASSIGNED_TO,
COST,
BUDGET,
apex_item.radiogroup(1,TASK_NAME) ACTION
from EBA_DEMO_IR_PROJECTS
where (nvl(:P3_STATUS,'0') = '0' or :P3_STATUS = status)
Note the added column "ACTION" which consists of the apex_item.radiogroup with TASK_NAME value. Let's assume that this is the value that you want to pass to another page item.
Open that column's attribute under Page Designer and disable "Escape special characters" attribute and add a CSS Class (e.g. mycolumn)
Create a Page Item (e.g. P3_NEW).
Now add the following Dynamic Action
Event > Click
Selection Type > jQuery Selector
jQuery Selector > #classic_report .mycolumn input
Your true action will be of the type Set Value and the Set Type is JavaScript Expression with the following code:
this.triggeringElement.value
Your affected element is P3_NEW and disable Fire on Initialization
Can i make field value hidden within Expression in SSRS because i don't want to display this integer value?
For instance: I placed text box where I created simple Expression:
="Click for Details" & Fields!LocationId.Value
Fields!LocationId.Value is my specified parameter where I link Main report ID and Details report ID
I use Action within cell column to redirect to subreport based on unique LocationId.Value where user will click on the line with wording "Click for Details".
When report runs I have in each cell :Click for Details3636
Click for Details7239
and so on..
is mission impossible here??!!
Angelika
I am trying to hide a textbox based on another textbox value in a table. In my ssrs 2013 report, I have a column in a table called EmpExist that returns nothing or text like Emp does not exist. On top of the table I have a textbox called Go To when clicked it will take you to another report. I am trying to hide this textbox based on EmpExist column in the table.
I tried the following, setting the visibility of "Go To":
=IIF(ReportItems!EmpExist.Value = "" OR ReportItems!EmpExist.Value IS NOTHING, False, True)
or this:
=IIF(First(Fields!EmpExist.Value, "dataset1") IS NOTHING OR First(Fields!EmpExist.Value, "dataset1") = "", False, True)
The problem is that the Go To textbox will be either visible or hidden regardless of the EmpExist value. If the EmpExist has any value, "Go To" should be hidden, but it is visible. If it does not have any value or nothing, it should display it but it is visible as well.
Thanks.
I ended up using a parameter to check the value of EmpExist and used the expression above (using the parameter instead of the column name) and seems to be working fine. Not sure why I was not able to do it based on textbox value in SSRS 2013
In BIRT, the report parameters window that pops up for user input ,I am taking two radio buttons. For the first radio button ,I am giving 'ALL' to select all office codes.
For the second radio button , I want to add a text box where the user can give one particular office code as input.
I would like to know how to add a text box against a radio button.
Thank you in advance.
I believe it is possible to do as you ask, but it would require creating a custom parameter. This is an easier solution for what I imagine is what you are trying to do.
The easier solution use a single text box in your parameter, set the default value to "All" and SQL code in your query similar to this.
where CONTCTSM1.OPERATOR_ID = ?
or
('All' = ?
and
CONTCTSM1.ACTIVE = 'f' )
With this code if a specific value is given it returns results for that one parameter. If the Value is left as All, then it returns all values where CONTCTSM1.ACTIVE = 'f'
I have a SubReport with a textbox, I would like to read the value of this textbox and then put it in the main report for each data row.
My SubReport is in a data column.
If you are using Visual Studio, you should be able to drag and drop the sub report object into the text box and configure it from there. But make sure that if the sub report expects parameters, you send the required parameters.