There is already a functionality that does this, in IR → Actions → Download → Email, but it sends all records and I need to send only the records that are selected in the IR .
Is there any way to modify this functionality that already exists?, or set it up to do this?, some ideas, tips, something that can help me, maybe using the bind variable :REQUEST?
Thanks in advance.
Vinish Kapoor
I have just tested the IR report by filtering the data using the top search region and then used the mail option. It is sending only those records currently visible.
Are you talking about selected rows from this search region?
Natalia
Hi Vinish, thanks for answering.
I actually mean the checkboxes, the selected records that are checked, and not limiting the number of rows by filtering by columns.
see the image. I have checked only 3 rows in the report , then the Html file attached to the email should contain only 3 rows and not all of them
afzal
step 1.. create a employee report with checkbox like --
select apex_item.checkbox2(
p_idx => 1,
p_value => EMPNO,
p_attributes => 'class="empno"',
p_checked_values => :P35_EMPNO,
p_checked_values_delimiter => ',') CHECKBOX, ENAME,JOB,HIREDATE from EBA_DEMO_CHART_EMP
step 2.. create a hidden item --P35_EMPNO , and set value protected off
step 3.. create another hidden dummy employee report without checkbox name="DummyReport" like
select EMPNO,ENAME,JOB,HIREDATE from EBA_DEMO_CHART_EMP
WHERE EMPNO IN (select column_value from apex_string.split(:P35_EMPNO, ','))
SUBMIT-- P35_EMPNO
---define these setting in this report region-- to hide this report
STATIC ID= emp
custom attribute= style="display:none;"
step 4.. keep the selected row empno in "P35_EMPNO" item using dynamic action like-- 101,102,103
step 5..create a button "downloadReport" with static id "btn"
step 6.. keep javascript code like- var popup=null; "at function and global variable declartion section of the page"
step 7.. create dynamic action
name="refresh report"
event- click
selection type- button
button- "downloadReport"
action--javascript code
popup = apex.util.showSpinner( $( "#btn" ) );
apex.region('emp').refresh();
step 8.. create dynamic action
name= "open download popup"
event- after refresh
selection type- region
region--- DummyReport
action -- javascript code
popup.remove();
$('#emp_actions_menu').menu('find','irDownload').action();
Natalia
Hello Afzal.
Thank you very much for your answer.
yes, I expected to have to implement a new functionality, adding a button to the report menu bar and by a dynamic action to be executed when clicking on the button generate the download process.
I will give it a try and comment how it turns out.
Have a nice day