#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2003
    Posts
    64
    Rep Power
    12

    simulate MenuClick


    With this code:
    Code:
    HMENU MAINMENU= GetMenu(Handle);
    HMENU SubMenu1=GetSubMenu(MAINMENU,0);
    HMENU SubMenu2=GetSubMenu(SubMenu1,0);
    DeleteMenu(SubMenu2,2,MF_BYPOSITION);
    I can delete the items from a menu of an any application.
    But how can I simulate the click on an item? For example I want to show the save as dialog of Notepad. I know that there is a way to do this with WM_MENUSELECT but I do not know how to use it.
    Last edited by SirX; November 1st, 2003 at 12:09 PM.
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Aug 2003
    Posts
    64
    Rep Power
    12
    Well I found a way to open the "open file"-dialog. Now I have to pass a path into the "path-editbox" and after this I musst press the OK button. Does anybody knows a way how to do this? The only thing I have is the handle to the mainform.

IMN logo majestic logo threadwatch logo seochat tools logo