Not able to create a text file in Client Machine using Forms 10g

Hi - I'm mot able to create a text file in Client Machine using Forms 10g. I'm getting error when system executes the bolded line.(i.e. CLIENT_TEXT_IO.FOPEN). During run-time system is throwing "ORA-06508: PL/SQL: could not find program unit being called".
I had attached webutil.pll in the form.
Please advise me.
DECLARE
l_Temp CLIENT_TEXT_IO.FILE_TYPE;
LC$Name Varchar2(100) ;
LC$Fic Varchar2(100) ;
LN$Lines Pls_integer := 0 ;
LC$Line Varchar2(4000) ;
Cursor C_CUR Is
Select * From TEST_TEXTIO where rownum <= 50;
BEGIN
LC$Name := 'tmp_file.txt' ;
LC$Fic := 'c:\temp\tmp_file.txt';
Begin
l_temp := CLIENT_TEXT_IO.FOPEN( 'C:\temp\tmp_file.txt', 'W');
Exception
     when others then
     message( 'OPEN FILE ERROR ' || LC$Fic ||sqlerrm );
     display_error;
     raise form_trigger_failure;
End ;
-- Write the lines --
For Cur In C_CUR Loop
     LC$Line := Cur.CODE || ' -> ' || Cur.COL1 || ',' || Cur.COL2 || ',' || Cur.Col3 ;
     CLIENT_TEXT_IO.PUT_LINE( LF$File, LC$Line ) ;      
     LN$Lines := C_CUR%ROWCOUNT ;
End loop ;
-- Close the file --
CLIENT_TEXT_IO.FCLOSE( LF$File ) ;
Exception
     When others Then
message('err='||sqlerrm);message(' ');
display_error;
CLIENT_TEXT_IO.FCLOSE( LF$File ) ;      
     Raise ;
END;
Thanks.
Arun

Hi ,
i have one Question though its not related to thos question if some could help me it will be really helpful,
i have created one program to import and export excel to forms vice versa, if the form is attached with webutil its working fine am using ole2.but i have a new idea if i add this program in menu, it can be used for all the forms attched to that menu, i made program also, but problem am facing right now is if the form is not attched with webutil it will not work so is there possiblity to share my webutil from one form to another form ,so i will keep one form as a interface form in that webutil will be attched ,i can share that webutil to all other forms so that all the forms no need to attach webutil again
if its possible means please suggest some ideas

Similar Messages

  • Open bat file on client machine using webutil

    Hi all.
    I'm on devsuite 10g.
    I want to run a bat file on client machine using client_host function of webutil.
    I have tried first to execute the bat file with mouse double-click in order to check if it is ok, and it works.
    Now I want to execute this file from my form using webutil.
    Here is my code:
    --> with this code I select a file from client machine
    Declare
         LC$Fichier Varchar2(1000):=null ;
         PC$Filtre Varchar2(2000) := '|All files|*.*|' ;
    Begin
         LC$Fichier := WEBUTIL_FILE.FILE_OPEN_DIALOG
         null,
         PC$Filtre,
         'Seleziona un file da caricare'
    If LC$Fichier is not null Then
    :output.apri_file := LC$Fichier ;
    End if ;
    End ;
    --> with this code I execute the file that I have opened
    declare
         cmd varchar2(30000) := null;
    BEGIN
         Cmd := 'cmd /c start "" "' || :output.apri_file || '"' ;
    CLIENT_HOST(cmd);
    END;
    When I execute my form I have this error:
    Exception in thread "main" java.lang.NoClassDefFoundError: ....folder of file opened.
    Can anyone help me to solve this problem??
    Thanks in advance,
    Fabrizio

    Fabrizio Delli Priscoli wrote:
    Hi Tony.
    I have tried to run my bat file with double-click and everything is OK.
    When you say the DOS window opens for few second, is your batch file being executed?? did you see the results??
    The answer in NO for both of your questions.
    If I try to drag and drop the file I have error.
    How can I attach an image to this post, so that you can see the error??
    Thanks,
    FabrizioThis seems like a directory or OS level permission issue on the batch file, What is the error you got when you tried drag and drop the batch file in an DOS window???
    I think you need to upload the image to a site and use the markup for the image, include the full URL of the uploaded file between ! (exclamation marks) something like ! http://../post.gif ! without the spaces.
    Tony
    Edited by: Tony Garabedian on Sep 4, 2008 12:30 PM

  • Creation of Text File on Client Machine

    I am using Oracle 11i EBS and I have a requirement to create a text file on the client's machine. The name of the file is suppose to be on a particular format (DDMMYY.TXT). It is an urgent requirement from our client and we need to go live in 3 days. Kindly helP me out.
    Regards

    Hi Hussain,
    I need to extract data from Oracle Applications table and then this data had to export in text file. User wants to do this through Oracle application front end. If you want more detail please let me know.
    Thanks

  • Download a text file to client machine

    Hello everyone,
    I'm trying to implement a report in EP6 SP2 version using Dynpage. I have it working perfectly, where in it displays the result in a Tree Format. But now the client wants a button, on clicking which it should download everything in a text file. I'm thinking of creating a text file and using FileOutputStream dumping the data into a text file. But I dont know how to open that text file or download it to the client machine ?
    Can someone helpme with this ?
    Thanks.

    Another thing you can do is create a table that you can insert the results of the UTL_FILE export. This table will basically track all of your UTL_file exports. You would just have to have three columns in the table. An ID, Filename, Directory. The ID would be your Primary Key, Filename would be the name of the file, and the Directory, would be directory in which the file is in. Then you can build a portal dynamic page that selects the results with a hyperlink. Then everything will work dynamically. Let me know if you have any questions.
    Thanks,
    Martin

  • How to write files on Client Machine using JSP

    Hi,
    I am new to JSP. Please tell me how do i write files on Client machine thru a Browser.
    Please let me know at the Earliest.
    Thanks.
    Mehul Dave

    1) Well I find it rather convenient to deploy a web app as just one file rather than a bunch of files. For deployment it's much better. However I prefer using expanded files when developping (to use auto reload in Tomcat for example)
    2) It is a bad idea to upload files inside your webapp's context (ie: in it's deployment directory) because one day an uninformed system administrator might come and redeploy the web app and therefore delete all your uploaded files (believe me, I've already experienced this!)
    What i do usually is upload it in a completely different directory, something like /uploaded_files. Your uploaded files are therefore completely independant from your webapp
    However it is a bit trickyer to get those files back. Let's take the example of image uploads. You have 2 ways of proceeding:
    - the easiest : configure your web server (apache etc...) to redirect a certain url to your external directory. For example the /upload url will point to a /uploaded_files directory. This is easier to do and the fastest way to serve images but not always the best solution: you are dependant on the web server's configuration and you can't control the visibility on your files (no security constraints, anyone can see your uploaded files if they know the url).
    - you can also write a servlet which will load the file as an array of bytes and send it back in the response.
    You can call it this way :
    <img src="/serlvets/showmyimage?path=uploaded.gif">
    in this way you can control your uploaded files better: you may want to define security constraints on the visibity or not of uploaded files depending on the user which has logged on the site.

  • Not able to create New Transformation file in BPC

    I am getting error in BPC 10.0 when creating new transformation file from the EPM tab in Excel.
    When i click on create New transformation then some garbage value appear on the Excel cells. Problem with Authorization is not the case as i have checked all the authorizations in BI and BPC.
    Attached is the screen shot of the same.

    Hello Nidheesh,
    Can you check in UJFS Tcode whether you have file named newconversiontable.xlt and newtransformation.xlt in \ROOT\WEBFOLDERS\ADMINTEMPLATES.
    Also can you check the Language settings of yours in Excel Option
    Regards
    Bhagyesh Ravange

  • Not able to create a new project (i.e Manage - Project ) in 10g

    Hi Team
    I am trying to create a new project to implement Multi User Development Environment (MUDE) , but facing the below problems while doing so : -
    a:> While Opening repository in Online Mode :-
    I am not able to open open Manage --> Projects ( as Projects is disabled for me i. grayed out )
    b:> While opening in Offline Mode :-
    I am able to navigate to Manage --> Projects , but when the Project Windows opens and I am doing Actions --->New Project not able to do so ( as New Project is disable i.e grayed out ) .
    Please guide.
    Thanks
    Rohit

    Hi Friends
    Actually there was a mistake on my part ... i.e I had opened the repositorty in offline while BI server was still running !
    how silly . ..:)
    I am now getting the options .
    Regards
    Rhit

  • FND function to create .csv data file on client machine?

    Hello All,
    I am trying to create a concurrent request which when run by the user's creates a .csv file with data. I created a procedure in the database which run's when they run the conc.request.
    However is there any FND function or anyother function available that creates the data file on the client machine (either in their 'C:\') or in a share drive etc?
    Currently through the procedure, I am able to write the .csv data file to a unix directory to which users do not have access.
    Thanks,
    Chiru

    Chiru,
    Several options for you to consider are :
    1. If you want to have the csv on client machine: Make the program to create the csv in server with a constant name, eg : test.csv and create a dos command in client's machine that is could FTP to server, rename the existing csv file in client's machine and get test.csv from server.
    2. If you want to do in share drive : As long as the share drive exists in PC that can be used for FTP, you can create unix host script that can FTP the file to the windows server. For instance, create a generic unix host script that accepts parameter such as filename, and server destination, destination folder, unix login ,password, etc. This program will run in a request set after your concurrent program. If you search google I'm sure you will find samples of unix script that does this kind of thing.
    3. As per what Kevin said ,another options is to send the csv file using email to the recipients.
    HTH

  • Creating excel file on client machine using oracle pl/sql code

    Hi All,
    I have a situation where in i need to create an excel output file in my client machine, but using UTL_FILE i understood that i need to create the directory on server and i need to read and write on server itself.
    Is there any other way where we can create a excel file other than oracle server, bcos this is used only once and there is no scheduler to execute on server.
    Please do the needful.
    Thanks,
    Santhosh.S

    santhosh.shivaram wrote:
    I have a situation where in i need to create an excel output file in my client machine, but using UTL_FILE i understood that i need to create the directory on server and i need to read and write on server itself.I would say that you only need to to look at basic client-server architecture - what is the client component responsible for and what is the server component responsible for.
    The server should create the data set required by the client - do all the (intense) server processing that servers do well. This data set is then send to the client. The client is responsible for rendering that data set.. or saving it to the client machine storage if needed.
    Within PL/SQL that is quite easy to do using the most common/standard client-server in use today - web based client-server.
    The client is a web browser. It makes a call to the web server, that is serviced by a PL/SQL database procedure - a so-called web enabled procedure. It processes the request from the web browser, and returns a dynamic response. This response can range from HTML and XML, to video and image streams - and also CSV (Character Separated Values) data.
    By default, most web browsers will use the local client spreadsheet application (like MS Excel) to open the CSV response received. Many web browsers will also provide an alternate option of saving that response as a CSV file (that can then be opened later using MS Excel).
    Straight forward and basic client-server - and easily done using PL/SQL. Even easier done using (freeware) Oracle APEX (Application Express). APEX is a PL/SQL software suite that provides a web development system (only web browser required for development) and a run-time system to run the web application you have created.

  • Create sql trace files on client machine

    Hi
    oracle creates sql trace files on server side, what are possible and best ways of sharing those files with end users? is it possible to create them on client side instead?

    Dbb wrote:
    Hi
    Hi
    oracle creates sql trace files on server side,
    Yes
    what are possible and best ways of sharing those files with end users?
    Using shared directory. Use the parameters dump to point to it
    is it possible to create them on client side instead?
    No
    . :-) any help with my english is wellcome :-) .does this mean sharing user_dump destination at linux level and then mounting it from client machines ( win xp )?is there any doc on this?

  • How to create a Log file on Client machine

    Hi All,
    I am trying to create a log file on my local machine using TEXT_IO.FILE_TYPE in a stored procedure but it is throwing a compiler error as Error(5,10): PLS-00201: identifier 'TEXT_IO.FILE_TYPE' must be declared. I seem it is occuring because of WebUtil and I am using Oracle SQL Developer on my machine.
    Is there any way to create log file on local machine.Can anyone help me out, Since three day I am struging to get out from this.
    With regards
    R e h a n

    Hi,
    TEXT_IO.FILE_TYPE Package is used in Oracle Forms. Please Post in the relevant Forum for Questions for these.
    Forms
    You can Use the UTL_FILE in PL/SQL to create Log Files on the database server directory and Share the directory.
    Thanks,
    Shankar.

  • How to view the pdf files stored in client side using  forms 10g

    Hi All,
    I am using webutil to upload and download the blobs from database. I susccessfully uploaded/downloaded the blobs from database to client(d:\temp.one.pdf)
    Now I want to view the download pdf through form.
    Can anyone help me regarding this?

    I have tested the sql and found that there are no records in the table in which iam uploading the file
    In the form, I am joing tow tables mapping with rpt_num
    Even after adding information for the image table like image_no,image_name and
    when i click on upload to db icon. it gives me the same error WUT-113
    I think I need to save this basic information first and then upload the file
    can you please advise where can i add this code to save the data first
    below is the code iam using to upload the file from database
    PROCEDURE UPLOAD_DB IS
    l_success boolean;
    BEGIN
    l_success := webutil_file_transfer.Client_To_DB_with_progress
    (clientFile => :images.file_name
    ,tableName => images'
    ,columnName => 'RPT_IMAGE'
    ,whereClause => 'RPT_NUM = ''' || :PVT.PVT_SA_RPT_NUM || ''''
    ,progressTitle => 'Upload to Database in progress'
    ,progressSubTitle=> 'Please wait'
    ,asynchronous => false
    ,callbackTrigger => null
    if l_success
    then
    message('File uploaded successfully into the Database');
    else
    message('File upload to Database failed');
    end if;
    exception
         when others
         then
         message('File upload failed: '||sqlerrm);
    END;

  • Not able to create EAR file for WAR file extracted project

    Hi Experts,
    I am trying to import a WAR file, make changes to the project and create an EAR file for the same. I am not able to remove import
    errors despite of adding required jar files to it.
    Also, I am not able to create an EAR file for the same.
    I have copied the steps here with screen shots. Below are the steps :
    Import WAR file in NWDS 7.3 – Enterprise Portal perspective
    Select WAR file to create WAR and EAR project for it.
      Project created with import errors.     e.g – com.sapportals.portal.prt*
    Found jar file from Class – target jar file table. 
    e.g – for Class com.sapportals.portal.prt.resource.IResource needed jar file is tc~epbc~prt~api.jar
    Copied required jar files in WEB-INF -> lib folder.
    Configure Build path and Add External jars.
    Portalapp file screen shot
    I think errors should go now, but they still exist.
    Next I right click on WAR project and tried updating related EAR project.
      Next, Export EAR file from EAR project.
       I have tried both EAR types.
    But EAR file is not created.
    Please help me in removing the errors.
    Thanks in advance :-)
    Anubha Pandey

    Hi Anubha,
    I feel that you're missing JAR dependencies and hence not able to resolve the above import errors.
    Please go through the below thread for the AFP Masthead customization and follow the same:
    How to download and change AFP Masthead on SAP Portal 7.3
    Hope, this will help!!!
    BR,
    Anurag

  • How to FTP a file from client machine to database server using forms 10g

    Hi
    I want to ftp a file from a client machine to the database server machine using forms 10G (or PL/SQL).
    could you please tell me how can I do this
    Regards

    hi
    How to get up and running with WebUtil 1.06 included with Oracle Developer Suite 10.1.2.0.2 on a win32 platform
    Solution
    Assuming a fresh "Complete" install of Oracle Developer Suite 10.1.2.0.2,
    here are steps to get a small test form running, using WebUtil 1.06.
    Note: Oracle_Home is used as an alias for your real oDS ORACLE_HOME.
    Feel free to copy this note to a text editor, and do a global find/replace on
    Oracle_Home with your actual value (no trailing slash). Then it is easy to
    copy/paste actual commands to be executed from the note copy.
    1) Download http://prdownloads.sourceforge.net/jacob-project/jacob_18.zip
    and extract to a temporary staging area. Do not attempt to use 1.7 or 1.9.
    2) Copy or move jacob.jar and jacob.dll
    C:\webutile is the folder where you extracted Jacob, and will end in ...\jacob_18
    cd C:\webutile
    copy jacob.jar Oracle_Home\forms\java\.
    copy jacob.dll Oracle_Home\forms\webutil\.
    The Jacob staging area is no longer needed, and may be deleted.
    3) Sign frmwebutil.jar and jacob.jar
    Open a DOS command prompt.
    Add Oracle_Home\jdk\bin to the PATH:
    set PATH=Oracle_Home\jdk\bin;%PATH%
    Sign the files, and check the output for success:
    Oracle_Home\forms\webutil\sign_webutil Oracle_Home\forms\java\frmwebutil.jar
    Oracle_Home\forms\webutil\sign_webutil Oracle_Home\forms\java\jacob.jar
    4) If you already have a schema in your RDBMS which contains the WebUtil stored code,
    you may skip this step. Otherwise,
    Create a schema to hold the WebUtil stored code, and privileges needed to
    connect and create a stored package. Schema name "WEBUTIL" is recommended
    for no reason other than consistency over the user base.
    Open Oracle_Home\forms\create_webutil_db.sql in a text editor, and delete or comment
    out the EXIT statement, to be able to see whether the objects were created witout
    errors.
    Start SQL*Plus as SYSTEM, and issue:
    CREATE USER webutil IDENTIFIED BY [password]
    DEFAULT TABLESPACE users
    TEMPORARY TABLESPACE temp;
    GRANT CONNECT, CREATE PROCEDURE, CREATE PUBLIC SYNONYM TO webutil;
    CONNECT webutil/webutil@rcci
    @Oracle_Home\forms\create_webutil_db.sql
    -- Inspect SQL*Plus output for errors, and then
    CREATE PUBLIC SYNONYM webutil_db FOR webutil.webutil_db;
    Reconnect as SYSTEM, and issue:
    grant execute on webutil_db to public;
    5) Modify Oracle_Home\forms\server\default.env, and append Oracle_Home\jdk\jre\lib\rt.jar
    to the CLASSPATH entry.
    6) Modify Oracle_Home\forms\server\formsweb.cfg insde [default] add :
    archive_jini=frmall_jinit.jar,frmwebutil.jar,jacob.jar
    archive=frmall.jar
    also add :
    [webutil]
    WebUtilLogging=off
    WebUtilLoggingDetail=normal
    WebUtilErrorMode=Alert
    WebUtilDispatchMonitorInterval=5
    WebUtilTrustInternal=true
    WebUtilMaxTransferSize=16384
    baseHTMLjinitiator=webutiljini.htm
    baseHTMLjpi=webutiljpi.htm
    baseHTML=webutilbase.htm
    archive_jini=frmall_jinit.jar
    WebUtilArchive=frmwebutil.jar,jacob.jar,f90all.jar
    archive=frmwebutil.jar,f90all.jar
    lookAndFeel=oracle
    7) Modify Oracle_Home\forms\server\webutil.cfg and add :
    transfer.database.enabled=TRUE
    transfer.appsrv.enabled=TRUE
    8) Start the OC4J instance
    9) Start Forms Builder and connect to a schema in the RDBMS used in step (4).
    Open webutil.pll, do a "Compile ALL" (shift-Control-K), and generate to PLX (Control-T).
    It is important to generate the PLX, to avoid the FRM-40039 discussed in Note 303682.1
    If the PLX is not generated, the Webutil.pll library would have to be attached with
    full path information to all forms wishing to use WebUtil. This is NOT recommended.
    10) Create a new FMB.
    Open webutil.olb, and Subclass (not Copy) the Webutil object to the form.
    There is no need to Subclass the WebutilConfig object.
    Attach the Webutil.pll Library, and remove the path.
    Add an ON-LOGON trigger with the code
    NULL;
    to avoid having to connect to an RDBMS (optional).
    Create a new button on a new canvas, with the code
    show_webutil_information (TRUE);
    in a WHEN-BUTTON-PRESSED trigger.
    Compile the FMB to FMX, after doing a Compile-All (Shift-Control-K).
    11) Under Edit->Preferences->Runtime in Forms Builder, click on "Reset to Default" if
    the "Application Server URL" is empty.
    Then append "?config=webutil" at the end, so you end up with a URL of the form
    http://server:port/forms/frmservlet?config=webutil
    12) Run your form.

  • Store and Display doc/pdf files in the database using Forms

    Hi all,
    How can i store and display doc/pdf files in the database using Forms 10g?.
    Arif

    How to get up and running with WebUtil 1.06 included with Oracle Developer Suite 10.1.2.0.2 on a win32 platform
    Solution
    Assuming a fresh "Complete" install of Oracle Developer Suite 10.1.2.0.2,
    here are steps to get a small test form running, using WebUtil 1.06.
    Note: [OraHome] is used as an alias for your real oDS ORACLE_HOME.
    Feel free to copy this note to a text editor, and do a global find/replace on
    [OraHome] with your actual value (no trailing slash). Then it is easy to
    copy/paste actual commands to be executed from the note copy.
    1) Download http://prdownloads.sourceforge.net/jacob-project/jacob_18.zip
      and extract to a temporary staging area. Do not attempt to use 1.7 or 1.9.
    2) Copy or move jacob.jar and jacob.dll
      [JacobStage] is the folder where you extracted Jacob, and will end in ...\jacob_18
         cd [JacobStage]
         copy jacob.jar [OraHome]\forms\java\.
         copy jacob.dll [OraHome]\forms\webutil\.
      The Jacob staging area is no longer needed, and may be deleted.
    3) Sign frmwebutil.jar and jacob.jar
      Open a DOS command prompt.
      Add [OraHome]\jdk\bin to the PATH:
         set PATH=[OraHome]\jdk\bin;%PATH%
      Sign the files, and check the output for success:
         [OraHome]\forms\webutil\sign_webutil [OraHome]\forms\java\frmwebutil.jar
         [OraHome]\forms\webutil\sign_webutil [OraHome]\forms\java\jacob.jar
    4) If you already have a schema in your RDBMS which contains the WebUtil stored code,
      you may skip this step. Otherwise,
      Create a schema to hold the WebUtil stored code, and privileges needed to
      connect and create a stored package. Schema name "WEBUTIL" is recommended
      for no reason other than consistency over the user base.
      Open [OraHome]\forms\create_webutil_db.sql in a text editor, and delete or comment
      out the EXIT statement, to be able to see whether the objects were created witout
      errors.
      Start SQL*Plus as SYSTEM, and issue:
         CREATE USER webutil IDENTIFIED BY [password]
         DEFAULT TABLESPACE users
         TEMPORARY TABLESPACE temp;
         GRANT CONNECT, CREATE PROCEDURE, CREATE PUBLIC SYNONYM TO webutil;
         CONNECT webutil/[password]@[connectstring]
         @[OraHome]\forms\create_webutil_db.sql
         -- Inspect SQL*Plus output for errors, and then
         CREATE PUBLIC SYNONYM webutil_db FOR webutil.webutil_db;
      Reconnect as SYSTEM, and issue:
         grant execute on webutil_db to public;
    5) Modify [OraHome]\forms\server\default.env, and append [OraHome]\jdk\jre\lib\rt.jar
      to the CLASSPATH entry.
    6) Start the OC4J instance
    7) Start Forms Builder and connect to a schema in the RDBMS used in step (4).
      Open webutil.pll, do a "Compile ALL" (shift-Control-K), and generate to PLX (Control-T).
      It is important to generate the PLX, to avoid the FRM-40039 discussed in
      Note 303682.1
      If the PLX is not generated, the Webutil.pll library would have to be attached with
      full path information to all forms wishing to use WebUtil. This is NOT recommended.
    8) Create a new FMB.
      Open webutil.olb, and Subclass (not Copy) the Webutil object to the form.
      There is no need to Subclass the WebutilConfig object.
      Attach the Webutil.pll Library, and remove the path.
      Add an ON-LOGON trigger with the code
             NULL;
      to avoid having to connect to an RDBMS (optional).
      Create a new button on a new canvas, with the code
             show_webutil_information (TRUE);
      in a WHEN-BUTTON-PRESSED trigger.
      Compile the FMB to FMX, after doing a Compile-All (Shift-Control-K).
    9) Under Edit->Preferences->Runtime in Forms Builder, click on "Reset to Default" if
      the "Application Server URL" is empty.
      Then append "?config=webutil" at the end, so you end up with a URL of the form
          http://server:port/forms/frmservlet?config=webutil
    10) Run your form.sarah

Maybe you are looking for