Results 1 to 6 of 6

Thread: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

  1. #1

    Thread Starter
    New Member
    Join Date
    Oct 2009
    Posts
    12

    Unhappy Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Hi,
    I would really appreciate if anyone coul help me.
    I am trying automate a process using MS Office 2007 macros. The process involves opening a *.tnd file which automatically opens in an engineering software called TRANED and then running the analysis.
    There are no hot keys to run the software. usually running it involves clicking the "Run TRANSYT" button when the file opens, which completes the run and then "produce report" button to create the report.

    How can i automate this process using excel? I have managed to open the file using Shellexecute, but it just opens the file. how can i run it and produce report automatically? is it possible to get macros to somehow press these buttons to run the program and save the report. I am really desperate. I need to finish this work asap. Please help!!!

    Edit by admin: no contact info permitted on the forum, thank you

  2. #2
    Discovering Life Siddharth Rout's Avatar
    Join Date
    Feb 2005
    Location
    Mumbai, India
    Posts
    12,001

    Re: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Welcome to the forums

    Are you using XP or Vista?
    A good exercise for the Heart is to bend down and help another up...
    Please Mark your Thread "Resolved", if the query is solved


    MyGear:
    ★ CPU ★ Ryzen 5 5800X
    ★ GPU ★ NVIDIA GeForce RTX 3080 TI Founder Edition
    ★ RAM ★ G. Skill Trident Z RGB 32GB 3600MHz
    ★ MB ★ ASUS TUF GAMING X570 (WI-FI) ATX Gaming
    ★ Storage ★ SSD SB-ROCKET-1TB + SEAGATE 2TB Barracuda IHD
    ★ Cooling ★ NOCTUA NH-D15 CHROMAX BLACK 140mm + 10 of Noctua NF-F12 PWM
    ★ PSU ★ ANTEC HCG-1000-EXTREME 1000 Watt 80 Plus Gold Fully Modular PSU
    ★ Case ★ LIAN LI PC-O11 DYNAMIC XL ROG (BLACK) (G99.O11DXL-X)
    ★ Monitor ★ LG Ultragear 27" 240Hz Gaming Monitor
    ★ Keyboard ★ TVS Electronics Gold Keyboard
    ★ Mouse ★ Logitech G502 Hero

  3. #3

    Thread Starter
    New Member
    Join Date
    Oct 2009
    Posts
    12

    Re: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Many thanks for your reply.
    I have VISTA at home but at my workplace were i need to use this macro I have XP. So its Windows XP i am interested in.
    Any help would be much appreciated.

    Thanks
    Noman

  4. #4
    Discovering Life Siddharth Rout's Avatar
    Join Date
    Feb 2005
    Location
    Mumbai, India
    Posts
    12,001

    Re: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Ok...

    You can use ShellExecute to open the file, which you already are doing.
    Since you are using XP, Have you considered the option of using sendkeys?
    A good exercise for the Heart is to bend down and help another up...
    Please Mark your Thread "Resolved", if the query is solved


    MyGear:
    ★ CPU ★ Ryzen 5 5800X
    ★ GPU ★ NVIDIA GeForce RTX 3080 TI Founder Edition
    ★ RAM ★ G. Skill Trident Z RGB 32GB 3600MHz
    ★ MB ★ ASUS TUF GAMING X570 (WI-FI) ATX Gaming
    ★ Storage ★ SSD SB-ROCKET-1TB + SEAGATE 2TB Barracuda IHD
    ★ Cooling ★ NOCTUA NH-D15 CHROMAX BLACK 140mm + 10 of Noctua NF-F12 PWM
    ★ PSU ★ ANTEC HCG-1000-EXTREME 1000 Watt 80 Plus Gold Fully Modular PSU
    ★ Case ★ LIAN LI PC-O11 DYNAMIC XL ROG (BLACK) (G99.O11DXL-X)
    ★ Monitor ★ LG Ultragear 27" 240Hz Gaming Monitor
    ★ Keyboard ★ TVS Electronics Gold Keyboard
    ★ Mouse ★ Logitech G502 Hero

  5. #5

    Thread Starter
    New Member
    Join Date
    Oct 2009
    Posts
    12

    Re: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Thanks for your prompt reply. I havn't used it as yet. Do u have an example?
    Basically, i just want to some how press the buttons to execute and produce the report.
    I have noticed if I press 'Alt' then 'right arrow' key 9 times, then 'down arrow key once' and then press enter, the program runs. Ca i somehow get macro to perform this operation??

    Thanks

  6. #6
    Discovering Life Siddharth Rout's Avatar
    Join Date
    Feb 2005
    Location
    Mumbai, India
    Posts
    12,001

    Re: Automate Programs that are not .exe - how can i control keyboard keys or mouse???

    Search the forums on sendkeys... There are plenty of examples in the forums.
    A good exercise for the Heart is to bend down and help another up...
    Please Mark your Thread "Resolved", if the query is solved


    MyGear:
    ★ CPU ★ Ryzen 5 5800X
    ★ GPU ★ NVIDIA GeForce RTX 3080 TI Founder Edition
    ★ RAM ★ G. Skill Trident Z RGB 32GB 3600MHz
    ★ MB ★ ASUS TUF GAMING X570 (WI-FI) ATX Gaming
    ★ Storage ★ SSD SB-ROCKET-1TB + SEAGATE 2TB Barracuda IHD
    ★ Cooling ★ NOCTUA NH-D15 CHROMAX BLACK 140mm + 10 of Noctua NF-F12 PWM
    ★ PSU ★ ANTEC HCG-1000-EXTREME 1000 Watt 80 Plus Gold Fully Modular PSU
    ★ Case ★ LIAN LI PC-O11 DYNAMIC XL ROG (BLACK) (G99.O11DXL-X)
    ★ Monitor ★ LG Ultragear 27" 240Hz Gaming Monitor
    ★ Keyboard ★ TVS Electronics Gold Keyboard
    ★ Mouse ★ Logitech G502 Hero

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width