3 Replies Latest reply on Aug 15, 2019 9:21 AM by 1002933

    Multiple files upload and download at line level in master details form

    1002933

      Dear All,

       

      I got requirement to have a multiple attachments at each line level in Master details form, eg. Details level we have 4 rows and each row must have 4 attachments upload and download option in forms 10g ,please suggest.  

       

      Thanks in advance.

        • 1. Re: Multiple files upload and download at line level in master details form
          Kanda-Oracle

          Hi

           

          Can you share is it specific to EBS (12.1.3 or 12.2) or stand alone forms 10g

           

          Thanks!

          • 2. Re: Multiple files upload and download at line level in master details form
            1002933

            Dear Friend please find below version details its EBS 12.1.3

             

            Application : System Administration

            Responsibility : RECEIVABLES ADMINISTRATOR

            Security Group : Standard

            User Name : TEST_DB

             

            ----------------------------------------

            Database Server

            ----------------------------------------

            RDBMS : 11.2.0.4.0

            Oracle Applications : 12.1.3

            System Date : ***********

             

            ----------------------------------------

            Forms

            ----------------------------------------

            APPSTAND : 12.0.6.12010000.6

            FNDCPMPE : 12.0.0

            FNDSCSGN : 12.0.15.12010000.10

             

            ----------------------------------------

            Form Menus

            ----------------------------------------

            FNDMENU : 12.0.2.12010000.6

             

            ----------------------------------------

            Forms PL/SQL

            ----------------------------------------

            APPCORE : 12.0.29.12010000.22

            CUSTOM : 12.0.0

            FNDSQF : 12.0.3.12010000.8

            GHR : 12.0.46.12010000.81

            GLOBE : 12.0.62.12000000.11

            GMS : 12.0.51.12010000.8

            IGILUTIL2 : 12.0.32

            IGILUTIL : 12.0.3

            OPM : 12.0.7.12010000.2

            PQH_GEN : 12.0.7

            PSA : 12.0.17

            PSAC : 12.0.5

            PSB : 12.0.2

            VERT1 : 12.0.0

            VERT2 : 12.0.0

            VERT3 : 12.0.0

            VERT4 : 12.0.0

            VERT5 : 12.0.0

            VERT : 12.0.0

            ____________________________________________

            Form Builder 32-Bit

             

            Forms [32 EE] 10.1.2.0.2

            Oracle Toolkit 10.1.2.0.2

            PL/SQL 10.1.0.4.2

            Oracle Procedure Builder V10.1.2.0.2 - Production

            PL/SQL Editor (c)

            Oracle Query Builder 10.1.2.0.2 - Production

            Oracle Virtual Graphics System 10.1.2.0.2 ()

            Oracle Tools GUI Utilities 10.1.2.0.2 ()

            Oracle Multimedia 10.1.2.0.2 ()

            Oracle Tools Integration 10.1.2.0.2 ()

            Oracle Tools Common Area 10.1.2.0.2

            Oracle CORE    10.1.0.4.0    Production

             

            Thanks in advance.

            • 3. Re: Multiple files upload and download at line level in master details form
              1002933

              got Solution Alhamduillah --

               

               

              Using seeded Generic File Manager Upload and Download features

               

              Upload Button Code:

               

              Now, the underlying code of this button is as shown below

               

              DECLARE

              access_id        NUMBER;

              button_choice      NUMBER;

              l_gfm_id         NUMBER := NULL;

              l_file_id        VARCHAR2(256);

              l_parameters           varchar2(255);

              l_server_url       VARCHAR2(255);

              BEGIN

              access_id := fnd_gfm.authorize(null);

              fnd_profile.get('APPS_WEB_AGENT', l_server_url);

               

              l_parameters :='access_id='||access_id||'&l_server_url='||l_server_url;

               

              fnd_function.execute

              (

                FUNCTION_NAME=>'FND_FNDFLUPL',

                OPEN_FLAG => 'Y',

                SESSION_FLAG => 'Y',

                OTHER_PARAMS =>l_parameters

              );

               

              FND_MESSAGE.set_name('FND','ATCHMT-FILE-UPLOAD-COMPLETE');

               

              button_choice := FND_MESSAGE.question(

                  button1=> 'YES',

                  button2=> null,

                  button3=> 'NO',

                  default_btn => 1,

                  cancel_btn =>3,

                  icon=> 'question');

               

              IF ( button_choice = 3 ) THEN

                fnd_message.debug('File upload has failed! Please re-try again');

              ELSIF ( button_choice = 1 ) THEN

                l_gfm_id := fnd_gfm.get_file_id(access_id);

                IF l_gfm_id IS NOT NULL THEN

                

                 select decode(instr(file_name,'/'),0,file_name,

                              substr(file_name,instr(file_name,'/')+1))

                 into   l_file_id

                 from   fnd_lobs

                 where  file_id = l_gfm_id;

                

                 l_file_id := REPLACE(l_file_id, ' ', '_');

                END IF; 

              END IF;

              END;

               

              Download Button Code:

               

              DECLARE

               

                l_gfm_id  NUMBER;

               

                gfm_agent VARCHAR2(255);

               

                l_url  VARCHAR2(2000);

               

              BEGIN

               

                l_gfm_id := <PUT YOUR FILE ID VALUE HERE>;

               

                gfm_agent := fnd_web_config.gfm_agent;

               

                l_url := fnd_gfm.construct_download_URL(gfm_agent, l_gfm_id, FALSE);

               

                fnd_utilities.open_url(l_url);

               

              END;

               

               

              Many thanks for support & Courage..