Download Any Report Csv, Xml And Xlsx Files In Oracle Apex

<span style="font-size:22px"> <h2>Download Any Report Csv. Xml And Xlsx Files In Oracle Apex</h2> </span>

Download Any Report Csv. Xml And Xlsx Files In Oracle Apex

 

The Most Common Solution Is To Convert The Xlsx File Into A Csv Format And Upload Data From The File To The Website Table Using The Pl / Sql Custom Process. This Is A Simple And Proven Method, But Due To Low Flexibility It Is Only Suitable For Uploading Files With A Fixed And Predictable Data Format (Number Of Columns And Their Data Types). In The Event Of Adding A New Column To An Existing File Or Deletion, We Are Forced To Adjust The Upload Process And / Or The Target Table. If We Want To Give The User The Ability To Share Data In The Form Of A Report, We Should Also Keep In Mind About The Apex Application Update.
It Does Not Change The Fact, That There Is A Need To Import Data Directly Into Xlsx Files And Our Customers Will Not Stop Asking For It. So If Necessary, We Should Find A Solution, Right?

Steps To How To Download Any Report Csv, Xml And Xlsx Files.

1. Create A New Page, Name- Download Any Report 
2. Create a Region, Name- All Button Name- All Button
    Type- Static Content
    Source -> HTML Code-

    <!--DOCTYPE html-->
    <html>
    	<head>
    		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    			<title>SheetJS JS-XLSX In-Browser HTML Table Export Demo</title>
    			<style>
    .xport, .btn {
     display: inline;
     text-align:center;
    }
    a { text-decoration: none }
    #data-table, #data-table th, #data-table td { border: 1px solid black }
 </style>
<style type="text/css"></style>
   </head>
    <body>
    <!--[if gt IE 9]-->
    <script type="text/javascript" src=" #APP_IMAGES#download/xlsx.full.min.js.download">
             	</script>
    <!--[endif]---->
    <!--[if lte IE 9]>
    <script type="text/javascript" src="shim.min.js"></script>
    <script type="text/javascript" src="xlsx.full.min.js"></script>
    <script type="text/javascript" src="Blob.js"></script>
    <script type="text/javascript" src="FileSaver.js"></script>
    <![endif]-->
  <script>
    function doit(type, fn, dl) {
     var elt = document.getElementById('testid');
     var wb = XLSX.utils.table_to_book(elt, {sheet:"Sheet JS"});
     return dl ?
      XLSX.write(wb, {bookType:type, bookSST:true, type: 'base64'}) :
      XLSX.writeFile(wb, fn || ('Downloaded File.' + (type || 'xlsx')));
    }
    </script>
        <pre>
        	<b>Export it!</b>
        </pre>
        <table id="xport">
            <tbody>
                <tr>
                    <td>
                        <pre>XLSX Excel 2007+ XML</pre>
                    </td>
                    <td>
                        <p id="xportxlsx" class="xport">
                            <input type="submit" value="Export to XLSX!" onclick="doit(&#39;xlsx&#39;);">
                        </p>
                        <p id="xlsxbtn" class="btn"></p>
                    </td>
                </tr>
                <tr>
                    <td>
                        <pre>XLSB Excel 2007+ Binary</pre>
                    </td>
                    <td>
                        <p id="xportxlsb" class="xport">
                            <input type="submit" value="Export to XLSB!" onclick="doit(&#39;xlsb&#39;);">
                        </p>
                        <p id="xlsbbtn" class="btn"></p>
                    </td>
                </tr>
                <tr>
                    <td>
                        <pre>Comma Separated Values</pre>
                    </td>
                    <td>
                        <p id="xportcsv" class="xport">
                            <input type="submit" value="Export to CSV!" onclick="doit(&#39;csv&#39;);">
                        </p>
                        <p id="csvbtn" class="btn"></p>
                    </td>
                </tr>
            </tbody>
        </table>
        </body>

        </html>

        
3. Create a New Region, 
   Name- Report,
   Type- Table/View
   Table- Your Table
   Advanced-> Static ID- testid
4. Go to Page Properties.
     JavaScript -> File URLs- Paste the code-

	<script src='https://cdn.jsdelivr.net/gh/jABER-IT/BlogSite-All-Host-File/Export_Data_Excel_File_In_Oracle_Apex/xlsx.full.min.js'/>
 

🔗 Demo Application-
            URL- Demo Application
            Username - demo, Pass- demo
 

I hope everyone will like it. Please watch the full video,
Comment on any of your problems, I will try my best to solve the problem, In-Shah Allah. Everyone's cooperation is desirable. Visit my blog site, new technology related videos, you will get different types of tutorials of Oracle Apex, and hopefully, you can use them in your daily work.
Please stay tuned by subscribing to the YouTube channel, and encourages new videos to be uploaded.
=================
Visit my site to get more collaborative posts about Oracle Apex and subscribe to my YouTube channel. Thanks.
Comment on any of your issues, I will try my best to solve the problem, In-Shah Allah. Everyone's cooperation is desirable.
Visit my blog site, new technology-related videos, you will get different types of tutorials of Oracle Apex, and hopefully, you can use them in your daily work.
==============================

🙍🏾‍ Md jABER HOSSEN
📲 Mobile- +8801760688286
📨 Email- jaberit786@gmail.com
🌐 FB- facebook.com/mdjaber.hossen1
Please Subscribe to My Channel

Many thanks for visiting the site.

Then Enjoy.........................

1 Comments

Hlo Sir

  1. I have a table with 10 columns, in the grid I only want to show 5 and export others, not necessarily the ones that appear in the grid

    ReplyDelete
Previous Post Next Post