Client_host

can i call excel sheet and save the details from the FORMS using client_host . i can open that excel sheet what i entered thro forms
kindly tell me the solution and example

If you are attempting to take data from a Forms application and send it to an client side Excel document, you will need to use WebUtil's CLIENT_OLE2 and not CLIENT_HOST. There are several Metalink notes which cover this topic as well as an OTN example of how to do this with MS Word.
http://www.oracle.com/technology/products/forms/htdocs/webutil/howto_ole.html
Regardless of the third party application, the majority of the information you will need to use OLE will come from that vendor and not Oracle. In your case, you will need to understand OLE and refer to the Microsoft documentation.
This may be a good starting place:
http://msdn.microsoft.com/en-us/library/aa203714(office.11).aspx
This one is a little older, but does offer additional clarity:
http://msdn.microsoft.com/en-us/library/aa155776(office.10).aspx

Similar Messages

  • How to run multiple DOS commands from a single Webutil Client_Host session?

    Hello all,
    I have a requirement where I need to create an interface with SVN from Forms for basic checkin-checkout of files.
    So, I've been trying to use webutil client_host to open a command line session and issue svn commands.
    For svn, sometimes I need to give multiple commands like change to a particular directory and then run an svn command.
    But client_host takes in only one command at a time and I'm unable to issue a series of DOS commands to perform
    a particular task.
    Is there a way to do this?
    Pls suggest.
    Regards,
    Sam

    First your original question... You can put more than one DOS command on a single line, simply separate each command with an ampersand (&). For example:
    mkdir c:\abc & cd abc & dir*
    Regarding your concerns about performance, well that would depend on exactly what you mean. Using CLIENT_HOST (or HOST on the server) simply opens a shell (DOS in this case) then passes your command to it. The performance of performing this action really isn't measurable. Basically you are just pressing a button and you should get a near immediate action. As for the performance of executing each command, that has nothing to do with Forms. Once the command is passed to the shell, the rest is a function of the shell and whatever command you passed.
    Having said that, if you were to write something sloppy like a loop (in pl/sql) which called CLIENT_HOST lots of times repeatedly, then yes there would be a performance problem because the pushing of the button will cause an exchange to and from the server and each cycle in the loop will do the same.
    So the answer to how performance is impacted will depend on what exactly you need to accomplish. If it is a single call to CLIENT_HOST, this should be fine.

  • How to use Client_Host without the exe file path

    Hi,
    i'm using oracle forms 10g,
    in my application the users can upload any type of files (doc,xls,pdf,avi ,.. etc) and any user can download and open any of these files.
    i implement this using client_host and including the path of winword.exe or AcroRd32.exe ,...
    in many cases i don't know where these exe files are installed in the client side or whether it is installed or not.
    i tried this command : client_host('calc.exe') it works and show me the calc without including the path of this exe file.
    what i want to do is to just call the target file(doc,pdf,avi,..) in the client_host without having to precede this with the exe and path like the calc.exe example.
    if you go to start->run and write for example c:\ahmed.mpeg , windows automatically call the real player or any other video software installed and open the movie.
    can we implement this in oracle forms? and how?

    Hi, you attach a procedure to download a file in the local runs from Windows and to close it updates in the database and then delete the local directory
    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;
              -- Ruta y nombre del fichero temporal --
              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 ;
              -- Descargamos el fichero --
              If Not webutil_file_transfer.DB_To_Client
              LC$Fic,
              'TABLE_NAME',
              'ITEM_NAME',
              'WHERE'
              ) Then
              Raise Form_trigger_Failure ;
              End if ;
              -- Abrimos el fichero temporal en local --
              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 ;
              -- Actualizamos el fichero en la BBDD --
         If Not webutil_file_transfer.Client_To_DB
              LC$Fic,
              'TABLE_NAME',
              'ITEM_NAME',
              'WHERE'
              ) Then     
              NULL;     
              Else
                   Commit ;
              End if ;     
         -- Eliminamos el fichero temporal local --
              LB$Ok := WEBUTIL_FILE.DELETE_FILE( LC$Fic ) ;
    Exception
              When Form_Trigger_Failure Then
              Raise ;
    End ;

  • Webutil_Host and Client_Host

    Hi,
    I am wondering what is the difference between Webutil_host and Client_host?
    I am trying to call sqlplus.exe located in the server and run a text file in the client side. I am wondering if I use webutil_host or client_host?
    Thanks in advance!

    Hi,
    client_host is a wrapper that is rovided for API parity. Client_Host calls Webutil_Host. If you need non blocking calls, or an ID retruned instead of an error code then use webutil_host.
    Frank

  • Webutil_host or client_host delete all files...

    I am trying to delete files within a directory on a client's machine through my forms 9i web application and it's not working???
    I tried
    client_host('cmd c/ DEL c:\gdocdocs\');
    client_host('cmd c/ DEL /F c:\gdocdocs');
    webutil_host.nonblocking('cmd c/ c:\gdocdocs\');
    webutil_host.nonblocking('cmd c/ DEL c:\gdocdocs\');
    Thanks,
    Terry Sicard

    IMHO For Windows 2000, the command should be
    cmd /c DEL /Q c:\gdocdocs\*.*
    /Q - Quiet mode, do not ask if ok to delete on global wildcard
    You could also try:
    echo Y | del c:\gdocdocs\*.*

  • Webutil.client_host relative path

    Hi, I'm upgrading an old 6i client application. There are some calls to host commands that contain relative paths.
    ..\import\start.batFrom 10G using client_host these files are not found. Probably the paths are not relative to the location of the fmx file?
    Edited by: Rene W. on Jan 29, 2009 1:07 AM
    Solved, should have left "host' instead of client_host in this particular instance.

    Hi, yes I realized that after posting my question. We start a couple of conversion tools before loading data into the database. Advantage of the webforms is that files can be uploaded to the AS and conversion can run from there. No need to have the conversion tools on all the clients anymore.

  • Webutil client_host question

    Hello,
    I have
    CLIENT_HOST('cmd /c START "" "fisier.bat" ');but if that file is located oln C:\forms\4.1.1\imp_ret, how can i specify this path in that command?
    Thanks

    try something like this:
    cmd /c cd /d <your_working_directory>&&<your_command>the +&&+ simply tells the cmd that it needs to execute another command; so the first it does is to change into your working directory ( /d is used if it is on another drive) and after changing the directory it executes your second command.
    cheers

  • Webutil - Client_host not working

    Hi all,
    I have installed/configured Webutil along with Jacob.jar and signed them. Also compiled the webutil.pll. Attached this to a form and when I used the client_host command to call any exe file, I get a please acknowledge message and the thereafter no processing.
    I am using Oracle Forms 9.0.4.
    sample command
    client_host('CMD /C cp c:\abc.txt c:\a.txt');
    Is this could be configuration issue of webutil?
    An exe on Application server should be opened in the client system.
    Is there any other way to access this?
    Please suggest.
    Regards,
    Gopal.

    Hello,
    I tested with Webutil 1.0.5 and Forms 9.0.4 on Windows 2000:
    It worked for me with:
    client_host('CMD /C cp c:\abc.txt c:\a.txt');
    What OS do you have?
    You should check to see if it does work in CMD promt in order to see if this is an OS issue or an WebUtil issue.
    Best Regards,
    Eugen

  • Webutil client_host

    I'm using webutil(client_host).
    e.g.
    CLIENT_HOST( 'CMD.EXE /C START '||NAME_IN( 'block_name.item_name' ) );
    The value acquired using CLIENT_GET_FILE_NAME goes into 'block_name.item_name'.
    In 'C:\Documents and Settings' e.g. becomes an error when a folder with a blank is specified.
    If there is the solution method, please let me know.

    Hi Duncan.
    If so, you just need to alter your command
    a little to enclose the path in quotes. e.g)Unfortunately It may not work. START will think that the parameter is a title of a window, not a command.
    C:>START /?
    Starts a separate window to run a specified program or command.
    START ["title"] [Dpath]  [MIN] [MAX] [SEPARATE | /SHARED]
    [LOW | /NORMAL | /HIGH | /REALTIME | /ABOVENORMAL | /BELOWNORMAL]
    [WAIT]  [command/program]
    [parameters]
    "title" Title to display in window title bar.
    path Starting directory
    etc...

  • Webutil_file.create_directory & client_host

    HI,
    *1.*
    I want to create directories & files in my C:\tmp, but I want try to run from my form.
    For example, I have a form. In my form, have a button 'Create File'. When I click that button, it will create a folder/file in my C:\tmp, not in AS. My OS pc is Win XP, AS is Unix, Oracle Forms [32 Bit] Version 9.0.2.12.2 (Production).
    Is it possible to do that? Or it totally impossible? I've tried using client_host, host, & webutil_file.create_directory, but all failed.
    When I use client_host & webutil_file.create_directory, error during compile.
    identifier 'client_host' must be declared.
    identifier webutil_file.create_directory' must be declared.
    Or am I forgot something about the settings?
    I know that:
    HOST is executed on the App Server
    CLIENT_HOST Is executed on the client
    but I really don't know the concept how & where to apply. I'm really new to all these things.
    *2.*
    Lastly, my question: Is it allow me to create folder in AS? That means I need access privilege/rights to create,edit,delete files/folders or not ? Because when I try to create folder in AS using host command, it failed.
    Is this problem related to rights on AS? The error appeared was +302000: non-ORACLE exception.+
    Can anyone help or clarify to me?
    Thanks,
    Luthfi
    Edited by: Luthfi on Sep 28, 2011 8:38 PM
    Edited by: Luthfi on Sep 28, 2011 8:44 PM
    Edited by: Luthfi on Sep 29, 2011 2:27 AM
    Edited by: Luthfi on Sep 29, 2011 2:32 AM
    Edited by: Luthfi on Sep 29, 2011 2:34 AM

    for creating the files at the client side you have to use the
    CLIENT_HOST('c:\windows\system32\cmd.exe /k "mkdir c:\temp\aa"');
    the above command will create a directory in the c:\temp\aa
    you have to configure the AS for pirvilleges for the creating of directories...

  • With webutil-client_host, send txt file to client printer

    hi,
    I wanna to learn how to send a txt file to client default printer(local or network),
    I created txt file at client disk, and try to send printer directly,
    just try some statement looks like below;
    a.client_host('cmd /c start print C:\TEMP399899.txt /d:lpt1');
    b.client_host('cmd /c start copy C:\TEMP399899.txt lpt1');
    I do not know the command prompt syntax, please help me, reference me,
    thanks

    Hi,
    on a command line type
    print /?
    for the help of how to print documents. On XP this help is
    PRINT [D:device] [[drive:][path]filename[...]]
    /D:device Specifies a print device.
    Frank

  • Webutil client_host problem executing pkzip pkunzip commands

    Hi,
    I configured webutil with Developer 10g (9.0.4).
    I used webutil_106.zip and jacob_18.zip.
    The execution of this statements (example) are successfully:
    CLIENT_HOST('notepad');
    CLIENT_HOST('tnsping db');
    However, when I issue this ones (in order to zip/unzip files):
    CLIENT_HOST('pkunzip d:\arch.zip d:\tmp');
    or
    CLIENT_HOST('pkzip....');
    I got this error:
    100501 non-OracleException
    What do I have to configure in order to execute this commands????
    Regards, Santiago

    I find the solution in metalink.
    Execute the commands like this:
    client_host('cmd /c start c:\pkzip .....');

  • Problem with client_host statement

    Hi all. I'm on devsuite 10g.
    I have a problem while executing client_host statement.
    With another application I have exported a job as script (.bat file).
    Now I want to execute this file from my form application.
    With webutil I'm able to locate file on the client machine.
    To execute it I issue this command:
    Client_host('cmd /c start ' ||my_file_directory\my_file.bat|| '' );
    I encountered an error.
    So I have created one .bat file in which there is this command: calc.exe;
    once I execute this file using the same client_host statement as before, I notice that it has executed from my desktop, and in the dos box appears this path:
    C:\Documents and Settings\dellipri\Desktop
    I have tried to execute my job script file both double clicking it and open manually a dos box and writing full path and name of file and everything is OK.
    So what I would know if there is an option that I must put in my client_host statement in order to execute my_file_name from the absolute path and not from my desktop.
    Thanks all for collaboration,
    Fabrizio

    When you double click on your batch file in explorer the cmd get's invoked with the working directory where you placed your batch file, so the batch file get's executed with this working directory.
    when calling cmd from somewhere else (like client_host) the shell get's invoked with the user home (c:\documents and settings\and_so_on) as working dir.
    So basing your calc sample you placed your testbatch file on the desktop?
    You don't need to put your batch file into any other directory, just force the shell to change the directory where your batch file lies within (wherever that is) and call the batch file.
    just a little sample to get this clear:
    create a file called test.txt in a directory e.g. c:\temp and put some text into it. In the same directory create a batch file called test.bat where you open your file with notepad:
    notepad test.txtdouble click it in explorer, the directory of the shell should be c:\temp, and notepad opens the file.
    then the next run it via start => run and type in
    cmd /c start c:\temp\test.bat
    and notepad prompts you if you want to create a new test.txt (as in c:\documents.... there is no test.txt)
    and the last
    open start => run and type in
    cmd /c cd c:\temp&&test.bat
    and notepad opens the file again. The shell get's invoked with workdir c:\documents..., then changes the directory to c:\temp and then in this directory it calls the batch file.
    It is the same as if you'd put the "cd c:\whatever" into your batch file, but as you said that's not possible, so force the cmd to do that before invoking your batch file (the && command simply tells the cmd to do more than one command; and the first command is to change the directory to c:\temp, and the second is to call the batch file).
    Actually I tried it with the notepad sample I provided above from forms, and it worked for me...
    regards

  • CLIENT_HOST error in forms

    Hi ,
    I am calling CLIENT_HOST command in forms in linux machine and passing an exe file as the parameter, but this client_host command is showing the below error on execution :
    CLIENT_HOST command is part of WEBUTIL.pll file and this file is attached to the form as well.
    Command executed on click of button:
    ========================
    client_host('cscript.exe c:\temp\text.txt');
    ERROR shown:
    =========
    Error occured: ORA-06508: PL/SQL: could not find program unit being called ORA-01403:no data found
    Can someone help in this regard ? it is bit urgent.
    Regds,
    noneda

    Most likely, the Window Script Host (cscript.exe) isn't finding a script engine for the .txt file extension. What are you trying to accomplish with this Client_Host call and what is text.txt suppose to do?
    Hope this helps,
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

  • WEBUTILS CLIENT_HOST

    I am using the webutil client_host functionality.
    The following command calls the program correctly but the tabs have been ignored or replaced by spaces.
    CLIENT_HOST('creditcarddonations.exe '||:global.connum||CHR(9)||v_name||CHR(9)||RTRIM(v_address, CHR(9)));
    Any Ideas?
    Works fine using host in Forms 6i
    Nigel

    On further investigation the tabs exist in the command string up to the SET_CUSTOM_PROPERTY in the webutil_core.set_item_property procedure

  • PROBLEMS USING WEBUTIL_FILE_TRANSFER AND CLIENT_HOST COMMAND TO VIEW BLOB

    I am using webutil_file_transfer.DB_To_Client_with_progress to retrieve a blob
    from the database (that was saved in a word format) into a .doc file on the
    client.
    1st problem: The document that is being saved is not readable. It has all
    kind of special characters in it.
    Then using the client_host command, I open the document into ms word.
    2nd problem: The document opens fine (again not readable in garbage
    characters) but when I close the document, notepad pops up blank with nothing
    in it.
    Below is a sample of the code.:
    PROCEDURE DOWNLOAD_DB IS
    l_success boolean;
    username varchar2(30);
    document_name varchar2(20);
    wordexe varchar2(20);
    BEGIN
         username := webutil_clientinfo.get_user_name;
         document_name := 'wo'||:wod.fk_work_order_number||'.doc';
         :locals.file_name := 'Documents and Settings\'||username||'\my documents\'||document_name;
    l_success := webutil_file_transfer.DB_To_Client_with_progress
    (clientFile => 'C:\'||:locals.file_name
    ,tableName => 'DEFECTS'
    ,columnName => 'DESCRIPTION'
    ,whereClause => 'FK_WORK_ORDER_DATE_ID = '||:DEF.FK_WO_DATE_ID
    ,progressTitle => 'Defect document being opened'
    ,progressSubTitle=> 'Please wait'
    if l_success
    then
    CLIENT_HOST('cmd /c start /wait winword.exe C:\'||'"'||:locals.file_name||'"');
    else
    message('File download from Database failed');
    end if;
    exception
         when others
         then
         message('File download failed: '||sqlerrm);
    END;
    Any ideas?

    Hello,
    I use this kind of code with 9i and 10g and it works fine with word, excel and any of windows files.
    I think that, if the file is not correct, the cause may be the first save of the file in the database.
    Which instruction did you use to save first the doc in the BLOB column ?
    Francois

Maybe you are looking for

  • Software RAID setup by partition or by drive?

    I've outgrown my ext FW drive that has served me well. May I still use it in a RAID 1 with a partition from a larger drive I am going to get? I've spent the last few years backing up a TiBook to an ext FW 120GB Maxtor drive, which has worked well. I

  • Exchange Fluctuation in FA

    Dear Friends, I have q query in FA module. I want to capitalize the exchange gain or loss relating to an asset and add it to cost of the asset. In AP module, when payment is payment the difference between invoice rate & payment rate goes to exchange

  • Business Objects Design Studio

    I am working on a report on Business Objects Design Studio, Please help me out with the below two issues, 1. I want to display user name after Welcome message. The user name should be of the person who is logged into the SAP warehouse currently. 2. T

  • Epson 3880 Printer won't print

    I have an i5 iMac running OS x 10.8.4 that I recently migrated to (about 3 months now) from a PC.  My Epson 3880 printer and 1400 printer will not print from Photoshop CS6 or Lightroom 4.  I have printed text and less intensive graphics to the 1400. 

  • BB Desktop freezes with 9630 in bluetooth mode

    I am running BB Desktop 5.0 and Vista, with a 9630.  I was able to sync with outlook using the BB Desktop and bluetooth to my phone at first, but now it has stopped working.  The BB Desktop application freezes up when initially communicating with the