Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 19
Default cmdbarmenu focus problem

Dear all,

I have a complex form using Excel, the processes on the form all work well.
I have removedmenu bar items that are not required and added ones of my own
to manage how users use the form. This enables actions that are required and
disables actions that are not.

My problem is that when a user activates acell or range on the form and then
goes to use one of the menu bar items it does not work. They have to release
the cell first. Is there a way of taking focus from the cell and ensuring
that the menu bar item gets it and the on action then works?

Here is the code I use to set the items (this is one of about 5)

Set CmdBarMenu = CmdBar.Controls.Add(Type:=msoControlPopup, befo=hindex)
CmdBarMenu.Caption = "&Refresh Form"
CmdBarMenu.OnAction = "'" & ThisWorkbook.Name & "'!thisworkbook.refreshform"

Manmy thanks for any help or advice in advance.

Paul

--
Message posted via http://www.officekb.com

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 3,290
Default cmdbarmenu focus problem


With the cursor active inside the cell it is impossible to get a
menu item to work. That is just the way Excel is.
You will have to make sure your users understand that.

An alternative is to uncheck the "Move Selection After Enter" setting
on the Edit tab in Tools | Options.
--
Jim Cone
San Francisco, USA
http://www.realezsites.com/bus/primitivesoftware



"pjbur2005 via OfficeKB.com" <u18722@uwe
wrote in message
Dear all,
I have a complex form using Excel, the processes on the form all work well.
I have removedmenu bar items that are not required and added ones of my own
to manage how users use the form. This enables actions that are required and
disables actions that are not.

My problem is that when a user activates acell or range on the form and then
goes to use one of the menu bar items it does not work. They have to release
the cell first. Is there a way of taking focus from the cell and ensuring
that the menu bar item gets it and the on action then works?

Here is the code I use to set the items (this is one of about 5)

Set CmdBarMenu = CmdBar.Controls.Add(Type:=msoControlPopup, befo=hindex)
CmdBarMenu.Caption = "&Refresh Form"
CmdBarMenu.OnAction = "'" & ThisWorkbook.Name & "'!thisworkbook.refreshform"

Manmy thanks for any help or advice in advance.

Paul

--
Message posted via http://www.officekb.com

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 19
Default cmdbarmenu focus problem

Jim Thanks for you reply,

Appreciate your point but why then is not the same for "file", "View" or any
other menu bar item appart from those I have added?

Unchecking the "move Seelction........" made no differance.

I have around 400 to 600 users, some understand, some think they do and the
rest cant be bothered too!

Paul

Jim Cone wrote:
With the cursor active inside the cell it is impossible to get a
menu item to work. That is just the way Excel is.
You will have to make sure your users understand that.

An alternative is to uncheck the "Move Selection After Enter" setting
on the Edit tab in Tools | Options.


--
Message posted via OfficeKB.com
http://www.officekb.com/Uwe/Forums.a...tions/200701/1

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Problem using newly created user function in Excel 2003 Richard Excel Discussion (Misc queries) 10 January 22nd 07 12:44 AM
Urgent Help Required on Excel Macro Problem Sachin Shah Excel Discussion (Misc queries) 1 August 17th 05 06:26 AM
Problem With Reference Update Egon Excel Worksheet Functions 17 July 16th 05 05:45 AM
Copy an Drag cell Formula Problem Nat Excel Discussion (Misc queries) 1 June 20th 05 03:24 PM
Freeze Pane problem in shared workbooks JM Excel Discussion (Misc queries) 1 February 1st 05 12:04 AM


All times are GMT +1. The time now is 02:58 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"