How to handle the word document which is already opened(Add content to it) using VbScript using "Word.Application" method

Hello,
I want to add some content to the word document which is opened already and active using vbscript.
Here is the sample code to have an idea.Kindly Help.
Set oWord = CreateObject("Word.Application")
oWord.Documents.Open
"c:\test.docx" ----->Here i dont want to open the Document as such as my document which is opened already,i have get the control over that document-I try to achive this by using HP UFT tool for word document automation
oWord.Selection.EndKey
6,0
oWord.Selection.TypeText
" This text has been entered by opening the exisitng document. "
oWord.ActiveDocument.Save
oWord.Quit
Set oWord = Nothing

Hello,
Nice to see the Reply from you. I have done the same thing what you have suggested but unfortunately i am not achieving the result as expected.
Here i explain you clearly,
Business Scenario:
Using an aplication we will create word documents-To do this we need to fill all the document properties and click on OK button-After this,Application automatically launches a Word Document with the File name given by itself as per the Configuration and
it will be available for the Editing-After user add content,he has to check in the document in the application in order to replicate the changes made by user to the document-This is the Business process
Here my Document actually resides in the Users Folder-"C:\Users\narayanasamy_r\Documentum\Checkout\" before checkin event happened,once i add content,save,close the document,i will navigate to the document in the application  and Do check-in
operation.
Interesting point is that,after i do check-in operation my actual document which was resided in "C:\Users\narayanasamy_r\Documentum\Checkout\" will not be available anymore
So My logic Should be,
1.identify that particular Document from the Folder and add content,save and close(Note:i dont want to open the document from "word.application" control here, as the application itself opens up the Document)
Kindly Help On the same.
Thanks,
Narayan

Similar Messages

  • Spotlight opens Microsoft Word documents underneath an already open document

    Spotlight opens Microsoft Word document underneath an already open document

    New Lion Feature. If you quit an app that has open windows and documents, it will restore state when restarted; in other words, reopen all the stuff it that was previously open. That's why the new document gets bumped underneath the old.
    If too avant-garde for your tastes, visit the General pane in System Preferences and uncheck "Restore windows when quitting...".

  • How to get the PDF documents that are currently opened in Adobe Reader?

    When a PDf file is opened in adobe reader, how can we know the details of the file which is currently opened.
    If I want a copy the PDF document to get saved on desktop automatically without asking to user, How can I do this in c#?
    If there are many PDF files opened, then also, I have to get all the details of PDF documents  which are opened.
    Thank You...

    Reader Forum http://forums.adobe.com/community/adobe_reader_forums

  • How to handle the ref cursor which is returning "no rows"

    I have written a function which is returning the REF CURSOR. But in one situation the REF CURSOR returns "no rows selected". To handle this situation an exception is raised "when no data found". But i dont know in this situation how should NULL cursor be returned through this function. Since I want to call this function in another procedure so something should be returned through this function by means of ref cursor. But since i am not able to handle this "no rows selected" situation i am not able move further.
    Thanks in advance........

    I agree.
    You would simply process the returned ref cursor irrespective of any rows actually returned in the cursor or not. You would be able to do at least one FETCH from the cursor (even if it does not actually contain any rows) and then determine the %NOTFOUND status to do the rest of the processing.
    SQL> variable cur refcursor
    SQL> exec open :cur for select * from scott.emp where rownum = 1 ;
    PL/SQL procedure successfully completed.
    SQL> print cur
         EMPNO ENAME      JOB              MGR HIREDATE           SAL       COMM     DEPTNO
          7369 SMITH      CLERK           7902 17-DEC-1980        800                    20
    1 row selected.
    SQL>
    SQL> exec open :cur for select * from scott.emp where 1 = 2 ;
    PL/SQL procedure successfully completed.
    SQL> print cur
    no rows selected
    SQL>
    SQL> SET SERVEROUTPUT ON
    SQL> DECLARE
      2      rec scott.emp%ROWTYPE;
      3      bol BOOLEAN;
      4      cur sys_refcursor;
      5  BEGIN
      6      OPEN cur FOR
      7          SELECT * FROM scott.emp WHERE 1 = 2; /* assume this is your function call returning a ref cursor */
      8      bol := FALSE;
      9      LOOP
    10          FETCH cur
    11              INTO rec;
    12          EXIT WHEN cur%NOTFOUND;
    13          --
    14          -- process the data here
    15          --
    16          bol := TRUE;
    17      END LOOP;
    18      CLOSE cur;
    19      IF (bol)
    20      THEN
    21          dbms_output.put_line('At least one row was found');
    22      ELSE
    23          dbms_output.put_line('No rows were selected');
    24      END IF;
    25  END;
    26  /
    No rows were selected
    PL/SQL procedure successfully completed.
    SQL>

  • How to handle the issue of multiple AR periods opened by mistake?

    Hi
    We have a situation where in the future AR periods (say till 2015) got opened by mistake. But we want to allow transactions to be entered in the current month period.
    Kindly suggest what needs to be done for this.
    Regards
    Prabhoo

    Hi,
    In order to fix this issue you can try run this update script for fixing the issue.
    UPDATE gl_period_statuses
    SET closing_status ='N'
    WHERE application_id = 222
    AND start_date > (your current period start date)
    AND closing_status ='O'
    Please note, before applying this fix kindly get the same verified with Oracle Product Support and test the same in a test instance and proceed for production application
    Regards,
    Kravipra

  • Focus on the editor Tab which is already opened (vspackage)

    I am binding  list of items to the toolwindow from database,when i click the item, corresponding item name editor tab opens but  when i click the same item i want to Focus(Active) the same editor tab.It should not open the new tab.I am using following
    code to open the editor.
    string name = item.name + ".  ";
    string path = @"VSkbEditor Files\VSkbEditor";
    DTE ppHier = (DTE)Microsoft.VisualStudio.Shell.Package.GetGlobalService(typeof(DTE));                    
    ppHier.ItemOperations.NewFile(path, name, EnvDTE.Constants.vsViewKindDesigner);
    Thanks in advance.

    Hi jnanesh,
    You can either set the focus back to the original editor window or firstly hide the opened editor window, for example:
    DTE dte = GetService(typeof(SDTE)) as DTE;
    Window originalWindow = dte.ActiveWindow;
    dte.ItemOperations.NewFile();
    originalWindow.Activate();
    //DTE dte = GetService(typeof(SDTE)) as DTE;
    //dte.ItemOperations.NewFile().Visible=false;
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to change the percentages of tax in already saved invoice

    i want to change the tax ammount in invoice, which i have already saved when i go to the change mode of invoice in (VF02) condition tab the update field is in disable mode so i cant change, please help me reguarding this issue.

    Dear Saumya,
    Reverse the accouting document which is already craeted for your invoice no., you FI consultant will help in doing so. After reversing the accouting entries update the Tax condition type with respective rate applicable and use update funcionality in VF02 and save the Invoice. This will solve your problem.
    I would like to suggest to use posting block funcionality to minimize this issue if it occuring repeatitly.
    If the solution proposed is helpfull please reward points and close.
    Thanks.
    Sumeet Sah

  • How can I view a Word document  when it tells me that someone else is using the document? This is not true as I am the only one using this Word document which is on my desktop?

    I am working on my Ancestry and today when I tried to view my Word document which awaits me on my desktop, I was told that someone else was using it. There is only me to use it, so there couldn't be anyone else. What can I try to open this document again?

    Hi,
    If you want to move the document to other library immediately, the following workarounds for your reference:
    1.Create an Event Receivers for document library and use SPFile.MoveTo
    method to move file to the other document library.
    http://msdn.microsoft.com/en-us/library/microsoft.sharepoint.spfile.moveto.aspx
    http://www.learningsharepoint.com/2010/07/04/programmatically-copy-and-move-documents-in-sharepoint-2010/  
    2.Create a workflow using SharePoint designer and use Copy List Item Action to copy file, then delete the current document.
    Thanks,
    Dennis Guo
    TechNet Community Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Dennis Guo
    TechNet Community Support

  • How do I open a WORD document which is password protected?

    I need to open a word document, which is password protected.  I can't even get to a page that'll allow me to put in the password!!!  Can anyone advise how I can do this?
    Thanks.

    Hi JoeyR.
    Thanks for your reply.
    I get the following message when I try to open the document: "The Word document is password protected and can’t be imported".
    I've looked at the Open Office software, as you suggested, but it seems confusing.  I'll give it a try, though, as I'm wasting too much time!
    Fingers Crossed!

  • How to specify the directory in which we want to store the uploaded files

    Hello !!
    I am using apache commonfile upload for uploading my files.I followed the user guide and tried to run a program,but my problem is I am not able to understand as to how to mention the directory in which the uploaded file will be saved..My code is given below :
    package r;
    import javax.servlet.*;
    import javax.servlet.http.*;
    import java.io.*;
    import java.sql.*;
    import java.util.*;
    import org.apache.commons.fileupload.*;
    import org.apache.commons.fileupload.servlet.*;
    import org.apache.commons.fileupload.disk.*;
    import org.apache.commons.io.*;
    import java.lang.Exception;
    public class fileupload extends HttpServlet
         public void doGet(HttpServletRequest request,HttpServletResponse response)throws IOException,ServletException
                   // Check that we have a file upload request
                  boolean isMultipart = ServletFileUpload.isMultipartContent(request);
                 System.out.println(isMultipart);
                 if (ServletFileUpload.isMultipartContent(request))
                 // Create a factory for disk-based file items
                   FileItemFactory factory = new DiskFileItemFactory();
                   // Create a new file upload handler
                   ServletFileUpload upload = new ServletFileUpload(factory);
                   // Parse the request
                   try {
                               List items= upload.parseRequest(request);               
                             Iterator iter = items.iterator();
                             while (iter.hasNext())
                                   FileItem item = (FileItem) iter.next();                    
                                 if (item.isFormField()) //NORMAL FORM FIELD
                                 String name = item.getFieldName();
                                  String value = item.getString();
                                  System.out.println(value);                                                             
                                  else
                                 String fileName = item.getName();
                                 System.out.println(fileName);
                                    String contentType = item.getContentType();
                                  File saveTo = new File("/info/upload_files/myFile.jpeg");
                             try
                                       item.write(saveTo);
                                       System.out.println("File written" );                    
                             catch(Exception e)
                                         System.out.println("File not written");
                                   // InputStream fs= item.getInputStream();                    
                                   fileName = FilenameUtils.getName(fileName);
                                    System.out.println(fileName);
                        }//end of try
              catch (Exception e) { }
         public void doPost(HttpServletRequest request,HttpServletResponse response)throws ServletException,IOException
                 doGet(request,response);
    The problem is that the control doesn't reach the try statement and I get " File not written" on the console because it enters catch everytime..Please tell me how the path to the directory should be given...Rest of the code is working fine

    No, the problem is that when an Exception is thrown, you ignore it completely and throw away all the information associated with it. That leaves you to guess at what the problem is. So instead of answering your guess at a good question, I'm going to suggest that in all of your catch blocks you put this code:e.printStackTrace();Then you can look at the output in the log file and see what the problem is. Start from there.

  • How can we capitalize the PR/PO, which are already booked in cost center?

    We are creating a capital Project for our department.  We have the structures ready and finalized with the budgets. But, the department has already done some commitments and expenditures in their cost center .Now, this expenditure and commitment values needs to be reflected in the report, so that correct values of assigned and available should be updated.
    1) Pls. suggest a process using which we can transfer this amount. Is this to be done by an FI entry or else we need to commit using sanction request?
    2) How can we capitalize the PR/PO, which are already booked in cost center?

    Hi,
    As we know the Contract is an Outline agreement for Quantity or Value for a particular Period with vendor.
    Without mentioning Plant also we can make contract for the Purchase organisation level for particular Material for the entire period
    Where as while creating PR  -it is an Indent for the material requiement for the specific Plant so when you refer Agreement inthe PR creation time System will ask you how much quantity to what plant you want to place indent. where as In PO  it ia an legal document so when you refer Agreement it will take all the details from Contract
    i think you are clear with my points
    With regrads
    Shrinivas gangoor
    Edited by: Shrinivas Gangoor on May 22, 2009 2:53 PM
    Edited by: Shrinivas Gangoor on May 22, 2009 2:54 PM

  • How to handle the control records in case of file to idoc scenario.

    Hi All,
    can you please clarify me how to handle the control records in case of file to idoc scenario.

    Hi,
    In File to Idoc scenario even though you selected apply control record values from payload and you are not getting those correct values which you have provided in the mapping.
    Also check the checkboxes Take sender from payload and Take receiver from payload along with the Apply control record values from payload checkbox
    Regards
    Seshagiri

  • How to handle the call transaction in method of a custom business object

    Hello all,
    There is a custom report " RPTCORAPP" for approving leaves . As per my requirement i have develop a copy of leave workflow and for approval process i have call  "RPTCORAPP" in Custom method of custom object. i have made a transaction for this custom report for approving attendances. I am calling this method though call transaction statement within method.
    Problem: while approving the attendance workitem is not disappearing from the portal. Problem is due to call transaction statement.
                   once workitem come to the user, user click on it. control goes to the report, which display all the leave to approve on
                   the portal.
                   If after approving/ rejecting attendance user close the screen.workflow remain in the "process" status.Control wont come  back after call transaction statement in the method.
                 At the same time if user clicks on back button inspite of closing the screen. it is working fine. workitem disappears from the portal.
    How to handle the scenarion. if after approving/rejecting, i want the control to come back to the NEXT STATEMENT after call transactionstatement in my method.
    Please help it out........:)

    Hi swami,
    thanks for reply. but i am not using BDC in my method. iam just calling a custom transaction thriugh statement
    Call transaction 'ZHR_APPROVE_CLINOUT'. This transaction directly run the report RPTCORAPP and display all the request.

  • How to read a pdf document which is saved on icloud

    how to read a pdf document which is saved on icloud

    Greetings jjakri,
    Welcome to the Apple Support Communities!
    It sounds like you have a PDF saved on iCloud Drive and would like to view that on your iPad. To view a PDF on your iPad, you would either need to sync from your computer view it from an email attachment. For more information on these processes, please refer to the attached article. 
    iBooks: Viewing, syncing, saving, and printing PDFs on iPhone, iPad, and iPod touch - Apple Support
    Cheers,
    Joe

  • How to find the transport request which was released to Quality

    Hi Friends,
    Could anyone please let me know, how to find the transport request that was already released from Development to Quality?
    there was some change in customization took place. I could find the user (through change log) who made these changes, however I could not find the transport request number he has already released. I did give his user name in SE10 and checked the released checkbox and did click transports to see them, however I found nothing. A message got displayed on the screen: Cross-system information for user xxx. I can't ask the Basis people about it, as its not yet been trasnported to Productive.
    Is this the correct way to see the transport request number? Is there any other way to find the number. I can give the tentative dates when the change was released.
    This post might already posted before, I did some search, could not find the exact info what I am looking for.  Would appreaciate if anyone could give the step by step method to find it.
    Thanks in advance.
    BR,
    Sats.

    Ram,
    let me tell you the the situation in a better way.
    When I see se10 with my user id I could see all the transport requests that I have released. However, now when I enter my colleague user id who did these changes (he is on vacation, otherwise I could simply ask him the transport number), nothing is shown on the page. in simple words the page is completely blank. Initially I thought it is because of some authorizations, but I can get the transport request numbers that are released by another user.
    the info what I have right now are:
    1. I knew the user name who did these chages
    2. I knew the date when it was changed.
    I just need the Transport Request number I mean which starts with DEVXXXXXXX.
    As per your solution --> If you have any idea when the reques was relase you can select the request and click on goto-transport logs. This way you can find out the request. --> I knew the date when it was released, but didnt understand, the bold and underlined sentense in your answer.. select on which request? as I said, the page was blank after I enter his user id and activate it.. May be I did not understnd your solution properly. Could you please simplify it.
    Thanks a bunch in advance
    Sats.

Maybe you are looking for

  • How do I move/copy music from iTunes to my USB stick?

    How do I move/copy music (a playlist) from iTunes to my USB stick, so that i can play it on my Media Center?

  • Need help choosing Software for a Slide Presentation

    I'd really appreciate some advice....I need to make a slide presentation with an audio soundtrack. There don't need to be any fancy special effects as the slides transition. A simple fade in & out is all I'm looking for. All I need is for some of the

  • Weblogic (WLS) / Oracle Forms & Reports (OFR) JRE lowest version parameter?

    Hi, Have WLS 11.3 and OFR 11.2 running within it. I have adjusted the parameter via the GUI for the JRE. This was to specify what version the client's JRE was in order to run OFR, if it was X version or higher it would run. I can not find this parame

  • DVD studio Pro discs still will not play

    Hi Folks, no matter what settings I change in DVD studio pro they will not play on computers or any DVD player I try.  If I print a copy off with a consumer platform like toast they play it fine.... what are the settings I need toadjust to ensure the

  • Macbook Pro charger LED goes dim.  Why?

    So a few weeks ago I went to apple to get my charger checked out.  My light was going dim and the charging indicator in the menu bar was acting weird.  They did a diagnostic and replaced the charger for me free of charge.  It was fine up until this M