Webutil_host.nonblocking PROBLEM

Good afternoon,
The webutil_host.nonblocking command works fine to open most documents BUT when trying to open a document that has spaces in the filename (example: hello there.doc) it doesn't work?? Does anyone have a suggestion other than renaming the document?
webutil_host.nonblocking('cmd /c '||p_dir_path||p_file_name);
Thanks,
Terry Sicard

Hi
WebUtil has trouble with white space , but If you use the "?? character in palce of white space it will work:
fileName := replace(fileName,' ' ,'?');

Similar Messages

  • Webutil_host.nonblocking('/bin/smbclient....') at linux mint client

    hi dear all
    after searching a lot.. now posting a problem
    my problem = Linux client not running client_host command , no error in console , no other sound
    i created character base report printing form. that first generate filename.txt out put from report then print to any network printer which selected by user.
    server = windows 2003 with oracle 10g forms and reports server
    client1 = windows XP
    webutil client info working fine
    form run following command
    client_host('cmd /c copy jobid0866.txt \\computer_name\printer_share');
    working fine
    client2 = Linux Mint
    webutil client info working fine
    form run following command
    client_host('/bin/smbclient //computer_name/printer_share password -U username -c 'print /home/user_name/Downloads/jobid0866.txt' ');
    actual command in form for further elaborate
    WEBUTIL_HOST.NONBLOCKING('/bin/ smbclient '||:PRINTER_NAME||' printer -U printer -c '||chr(39)||'print home/'||:global.client_user||'/Downloads/'||:parameter.p_filename||chr(39));
    not working with no warning, no error
    Edited by: mhpinger on Jan 27, 2012 3:40 AM

    server windows 2003 with oracle application 10g
    client linux mint
    working
    cmd_string := '/bin/cp /home/'||:global.client_user||'/Downloads/'||:parameter.p_filename||' '||'/home/'||:global.client_user||'/Downloads/result.txt';
    webutil_host.blocking(cmd_string);
    not working
    cmd_string := '/bin/smbclient '||:PRINTER_NAME||' printer -U printer -c '||chr(39)||'print home/'||:global.client_user||'/Downloads/'||:parameter.p_filename||chr(39);
    webutil_host.blocking(cmd_string);
    Edited by: mhpinger on Jan 31, 2012 1:32 AM
    Edited by: mhpinger on Jan 31, 2012 2:59 AM

  • How to run a batch file (.bat) from forms? WEBUTIL_HOST.NonBlocking?

    I need to execute a batch file on the clients pc. Right now, I'm using:
    WEBUTIL_HOST.NonBlocking('cmd.exe /c "' || :Test.Batch_File_Name || '"');
    where the :Test.Batch_File_Name is something like C:\run.bat.
    This works to some extent. When it runs, I see a blank cmd.exe window and when I check my processes, I can see that run.bat is running. However, I need to be able to see run.bat as it executes because it outputs messages to the screen. Is there a way to call client_host or webutil_host that will display the batch file screen?
    Thanks

    Hello,
    With the Webutil Get_Standard_Output() , you can get the output strings and display them into your own Forms canvas ;o)
    Francois

  • WEBUTIL_HOST.NONBLOCKING with quotes not works more !

    Hi,
    Forms 10.1.2.3
    Java 1.6_27, 1.6_34, 1.7_21
    windows 7
    Office 2010
    the interesting thing is we have changed nothing in the code for last 3 years
    We have not performed a Windows or Java update.
    Overnight, the call does just work like in example 2. But then I can not use more space in the Filename !!
    1)
    the last 3 years was used this call:
    WEBUTIL_HOST.NONBLOCKING('cmd /c "C:\Program Files (x86)\Microsoft Office\Office14\winword.exe" "C:\tmp\Docs 2013.doc"');
    2)
    This call works now
    Space was removed. Docs2013.doc instead Docs 2013.doc and without quotation marks
    WEBUTIL_HOST.NONBLOCKING('cmd /c "C:\Program Files (x86)\Microsoft Office\Office14\winword.exe" C:\tmp\Docs2013.doc');
    3)
    This not works
    space was removed. Docs2013.doc instead Docs 2013.doc and again in quotes
    WEBUTIL_HOST.NONBLOCKING('cmd /c "C:\Program Files (x86)\Microsoft Office\Office14\winword.exe" "C:\tmp\Docs2013.doc"');
    I do not understand why this behavior occurs suddenly
    someone has an idea ?
    thx
    Alfred

    There have been some significant changes in Java 7U21 which will impact the way CLIENT_HOST and WEBUTIL_HOST will now work. We are aware of these changes and are trying to determine how much of the old behavior we can restore. If your issue only reproduces in Java 7U21, feel free to contact Support and mention bug 16686443
    That said, I would recommend using this code in place of yours:
    Declare
         my_cmd varchar2(255);
    Begin
         my_cmd := 'rundll32 shell32,ShellExec_RunDLL '|| :t1;
         CLIENT_HOST(my_cmd);
    End;In the above code, :t1 might be a text field where the user would enter the path and name of the file to open. For example: C:\tmp\Docs 2013.doc
    Alternatively, if you feel the need to hard code the value, it might look like this:
    Declare
         my_cmd varchar2(255);
    Begin
         my_cmd := 'rundll32 shell32,ShellExec_RunDLL C:\tmp\My Directory\test.xls';
         CLIENT_HOST(my_cmd);
    End;This code has been tested on Forms 11.1.2.1 using Java 7U21. The same code should work on Forms 10.1.2.3, but keep in mind that Java 7U21 is not supported for use with Forms 10.

  • Webutil_host.nonblocking get focus back to applet

    When you launch a program using webutil_host.nonblocking(), is there a way to get the focus back to the Forms applet automatically without closing that program?
    In older Client/Server versions I believe this was possible using the constant SW_SHOWNOACTIVATE but in webutil I can not find an alternative.
    Thanks,
    Jeroen

    Controlling and external app's window focus and z-order from a java applet is not likely going to be a simple task. As I mentioned, the easiest approach would likely be to start the external app minimized or attempt to control the state of the Forms window. In other words, after calling the external app force the Forms window to the foreground. This is likely going to be the simplest place to start. You still may need to manage cursor focus, but this approach might at least get the Forms application back to the foreground where you can then figure out how to handle the cursor.
    So in other words,
    1. Add a java bean to your form which will control the state of the Forms applet window/frame. See the following:
    http://forms.pjc.bean.over-blog.com/article-2203967.html
    Understand that this will only work if Forms separateFrame=true.
    2. From the form, call your external app. Immediately after making the call to WebUtil to start the external app, execute a SYNCHRONIZE then call the above bean to bring the Forms separateFrame to the foreground using an "always on top" feature.
    3. Once the form is on the top of the z-order (in the foreground), disable the "always on top" option.
    In theory, the above should accomplish most of what you want. However, just because you brought the form to the foreground does not necessarily mean that the cursor focus will be in any particular item of the form. In fact, it is most likely that focus will be on the title bar of the form. The user would have to click on the desired field or button to perform their next task. Controlling the cursor focus at this point may be possible by executing a GO_xxxx to an item or block. If not, another bean or modifications to this one may be necessary in order to place the cursor back on the displayed canvas.
    if any of this stuff is something you are not familiar with, I suggest a google or similar search as what you are attempting to do is leaning into what many would call advanced tweaking ;)

  • Webutil_host.host problems (bugs???)

    Hi,
    I'm using the webutil_host.host(commandline) command to execute batchfiles on a client pc. These batch files are also echoing messages to the screen. In the client server version, when I use the host command, the messages appear in my ms-dos box. With webutil they don't.
    The same goes for the pause command in a batch file. When there is a pause command in the batch file to give the user the possibility to read the messages on the screen and wait for user interaction, the ms-dos box doesn't respond on my key-stroke. I have to close the ms-dos window by clicking on the upperrightcorner cross.
    imo this is unwanted.... Is there a workaround? Or do I have to live with the fact that webutil_host.host != host

    i'm using the webutil host command to execute batch files on the client pc. One function of these batch files is to start SQL*loader to read data-files on the client-pc. This is the core of the application, since the data in the datafiles is the base of the rest of the process.
    Because this is such an important part it is decided to give outputs to the ms-dos console and put pauses in the batchfile, so the process of reading the data-files can be evaluated.
    Since this is a migration traject (moving from c/s to web) my customer doesn't want any functional changes (like outputs to logfiles instead of ms-dos window).

  • Dealing with problem where calling to webutil_host on form startup

    hey ,
    i try to call webutil_host in order to open an external .NET form.
    this done on form startup (on when-new-form-instance calling).
    the call:
    WEBUTIL_HOST.NONBLOCKING(v_url_path);
    (on forms 10).
    as a result , i get:
    oracle.forms.webutil.host.host been not found
    WEBUTIL_HOST.execute will not work
    when i made the same call , this time with a button , everithing is worked fine.
    i had solve this problem by using a timer in when-new-form-instance trigger.
    my question is:
    why is it happend and if there is a way to solve it , without the use of timer.
    thanks , yair.

    Hi
    Everybody who has this problem has used a timer.
    As Aleksandar said, it's to do with the initialisation of the webutil bean not having occurred until the form startup process has completed.
    rgds
    Tony

  • WEBUTIL - file already open problem

    Hy everybody,
    I request your help for a problem with de Webutil library.
    I want to open a PDF document with the command :
    Ret := WEBUTIL_HOST.Nonblocking( Cmd ) ; (Cmd = path + file name)
    This function is called on a "When Button pressed" trigger in my form.
    The errors occurs when :
    1/ I pressed my button, my PDf is well displayed.
    2/ I didn't close my PDF and I click again on my button.
    3/ I get the error "WUT-105 : Unable to open file"
    I just want to know if exists a function which tell me if the document is already open. (WEBUTIL_FILE.FILE_IS_READABLE does not work any more !)
    Or if I could catch the exception in my code. I've tried but I didn't manage to catch it.
    If somebody could help me, thanks in advance. And sorry for my english, I'm just a french guy ... ;-)
    Bye.

    user10836197 wrote:
    Ret := WEBUTIL_HOST.Nonblocking( Cmd ) ; (Cmd = path + file name)You only pass the path of the file? Did you try it with rundll32?
    rundll32.exe url.dll,FileProtocolHandler test.txtOpens test.txt with the program I specified to always open textfiles with.
    cheers

  • Problem opening html file in separate browser window

    I have an forms app where a user can download a file from the database and then open that file on the client. After the file is downloaded, I use webutil_host.nonblocking ('cmd /s start' ||filename) and it works fine for .doc, .xls etc. as these open a separate program. Problem occurs when user downloads an html file, the command opens the file in the same browser window as forms is running, thus ending the forms session.
    I've tried web.show_document('file:\\'||filename) but that fails as I assume it is looking for the file on the application server instead of on the client.
    Any ideas on how to workaround this issue?

    Well I searched around on google looking for a java servlet or jsp example and couldn't find one. I know they are out there becasue thats where I got mine about a year ago. I dont work at the same place anymore and couldnt take my code with me. Anyway, you would use this servlet for any document (xls, doc, html, txt, pdf) that is in the blob column in the db. The servlet would send a mime type first in the response and then the blob. The browser would display the blob in the associated helper application on the client (Excel, Word, IE, notpad, Adobe Acrobat Reader, etc..). The user can then save the document to their hard drive if they wish. This is faster becasue the clients hard drive isnt involved in the transfer from db to client. The user can then edit the document and reupload the document. Thats how we did it.
    Maybe somebody else can post a link to a generic blob download servlet? Thanks..

  • 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_host closing command prompt

    I am using this command in my form:
    webutil_host.nonblocking('cmd /c "' || v_file_name || '" && exit');
    I want to be able to open the WORD/PDF/EXCEL, etc.
    file and close the Command Prompt as well.
    Currently, the document will display properly but the
    command prompt window will stay there until the user
    exits the document. I want the command prompt window
    to disappear (or hide) as soon as the document opens.
    Is this possible?

    You could try
    webutil_host.nonblocking('cmd /c start "' || v_file_name || '" "' || v_file_name || '"' );
    It will not work if client uses Windows 95/98/ME.

  • Webutil_host very slow first time.

    I use a very simple comand
    WEBUTIL_HOST.NONBLOCKING(COMANDO)
    where COMANDO is
    COMANDO := 'CMD /C "'||FILE_NAME||'"' ;
    and FILE_NAME contains the name of a .xls Excell file.
    It works fine but first time I execute it it takes more than 5 minutes to open the Excell file.
    From the second on it appears after 20 secs.
    I tried to open Excel by hands before I execute the command but nothing changed.
    How can I solve that issue ?
    Tks
    Tullio

    Can you explain what you mean by this statement:
    I tried to open Excel by hands before I execute the command but nothing changedWhat do you mean by hand? Do you mean you try opening the file using excel application on client machine? If so, how fast did it load first time on client machine?

  • Webutil host nonblocking blank file

    Hi, I've used webutil_host.nonblocking( 'rundll32 url.dll,FileProtocolHandler ' || v_location||v_filename ); to call an .csv file.
    first execute everything is fine...we can see data writed on that file.... but when we execute again, we just have a blank page .csv ...
    does anyone know how we can fix it?
    Thanks in advance,
    Alwin

    Hi
    WebUtil has trouble with white space , but If you use the "?? character in palce of white space it will work:
    fileName := replace(fileName,' ' ,'?');

  • Try to call wfs.exe (MS fax and scan) with webutil_host !!

    hi,
    I would call from Forms the MS scan and fax application “wfs.exe”.
    This is found under windows\system32.
    call:
    WEBUTIL_HOST.NONBLOCKING ('cmd /c C:\windows\system32\wfs.exe');
    Unfortunately, nothing happens. No error message and no cmd-process remains open in the taskmanager.
    with other applications it works. For example:
    WEBUTIL_HOST.BLOCKING('cmd /c C:\Windows\System32\notepad.exe');
    WEBUTIL_HOST.BLOCKING('cmd /c C:\Windows\System32\calc.exe');
    I use Forms 10.1.2.3 on Windows 7.
    Does anyone have any idea or can test that if it works?
    thx Alfred

    you can use
    WEBUTIL.client_HOST ('cmd /c C:\windows\system32\wfs.exe',hide_screen);
    instead of
    WEBUTIL_HOST.NONBLOCKING ('cmd /c C:\windows\system32\wfs.exe');
    which will run the wfs.exe file located in the windows\system32 directory. if client machine is on the windows O/S
    you can view the process list by tasklist command on the command prompt.
    you can use cmd /k option for remaining in that session for the errorlevel checking.

  • Webutil.host and space in filename ....

    Hello,
    Do someone have found a solution at the problem of space in filename calling whith webutil.host ?
    under winxp if I do :
    CMD /C start "C:\Program Files\Microsoft Office\OFFICE11\WINWORD.EXE" "C:\travail\COMMENTAIRES DU DOSSIER 5200257".doc
    it works well
    But do the same in Webutil.host command ... and it fail :<
    I see that this was an old problem in post but dunot have found any response ..
    tk anyway.

    So, i have try all these options and found that webutil seems to cut spaces.
    As I have this
    LC$Cmd := 'cmd /c start "C:\Program files\Microsoft Office\OFFICE11\WINWORD.EXE" "c:\travail\COMMENTAIRES DU DOSSIER 5200257.doc"'
    WEBUTIL_HOST.Nonblocking( LC$Cmd ) ;     
    webutil launch :
    "C:\Program files\Microsoft Office\OFFICE11\WINWORD.EXE" "c:\travail\COMMENTAIRES DU DOSSIER 5200257.doc"'
    and so it dunot found the document
    bcs it make all space -> 1 space
    strange !!
    perlaps some have got same problem ?

Maybe you are looking for