PC Review


Reply
Thread Tools Rate Thread

Calling Excel shortcuts from VBA

 
 
M G
Guest
Posts: n/a
 
      20th May 2010
Hi,

I am trying to automate the following two excel shortcuts using VBA. I know I can use commandbar and commandcontrol to call excel menus but I can not find the submenus these shortcuts belong to.

1. Ctrl + [ -- cursor goes to the precedent cell
2. F5 + Enter -- cursor goes to the original cell


Also, is it possible to call an excel shortcut from VBA? I know that one can call a worksheet function from VBA (For example, Application.WorksheetFunction.Fact(5) ). But is there way to call a shortcut, say Ctrl + C from VBA?

Thanks,

MG.


Submitted via EggHeadCafe - Software Developer Portal of Choice
Parallel Programming in C# 4.0: A Short Synopsis
http://www.eggheadcafe.com/tutorials...ming-in-c.aspx
 
Reply With Quote
 
 
 
 
Gary''s Student
Guest
Posts: n/a
 
      20th May 2010
Just make the VBA do what the shortcut does.
CNTRL+[
can be implemented by:
Selection.DirectPrecedents.Select
--
Gary''s Student - gsnu201003


"M G" wrote:

> Hi,
>
> I am trying to automate the following two excel shortcuts using VBA. I know I can use commandbar and commandcontrol to call excel menus but I can not find the submenus these shortcuts belong to.
>
> 1. Ctrl + [ -- cursor goes to the precedent cell
> 2. F5 + Enter -- cursor goes to the original cell
>
>
> Also, is it possible to call an excel shortcut from VBA? I know that one can call a worksheet function from VBA (For example, Application.WorksheetFunction.Fact(5) ). But is there way to call a shortcut, say Ctrl + C from VBA?
>
> Thanks,
>
> MG.
>
>
> Submitted via EggHeadCafe - Software Developer Portal of Choice
> Parallel Programming in C# 4.0: A Short Synopsis
> http://www.eggheadcafe.com/tutorials...ming-in-c.aspx
> .
>

 
Reply With Quote
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Calling Excel shortcuts from VBA JLGWhiz Microsoft Excel Programming 0 20th May 2010 04:35 PM
calling a C++ program from Excel 2000 and passing a result from C++ back to an excel spreadsheet ellis kurland Microsoft Excel Misc 3 15th Aug 2005 04:10 PM
HELP! - Calling Windows Scripting Host from C# to Create Shortcuts G$ Microsoft C# .NET 1 4th Nov 2004 04:09 AM
Shortcuts in Explorer not working for Excel, but opens within Excel Brian @ SMS Microsoft Excel Misc 1 28th Feb 2004 01:36 AM
Excel Shortcuts do not work in Explorer, but open in Excel (periodically) Microsoft Excel Misc 1 27th Feb 2004 09:19 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 09:16 PM.