VBA Questions

bellram81

New Member
Joined
Mar 17, 2013
Messages
4
:) Hello!, i have been trying to use send keys in a application(not a web app.) but it was not working. I have used sendkeys and application.sendkeys even though it was not working. Pls tell another codes. in that window i want to press f11 and f12 and also file menus.
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.
Try calling AppActivate first:
Code:
AppActivate "Title of application window"  'change string to the full title of the application's window or the string it begins with
SendKeys "{F11}"    'F11
SendKeys "%FI"      'Alt F I
If the application conforms to Windows standards then file menus are accessed by pressing the Alt key followed by one or more keys, as shown.

VBA SendKeys is very unreliable and if it doesn't work you could try this SendKeys emulator which allows you to specify the window which receives the key presses. Download the VB6 version and put the code in a VBA module and it should compile after making some minor edits.
 
Upvote 0
Yes, i have used the same coding what you have given here, Even though it was not working. That appln is more secure even we cant select or copy anything. Then how can i use sendkeys here? Realy i need your help here pls.Thanks.
 
Upvote 0
Appactivate("appname")sendkeys "{F11}",[100]& sendkeys "{F11}", True.This is the code what i have used. I dnt know how to use sendkey emulator. Help me out pls
 
Upvote 0
What is the window title (caption) of the application you are trying to control? I need this information in order to write code for the SendKeys emulator.
 
Upvote 0

Forum statistics

Threads
1,213,539
Messages
6,114,221
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top