zoukankan      html  css  js  c++  java
  • Get_File_Name Usage in Oracle Forms 6i

    Get_File_Name is built-in function of Oracle Forms 6i, used to get the file name with address by browsing the file. You can browse a specific extension name file or with multiple extensions using wild cards.
     
    In this example I am showing three different usage of Get_File_Name function, one is given for to get any Csv file name into a display field, second is given to read image files into an image item and third is for sound item.
     
    Below is the screen shot for this example:
     
     
    You can also download this form from the following link: GetFileName.fmb

    Write the following code on When-Button-Pressed trigger for Browse CSV Files button:
     
    declare
    filename varchar2(500);
    begin
    filename := GET_FILE_NAME(File_Filter=> 'CSV Files
    (*.Csv)|*.Csv|');

    :block2.txtfile := filename;

    end;

    Write the following code on When-Button-Pressed trigger for Upload Image button:
     
    declare
    filename varchar2(500);
    begin
    filename := GET_FILE_NAME(File_Filter=> 'Jpg Files
    (*.jpg)|*.jpg|Gif Files (*.gif)|*.gif|All Files (*.*)|*.*|');

    READ_IMAGE_FILE(filename, 'JPEG', 'block2.image9');
    end;


    Write the following code on When-Button-Pressed trigger for Browse Wave button:
     
    declare
    filename varchar2(500);
    begin
    filename := GET_FILE_NAME(File_Filter=> 'Wav Files
    (*.wav)|*.wav|All Files (*.*)|*.*|');

    READ_sound_FILE(filename, 'wave', 'block2.sound_item11');
    play_sound('block2.sound_item11');
    end;
    Like us to get notifications for free source code in future, thanks.
  • 相关阅读:
    软件补丁问题(网络流24题)
    飞行员配对方案问题(网络流24题)
    [NOIp普及组2011]瑞士轮
    如何在Linux上安装QQ
    [洛谷P2420] 让我们异或吧
    高斯消元
    [SCOI2014]方伯伯的OJ
    [USACO1.3]虫洞
    KMP算法讲解
    [洛谷P1382] 楼房
  • 原文地址:https://www.cnblogs.com/quanweiru/p/6220206.html
Copyright © 2011-2022 走看看