Print report from client machine without showing in screen

Hi guys!!
I m using (forms10g+ 10gAS). I want to Print report from client machine without showing in the screen/monitor.
Currently I m generating report in pdf format. From the pdf I m printing the document.
But my requirements is to print directly to the printer without showing preview
Thanks in advance
Mokarem

Maybe this will help:
http://forums.oracle.com/forums/thread.jspa?messageID=1209371&#1209371
Gary

Similar Messages

  • Running Reports from Client Machines in which the reports are residing on t

    Hi Folks,
    I'm using Developer 6i with Oracle 9i. I can run forms from the clients so that the FMX file is residing on a shared drive on the server, but when I try to run reports which also reside on the shared drive of server, I get error that unable to find the report. Do I need to install report server on the client machine/server or am I missing some basic step here?
    TIA
    Hassan

    Hi,
    There's a whitepaper on the topic of Forms/Reports integration for the web called "Oracle9iAS Forms Services and Reports Services Integration". This should give you the information you are seeking.
    regards,
    Stewart

  • Is it possible to export (expdp) oracle table from client machine ?

    Is it possible to export (expdp*) oracle table from client machine, without using Remote desk top connection ?*
    1) Database-10g server is in America
    2) client machine is in India
    3) Oracle client-10g software is installed in my machine
    4) I am able to connect to the server, could see all tables
    5) one table is with 35 million record, I wanted to export this table using data pump, is it possible?
    note: without using Remort desk top connection.

    Hi
    I used the following syntax , but I am getting error
    6) connect sys as sysdba
    create directory test_dir as '/dbusr1/exp_test'
    grant read, write on directory test_dir to user1;
    7) expdp user1/pwd1@xyz tables=test_1 directory=test_dir dumpfile=test_file.dmp logfile=test_file.log
    8) Errors
    In linux prompt I am getting this error
    -bash: expdp: command not found
    In windows cmd prompt I am getting this error
    ORA-39002: invalid operation
    ORA-39070: Unable to open the log file.
    ORA-29283: invalid file operation
    ORA-06512: at "SYS.UTL_FILE";, line 488
    ORA-29283: invalid file operation
    9) why ?
    -- Does the user ( "user1") should have any system level privilege ? to export his own table?
    -- This folder ('/dbusr1/*exp_test'*) has write privilege in os level.
    Thanks in advance
    sbmk_design
    Edited by: sbmk_design on Aug 24, 2009 12:06 AM

  • BOE 4.0 Report Application Server Connectivity from client machine

    Hi,
    We have installed BO 4.0 for RAS. We configured the RAS to pick up the rpt files from local repository, that is from the machine which the Bo is installed.
    But when we try to access the RAS from client machine to process report it is not accepting the request,
    1. Do I need to grant access to any specific user group?
    2. What is the user id which the Report Application Service runs in the machine?
    3. Do I need to add / manage any guest acoount to request from client machine?
    4. How to accept other user request to process reports?
    Here is the error details,
    Message Number: -2147217397
    Message Description: The user account has been disabled. (FWB 00012)
    Please advise,
    Thanks,
    FebiginR
    Edited by: FebiginR on Jan 17, 2012 8:17 PM

    Thanks for your support.
    I searched in otn and i got the information
    http://www.oracle.com/technology/sample_code/products/forms/extracted/getclientinfo/readme.html?_template=/ocom/print
    1)But in Deployment section of this document the first point is copy entire sab and its subdirectories ........ot <oracle_home>\orant\forms60\java directory.
    I can't understand what is "sab" where should i look for it.
    2) Place the signed JavaBean JAR file (getclientinfo.jar.sig) in the codebase directory being used to deploy Oracle Forms Server 6i applications.
    Can you kindly explain this.
    3) where should we write <ARCHIVE = "f60all.jar, getclientinfo.jar.sig">
    Can you kindly explain this.
    Thanking you in anticipation.
    Regards,
    Devendra

  • How to download/save report from server machine to client machine?

    Hello All
    This is San,
    My problem is that i need to save pdf/html report in client machine while report running on client machine for this i have set destype as file and desformat as pdf/html.
    It is running and save automatically while report run on server machine (Application Server OS is Windows 20003 professional) but when i run it on client machine (Client machine OS is XP sp2) click on run button to run report then it give message as
    FRM-41214: Unable to run report
    When I do showjobs then it give message as
    Executed successfully but there were some errors when distribute the output<br>
    Please suggest me solution of the above mentioned.
    I am waiting for your reply.
    Thanks in Advance
    Edited by: user8752210 on Feb 11, 2011 11:46 PM

    Hello Mr.
    Thanks for quick reply.
    The e:\tempReport directory is on both app-server and client and it is shared folder, i am sending procedure that i have used as:
    PROCEDURE DOWNLOAD_AS IS
    l_success boolean;
    l_bare_filename varchar2(50);
    BEGIN
    --l_bare_filename := substr(:upload.file_name,instr(:download.file_name,'\',-1)+1);
    l_success := webutil_file_transfer.AS_to_Client_with_progress
    (clientFile => :GLOBAL.PATH3||:global.tmp--(\\client_ip_address\e:\tmpreports\file_name.html it is shared folder)
    ,serverFile => :GLOBAL.PATH2||:global.tmp--\\server_iip_address\e:\tmpreports\file_name.html it is shared folder)
    ,progressTitle => 'Download from Application Server in progress'
    ,progressSubTitle => 'Please wait'
    if l_success
    then
    message('File downloaded successfully from the Application Server');
    else
    message('File download from Application Server failed');
    end if;
    exception
         when others
         then
         message('File download failed: '||sqlerrm);
    END;
    Please suggest me what to do.
    Thanks

  • How to print report on client default printer ?

    I develop web application. I use jdev 10.1.3.4.0 . I can print report in PDF format.
    My Problem
    I can't print report on client default printer. when Client run application and print. Report is printed at server default printer
    How can I do.
    _My source code for print to PDF format._
    FacesContext context = FacesContext.getCurrentInstance();
    response = (HttpServletResponse)context.getExternalContext().getResponse();
    String urlSchema = "jdbc:oracle:thin:@localhost:1521:ORCL";
    String schemaName = "hr";
    String schemaPass = "hr;
    reportPath = "D:\\Project\\Reports";
    Class.forName("oracle.jdbc.driver.OracleDriver");
    conn = DriverManager.getConnection(urlSchema, schemaName, schemaPass);
    reportPath = reportPath.endsWith("\\") ? reportPath : (reportPath + "\\");
    input = new File(reportPath + reportName + ".jasper");
    reportParameters.put("SUBREPORT_DIR", reportPath);
    reportParameters.put("P_IMAGE_PATH", reportPath);
    jasperPrint = JasperFillManager.fillReport(input.getPath(), reportParameters, conn);
    response.setContentType("application/pdf");
    response.addHeader("Content-Disposition", "attachment;filename=" + reportNameOutput + ".pdf");
    OutputStream outputStream = response.getOutputStream();
    JasperExportManager.exportReportToPdfStream(jasperPrint, outputStream);
    outputStream.flush();
    outputStream.close();
    conn.close();{code}
    _My source code for print to *printer*._
    {code}FacesContext context = FacesContext.getCurrentInstance();
    response = (HttpServletResponse)context.getExternalContext().getResponse();
    String urlSchema = "jdbc:oracle:thin:@localhost:1521:ORCL";
    String schemaName = "hr";
    String schemaPass = "hr;
    reportPath = "D:\\Project\\Reports";
    Class.forName("oracle.jdbc.driver.OracleDriver");
    conn = DriverManager.getConnection(urlSchema, schemaName, schemaPass);
    reportPath = reportPath.endsWith("\\") ? reportPath : (reportPath + "\\");
    input = new File(reportPath + reportName + ".jasper");
    reportParameters.put("SUBREPORT_DIR", reportPath);
    reportParameters.put("P_IMAGE_PATH", reportPath);
    jasperPrint = JasperFillManager.fillReport(input.getPath(), reportParameters, conn);
    JasperPrintManager.printReport(jasperPrint, false);
    conn.close();Edited by: jaae251 on Jun 18, 2009 2:29 AM

    If you offer a PDF to the end user, they usually know what to do with it. OTOH, if you wish to provide software to facilitate the local printing, you might launch an application on the client side that accesses the JNLP API's PrintService - that can be done in a sandboxed application.
    A signed application might access the normal J2SE based print services. Though I heard that Sun had decided to make printing a 'prompt on first attempt' deal - even for sandboxed apps., from 1.5 plus (or was it 1.6 plus?).
    It would be a serious security bug if a web site could print on the client printer, without trust or active involvement from the end user.

  • Issue in XL reporter on Client machine

    Hi Experts
    I am facing issue in running XL reporter on client machine aftre upgrading patch 10 of SAP B1 2007 B.
    System shows following errro
    Run TIme Error 430
    Class does not support Automation or does not support expected interface.
    pls. help me out from this.
    Regards
    Kamlesh Vagal

    Hi,
    Please check this link:
    http://support.microsoft.com/kb/248404
    Thanks,
    Gordon

  • How to delete file from client machine

    Hi all,
    we are using the DataBase: oracle:10g,
    and forms/reports 10g(developer suite 10g-10.1.2.2).
    can anybody help me how to delete the file from client machine in specified location using webutil or any
    (i tried with webutil_host & client_host but it is working for application server only)
    thank you.

    hi
    check this not tested.
    PROCEDURE OPEN_FILE (V_ID_DOC IN VARCHAR2)
    IS
    -- Open a stored document --
    LC$Cmd Varchar2(1280) ;
    LC$Nom Varchar2(1000) ;
    LC$Fic Varchar2(1280);
    LC$Path Varchar2(1280);
    LC$Sep Varchar2(1) ;
    LN$But Pls_Integer ;
    LB$Ok Boolean ;
    -- Current Process ID --
    ret WEBUTIL_HOST.PROCESS_ID ;
    V_FICHERO VARCHAR2(500);
    COMILLA VARCHAR2(4) := '''';
    BOTON NUMBER;
    MODO VARCHAR2(50);
    URL VARCHAR2(500);
    Begin
    V_FICHERO := V_ID_DOC;
    LC$Sep := '\';--WEBUTIL_FILE.Get_File_Separator ; -- 10g
    LC$Nom := V_FICHERO;--Substr( V_FICHERO, instr( V_FICHERO, LC$Sep, -1 ) + 1, 100 ) ;
    --LC$Path := CLIENT_WIN_API_ENVIRONMENT.Get_Temp_Directory ;
    LC$Path := 'C:';
    LC$Fic := LC$Path || LC$Sep || LC$Nom ;
    If Not webutil_file_transfer.DB_To_Client
    LC$Fic,
    'TABLE_NAME',
    'ITEM_NAME',
    'WHERE'
    ) Then
    Raise Form_trigger_Failure ;
    End if ;
    LC$Cmd := 'cmd /c start "" /MAX /WAIT "' || LC$Fic || '"' ;
    Ret := WEBUTIL_HOST.blocking( LC$Cmd ) ;
    LN$But := WEBUTIL_HOST.Get_return_Code( Ret ) ;
    If LN$But 0 Then
    Set_Alert_Property( 'ALER_STOP_1', TITLE, 'Host() command' ) ;
    Set_Alert_Property( 'ALER_STOP_1', ALERT_MESSAGE_TEXT, 'Host() command error : ' || To_Char( LN$But ) ) ;
    LN$But := Show_Alert( 'ALER_STOP_1' ) ;
    LB$Ok := WEBUTIL_FILE.DELETE_FILE( LC$Fic ) ;
    Raise Form_Trigger_Failure ;
    End if ;
    If Not webutil_file_transfer.Client_To_DB
    LC$Fic,
    'TABLE_NAME',
    'ITEM_NAME',
    'WHERE'
    ) Then
    NULL;
    Else
    Commit ;
    End if ;
    LB$Ok := WEBUTIL_FILE.DELETE_FILE( LC$Fic ) ;
    Exception
    When Form_Trigger_Failure Then
    Raise ;
    End ;sarah

  • Excel output of report on client machine

    excel output report on client machine
    hello
    i am running report from app server, output is excel file...
    using following URL
    web.show_document(rpt_url ||'&report='||rpt_path||'batch_idcards_print_excel.rdf&desformat=spreadsheet&destype=file&desname=c:\batch.xls','_blank');
    ----this stores the excel file at app server under c:\
    now i want to save it on client machine... how can i do that ?
    from one forum, i got help , so i changed URL as below
    web.show_document(rpt_url ||'&report='||rpt_path||'batch_idcards_print_excel.rdf&desformat=spreadsheet&mimetype=application/msexcel&destype=FILE&title=batch.xls','_blank');
    when i open report, no window opens for saving file...a new window opens and gets closed itself immediately...
    wht is the problem?... client machine having MS office excel 2003...

    Dear
    Could you, please, tell us what you've done to solve this issue? We're facing the same problem, and until now we couldn't figure out what is exactly happening.
    Thanks in advance for any help.

  • How to restore from Time Machine WITHOUT install discs using a second Mac

    It's a question that is asked repeatedly all over the web by Mac users like me that bought in to Time Machine (TM) on the assumption that if their computer died one day it would be a piece of cake to restore from it, only for that day to come and then to be told "ahh, okay the first thing is to get your computers install discs..." (loud crashing sound of world falling around ears).
    I've never been able to afford a new Mac and both of my machines were bought second-hand. Neither came with Leopard (both have Tiger and have been upgraded to Leopard via the net). This was never supposed to be a problem as I've been backing up with TM. However it appears that Tiger discs are as much use as an inflatable dart board when it comes to using TM. So I've been faced with the possibility of having to spend £130 (about two hundred Pres Sheets, Yankees) on the Leopard install discs just so that I can have the option of restoring from TM. Bonkers.
    However after much nashing of teeth, a very long weekend learning all sorts of things about 'Target Mode', 'Single User Mode', 'Verbose Mode', 'Open Source 9' etc the following solution has worked without the need to go out and buy those over-priced discs...
    What you will need:
    1 broken Mac requiring restoration
    1 second donor Mac running Leopard (or Snow Leopard so long as the broken Mac can run it)
    1 firewire cable with the correct fitting at either end to attach both Macs together
    1 Time Machine backup
    Note: The following is for when you have given up trying to boot from your hard drive. In my case I couldn't boot in to Safe Mode etc. so was forced to format my drive and re-import everything. If you've read this far I'm assuming your at the same point as well and have tried everything else that's out there first.
    Also - both my Macs are Power PC's so can't run Snow Leopard, so I can't say 100% this will work with SL (Intel) machines. From what I've read Snow Leopard will work with this procedure too, but if you've found differently please feel free to add your experiences below...
    STEP ONE: Format the corrupt Hard Drive or replace with a fresh HDD
    *Link the two computers with a firewire.
    *If you're replacing your HDD, remove your corrupted hard drive from the 'broken' machine and insert a new one.
    *Power up the broken Mac whilst holding down the 'T' key. This will start it up in Target Mode and you'll get a nice firewire symbol floating around that machine's screen.
    *Power up the second 'healthy' Mac. This will be our 'donor' machine. When it starts up after a few seconds you will see the hard drive of the broken Mac appear on the donor Mac's desktop.
    *Using your donor Mac's 'Disc Utility', format the broken Mac's hard drive (now's the time to partition it etc. if you want to).
    STEP TWO: Clone your donor Mac
    Your broken Mac is no longer broken and now needs a new OS. But you don't have the discs, right? Well get this... you can clone your donor mac on to your machine, even if they are totally different i.e. a laptop on to a tower.
    *Again using Disc Utility, click on your donor Mac's hard drive. The restore tab appears as an option.
    *Click on restore and drag the donor Mac's hard drive that contains the operating system in to the Source box.
    *Drag the newly formatted hard drive on the broken Mac in to the Destination box.
    *Click restore. Your donor Mac's hard drive will now be 'cloned' on to your no-longer-broken Mac. Once this is done, eject the first Mac's hard drive from your donor Mac's desktop. You no longer need the donor Mac.
    Ta daa! Your machine now starts up happy and smily again. Time to restore all that stuff that's been sat on your Time Machine drive...
    STEP 3: Restore from Time Machine using Migration Assistant
    This is the really clever part that prompted me to write this piece in the first place. Time Machine IS accessible without those Leopard install discs you don't have. You need to use something called 'Migration Assistant'.
    *Start up your machine as normal and you'll see it is an exact clone of the donor machine. Weird huh?
    *Attach your Time Machine hard drive. It will show up as an icon on the desktop and because of it's size, you'll be asked if you want to use it as a Time Machine backup. Err, NO YOU DON'T! Click 'cancel'.
    *Open Migration Assistant (if you can't find it just type it in to Finder and click). There are three options, the middle one being to restore from TM or another disc. Yup, you want that one.
    *Migration Assistant will now ask you what you want to restore in stages, firstly User Accounts, then folders, Apps etc. It will even import internet settings
    And that's you done. Let Migration Assistant do it's thang... altogether I had about 140gb to restore, so it wasn't exactly speedy. This wasn't helped by the fact that my TM hard drive is connected via USB (yes, I know). Just leave it alone and it'll whirr happily away...
    Before I go - you don't have an option of when to restore from, and will restore from the last Time Machine save. At least then you should be able to access TM and go 'backwards' if you need to.
    Also - for a Mac expert, the above will be up there with 'Spot Goes To The Farm' in terms of complexity. However, for the rest of us the above is only available in fragments all over the net. By far the most common response to 'how do I restore from Time Machine without install discs' is 'you can't'. If I'd found the above information in one place I could have saved a lot of hair pulling and swearing over the last couple of days, so forgive me for sharing this workaround with the rest of the world. Meanwhile your expertise will come in very handy for the inevitable questions that will get posted below, so please feel free to help those people that won't be sure if this solution is the right one for them. I'm no expert, I just want to help people that were stuck in the same situation (and looking at the web, there's a LOT of them).
    Hope this is of use to someone, thanks and *good luck*!

    Most maintenance and repair, restore and install procedures require the use
    of the correct OS X install DVD; be it an original machine-specific restore/install
    disc set or a later retail non-specific general install disc set.
    By having an unsupported system, perhaps installed via an illegal download or
    other file-sharing scheme, where no retail official discs are involved and the
    initial upgrade was done by other means outside of the License Agreements,
    you are asking us to discuss a matter of illegal installation and use of a product.
    There are no legal complete OS X system download upgrades online; only bits
    that are update segments to a retail or as-shipped machine's original OS X install.
    +{Or an installation where a previous owner had correct retail upgrade discs, &+
    +chose to not include them with the re-sale of the computer it was installed in.}+
    However, to answer the initial question. To get and use an externally enclosed
    hard drive in suitable boot-capable housing, and get a free-running Clone
    Utility (download online; often a donation-ware product, runs free) you can
    make a bootable backup of everything in your computer to an external HDD.
    This is the way to make a complete backup to restore all functions to the computer.
    The Time Machine has some limits, in that it can restore only that which it saves.
    It does not make a bootable clone of your entire computer system with apps and
    your files, to an external drive device. A clone can. And some of the clone utility's
    settings can also backup changes to an external drive's system; if that other drive
    is attached to the computer correctly.
    Carbon Copy Cloner, from Bombich Software; and also SuperDuper, another of
    the most known software names you can download and use to clone boot-capable
    system backups of your computer's hard disk drive contents, are often cited.
    However you resolve the matter of the running OS X system in your computer,
    derived from what appears to be questionable means, is part of the initial issue.
    Since you do need to be able to fix an existing installation by unmounting the
    computer's hard disk drive and run the computer from the other (install disc or
    system clone) while it is Unmounted; and use the correct Disk Utility version to
    help diagnose and perhaps be able to fix it. You can't use a Tiger version Disk
    Utility to fix a Leopard installation, and so on.
    So, the situation and replies as far as they can go (since the matter does
    constitute an illegal system, if it was arrived at without correct discs) is a
    limited one. And file sharing of copied Mac OS X (and other) software is
    also considered illegal.
    And, one way to get odd malware and unusual stuff, is to get an unauthorized
    system upgrade from an illegal source online. You never know what's inside it.
    The other reply was not a personal attack; the matter is of legal status and as
    you have a product with a questionable system, the answer is to correct it.
    And if you want to save everything in your computer, make a clone to a suitable
    externally enclosed self-powered boot capable hard disk drive. With older PPC
    Macs, that would best be to one with FireWire and the Oxford-type control chips.
    However that works out...
    Good luck & happy computing!

  • Reading files from clients machine through a browser

    if i have to access or use some files say C:\hello\myimage.jpg from client machine's local drive, how it can be done using some technology in Java eg applets or some other way. please read the following situation to have a better undertsanding of the problem,
    consider the following situation:
    a web application is running on client PC, and on click of a button, i have to generate a report in some format and insert some images in that report which are on clients local drive and their path is known to me say C:\ myimage.jpg.
    if the mages were on the server(where web application is hosted), then its not a prob.
    if there any other technology in java to read files from clients PC through a browser other than java

    Sign the applet.
    http://forum.java.sun.com/thread.jspa?forumID=63&threadID=524815
    second and last post

  • Reg :File upload and download from client machine

    hi..
    anyone help me the way that how to upload and download word
    document file from client machine.. i am using j2eeserver1.4 in linux..
    i want upload file from client machine(windows) to server(linux.) please
    help me . tell me idea regarding..
    i have tried this coding.. but i can transfer txt file. only. when i upload mirosoft word file.. it will open with some ascii values with actual content.
    <!-- upload.jsp -->
    <%@ page import="java.io.*" %>
    <%String contentType = request.getContentType();
    String file = "";
    String saveFile = "";
    FileOutputStream fileOut = null;
    if ((contentType != null) && (contentType.indexOf("multipart/form-data") >= 0))
    DataInputStream in = new DataInputStream(request.getInputStream());
    int formDataLength = request.getContentLength();
    byte dataBytes[] = new byte[formDataLength];
    int byteRead = 0;
    int totalBytesRead = 0;
    while (totalBytesRead < formDataLength)
    byteRead = in.read(dataBytes, totalBytesRead, formDataLength);
    totalBytesRead += byteRead;
    try { 
    file = new String(dataBytes);
    saveFile = file.substring(file.indexOf("filename=\"") + 10);
    saveFile = saveFile.substring(0, saveFile.indexOf("\n"));
    saveFile = saveFile.substring(saveFile.lastIndexOf("/") + 1,saveFile.indexOf("\""));
    int lastIndex = contentType.lastIndexOf("=");
    String boundary = contentType.substring(lastIndex + 1,contentType.length());
    int pos;
    pos = file.indexOf("filename=/" + 1);
    pos = file.indexOf("\n", pos) + 1;
    pos = file.indexOf("\n", pos) + 1;
    pos = file.indexOf("\n", pos) + 1;
    int boundaryLocation = file.indexOf(boundary, pos) - 4;
    int startPos = ((file.substring(0, pos)).getBytes()).length;
    int endPos = ((file.substring(0, boundaryLocation)).getBytes()).length;
    String folder = "/tmp/uploads/";
    fileOut = new FileOutputStream(folder + saveFile);
    fileOut.write(dataBytes);
    fileOut.write(dataBytes, startPos, (endPos - startPos));
    fileOut.flush(); } catch(Exception e) {  out.print(e);
    } finally
    {  try
    {fileOut.close();
    }catch(Exception err)
    %>
    please which package will help me to upload word document file with no errror. send me how can use in ftp.. send me some sample program..
    Regards..
    New User M.Senthil..

    Hi,
    Well,i don't know whether if this helps people here are not.
    It is always a good practise to do it via Servlet and then download content.
    The adavantage of doing this is
    1). You may not need to pack the downloadable with the .war which you ultimately genrate which ceratinly help us in terms of faster deployment.
    3). You may update the new content just by moving a file to the backup folder.
    2).One may definately download the content irrespective to the content/file.
    Hope example below helps..
    Configurations:
    In the above example we are assuming that we placing all downlodable file in D:/webapp/downlodables/ and you have configured the same path as a init param with the name "filePath" in your web.xml.
    something like the one below.
    <servlet>
        <servlet-name>DownloadServlet</servlet-name>
        <servlet-class>com.DownloadServlet</servlet-class>
        <init-param>
           <param-name>filePath</param-name>
           <param-value>D:/webapp/downlodables/</param-name>
           <!--Could use any backup folder Available on your Server-->
        </init-param>
    </servlet>
    <servlet-mapping>
        <servlet-name>DownloadServlet</servlet-name>
        <url-pattern>/downloadFile</url-pattern>
    </servlet-mapping>DownloadServlet.java:
    ==================
    package com;
    import javax.servlet.ServletConfig;
    import javax.servlet.ServletException;
    import javax.servlet.http.HttpServlet;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import java.io.BufferedOutputStream;
    import java.io.File;
    import java.io.FileInputStream;
    import java.io.IOException;
    import javax.activation.MimetypesFileTypeMap;
    *@Author RaHuL
    /**Download Servlet
    *  which could be accessed downloadFile?fid=fileName
    *  or
    *  http://HOST_NAME:APPLN_PORT/ApplnContext/downloadFile?fid=fileName
    public class DownloadServlet extends HttpServlet{
      private static String filePath = new String();
      private static boolean dirExists = false;
      public void init(ServletConfig config){
          // Acquiring Backup Folder Part
          filePath = config.getInitParameter("filePath");
          dirExists = new File(filePath).exists();      
      private void processAction(HttpServletRequest request,HttpServletResponse response) throws Exception{
           // Some Authentication Checks depending upon requirements.
           // getting fileName which user is requesting for
           String fileName = request.getParameter("fid");
           //Building the filePath
           StringBuffer  tFile = new StringBuffer();
           tFile.append(filePath);    
           tFile.append("fileName"); 
           boolean exists = new File(tFile.toString()).exists();
           // Checking whether the file Exists or not      
           if(exists){
            FileInputStream input = null;
            BufferedOutputStream output = null; 
            int contentLength = 0;
            try{
                // Getting the Mime-Type
                String contentType = new MimetypesFileTypeMap().getContentType(tFile.toString());          
                input = new FileInputStream(tFile.toString());
                contentLength = input.available();
                response.setContentType(contentType);
                response.setContentLength(contentLength);
                response.setHeader("Content-Disposition","attachment;filename="+fileName);
                output = new BufferedOutputStream(response.getOutputStream());
                while ( contentLength-- > 0 ) {
                   output.write(input.read());
                 output.flush();
              }catch(IOException e) {
                     System.err.println("Exception Occured:"+e.getMessage());
                 System.err.println("Exception Localized Message:"+e.getLocalizedMessage());
              } finally {
                   if (output != null) {
                       try {
                          output.close();
                      } catch (IOException ie) {
                          System.err.println("Exception Occured:"+e.getMessage());
                             System.err.println("Exception Localized Message:"+e.getLocalizedMessage());                      
           }else{
             response.sendRedirect("/errorPage.html");
      public void doPost(HttpServletRequest request,HttpServletResponse response) throws Exception{       
            processAction(request,response); 
      public void doGet(HttpServletRequest request,HttpServletResponse response) throws Exception{
            processAction(request,response); 
    NOTE: Make sure You include activations.jar in your CLASSPATH b4 trying the code.
    therefore,if you have something like above set as your application enviroment in the above disccussed
    can be done by just giving a simple hyper link like
    <a href="downloadFile?fid=fileName.qxd" target="_blank">Download File</a>REGARDS,
    RaHuL

  • HOW TO CONNECT FROM CLIENT MACHINE TO REMOTE MACHINE(SERVER DATABASE MACHINE)

    Hi friends.
    I need your valuable help,
    I am using oracle 11g database.
    I have two system.One is client machine and installed oracle 11G client software.
    and from this machine user can connect remote server database(This is old remote system, this is just for Information).
    And i have created one new database called RMANP in new remote server machine (this is the machine, in which i need to connect from client machine)
    ex
    CLIENT MACHINE DETAIL IS:
    system66
    ip address is 192.162.21.66
    REMOTE SEVER MACHINE DETAILS IS:
    system56
    ip address is 192.162.21.56.
    and i add entry on client machine tnsname.ora file like following,
    RMANP=
    (DESCRIPTION=
       (ADDRESS=
         (PROTOCOL=TCP)
         (HOST=192.168.21.56)
         (PORT=1521)
       (CONNECT_DATA=
         (SERVICE_NAME=rmanp)
    But when i try to connect to remote server from client machine in sqlplus, i am getting an error, Like following,
    SQL> CONN SYS/SYSPW AS SYSDBA;
    ERROR:
    ORA-12560: TNS:protocol adapter error

    2684285 wrote:
    Hi friends.
    I need your valuable help,
    I am using oracle 11g database.
    I have two system.One is client machine and installed oracle 11G client software.
    and from this machine user can connect remote server database(This is old remote system, this is just for Information).
    And i have created one new database called RMANP in new remote server machine (this is the machine, in which i need to connect from client machine)
    ex
    CLIENT MACHINE DETAIL IS:
    system66
    ip address is 192.162.21.66
    REMOTE SEVER MACHINE DETAILS IS:
    system56
    ip address is 192.162.21.56.
    and i add entry on client machine tnsname.ora file like following,
    RMANP=
    (DESCRIPTION=
       (ADDRESS=
         (PROTOCOL=TCP)
         (HOST=192.168.21.56)
         (PORT=1521)
       (CONNECT_DATA=
         (SERVICE_NAME=rmanp)
    But when i try to connect to remote server from client machine in sqlplus, i am getting an error, Like following,
    SQL> CONN SYS/SYSPW AS SYSDBA;
    ERROR:
    ORA-12560: TNS:protocol adapter error
    There is nothing in your connect string to tell sqlplus which database you want to connect to.  Therefore it assumes (by default) that you want to connect to a *local* database whose name is identified by the value of the environment variable ORACLE_SID.  And there is no such database, so he gets the reported error trying to establish a connection to a non-existent local service.
    You need to specify your target database, thusly:
    SQL>  conn sys/syspw@rmanp as sysdba
    BTW, connecting to a remote database as sysdba is considered by most DBAs to be a big secruity breach.  If you really need sysdba privileges (rare) you should be logged on to the database server machine with proper OS credentials, and work from there.
    Also, TYPING IN ALL CAPS IS PERCEIVED AS SHOUTING.

  • Running Pro*C from client machine

    Hi
    I trying to run a Pro*c program which tries to connect to DB which is running on different server.
    While running this I am getting "ORA-12560: TNS:protocol adapter error".
    One suggestion I found that Pro*C application should run on DB server.
    is there any workaround so that we can run pro*C from client machine?
    Or running on server is only possibility?
    Thanks
    Shailesh

    Sorry, I may have misunderstood your problem. I believe that this issue has to do with your tnsnames.ora file. You need to configure your DB to be able to talk to the Pro*C program. In order to do this, you need to set up an LISTENER for EXTERNAL_PROC (for external processes). This is automatically created when you install the DB. You can also create a listener using Network configuration manager. You just need to specify the proctocol, IPC or TCP/IP and the KEY = extproc (can be anything)
    listener.ora (techobs.com is just the domain name)
    LISTENER =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
    TNSNAMES.ora where you you must specify the SID for the external proc
    EXTPROC_CONNECTION_DATA.TECHOBS.COM =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = IPC)(Key = EXTPROC0))
    (CONNECT_DATA = (SID = extp))
    Note: I learned this when doing the installation of OC. If I am wrong, I would hope that somebody would show me where because this is Oracle DBA.

  • HT201250 Can I restore photo files from Time Machine without the use of an external drive?  I'm trying to restore lost photo files and I see them listed in Time Machine (without use of an external drive), but when I try to restore I get a error code 36.

    Can I restore photo files from Time Machine without the use of an external drive?  While I was transferring photos back and forth from a thumb drive something went haywire and my IPhoto was wiped clean!  When I click on Time Machine I see all the dated pages (without an external storage drive connected), go back to a date where all my photo files are there, click "restore", and I get the message:  "The Finder can't complete the operation because some data in file cant be read or written (error code - 36)"

    Thanks so much Terence.  I tried some of the fixes from that page, but then discovered the suggestion to compress the Time Machine Back up of the original library and transfer it as a zip back to my computer as detailed here:
    http://pondini.org/TM/E9.html
    That worked like a charm.  I really appreciate it. 

Maybe you are looking for

  • Steps in Key mapping

    Hi all, i have gone through many forum's regarding key mapping. i can see that the following are used.. --> remote systems --> key mapping option in table-field properties --> key mapping option in table properties. -->key generation(none, range, qua

  • Count Of a Column

    Hello All, I have oracle 10 g r2 on windows. i have one table called T. I as selecting two columns that is t_col1 and t_col2. query is : select t_col1,count(t_col2) froom T group by t_col1; OutPut of the table is : t_col1 t_col2 james 4 lee 6 hopes 1

  • Long compiled and vaild package body executes but shows errors

    hello all, First of all sorry that i am posting such a big post with all the code here... I am new to debugging packegs,proc,fun..etc or as a matter of fact writing pl/sql...but here is the thing...the below package when execute it runs fine stating

  • WRT300n not connecting.

    There seem to be a lot of despondent WRT300n owners out there, and I wish I'd discovered this forum/thread before buying one at the weekend because I've just joined them. Hooked it up to my old and reliable WAG54G ADSL Gateway which I'd bridged to us

  • Help! : Install and configuration of OID and LDAP

    Hi, I'm trying to install OID and run a LDAP server. I installed OID in my 9iR2 database, it seems ok. When I try to connect in ODM, it says 'LDAP server not running'... I don't find in Control panel/services any service naming like 'LDAP' (I just fi