1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Help needed in hooking MS Office File Open/Save Dialog ........

Discussion in 'C++' started by dinu, Jul 8, 2010.

  1. dinu

    dinu New Member

    Joined:
    Dec 28, 2009
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    Dear all,

    I want to know how to hook Microsoft Office File Open/Save Dialog box.

    My exact requirements are as follows:

    1. To get the full path of the MS office file that is opened(it could be word, power point or excel file)

    2. If the user saves the file using "save as" option, I would like to get the full path of the target file


    I appreciate any help in this direction.

    I am using VC++ on windows XP

    Thanks in advance........
     
  2. NewsBot

    NewsBot New Member

    Joined:
    Dec 2, 2008
    Messages:
    1,267
    Likes Received:
    1
    Trophy Points:
    0
    Not sure I am able to get your requirement but do you mean your application is running in the background and want to track what user does with Office or you want your application to launch the process of Office XP and then track if user is saving any file or doing something else.
     
  3. dinu

    dinu New Member

    Joined:
    Dec 28, 2009
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    Yes you are right. My program runs in the background and I want to monitor the "Save as" user activity of Microsoft Office files. My program needs to get following informations:

    1. File name and path of the opened file(
    2. File name and path of the target file(which is saved using 'Save as' menu option)

    Hope I am clear with the requirement...

    Any pointers in this regard would be of great help

    Regards
     
  4. NewsBot

    NewsBot New Member

    Joined:
    Dec 2, 2008
    Messages:
    1,267
    Likes Received:
    1
    Trophy Points:
    0
    I am not sure I can point you with anything but the path to solution can be in 2 directions.

    1. You watch for Shell Events about any doc extension files and each time some events are encountered you can take needed action but take care that copy paste of word files are taken care nicely.

    2. Other option could be using the findwindow to see if MS word is running and see if there is any save window is opened by user.

    I guess you can mix and match the above 2 make more efficient algo on the same.
     
  5. dinu

    dinu New Member

    Joined:
    Dec 28, 2009
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    0
    I have tried the ideas, but it wont work.
    Anyways thanks
     

Share This Page