Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 252
Default "%^{F9}" doesn't cause calcaulation

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3,365
Default "%^{F9}" doesn't cause calcaulation

How about using the .Calculate method? Is this code in Excel or another
application?


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,501
Default "%^{F9}" doesn't cause calcaulation

Try,

Application.Calculate

Mike

"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,058
Default "%^{F9}" doesn't cause calcaulation

Sub kick_it()
Application.SendKeys "{F9}"
DoEvents
End Sub

will cause a single calculation, but will leave the mode in Manual
--
Gary''s Student - gsnu200731


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 252
Default "%^{F9}" doesn't cause calcaulation

Hi,

it is in Excel 2000.
--
thank you so much for your help


"JLatham" wrote:

How about using the .Calculate method? Is this code in Excel or another
application?


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help



  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default "%^{F9}" doesn't cause calcaulation

Application.Calculation isn't equivalent to the sendkeys you show.

Try using Application.CalculationFull

--
Regards,
Tom Ogilvy


"clara" wrote:

Hi,

it is in Excel 2000.
--
thank you so much for your help


"JLatham" wrote:

How about using the .Calculate method? Is this code in Excel or another
application?


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #7   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 252
Default "%^{F9}" doesn't cause calcaulation

Hi Tom,

Could you tell me the difference between the two method? They all works well.

Clara
--
thank you so much for your help


"Tom Ogilvy" wrote:

Application.Calculation isn't equivalent to the sendkeys you show.

Try using Application.CalculationFull

--
Regards,
Tom Ogilvy


"clara" wrote:

Hi,

it is in Excel 2000.
--
thank you so much for your help


"JLatham" wrote:

How about using the .Calculate method? Is this code in Excel or another
application?


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #8   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 252
Default "%^{F9}" doesn't cause calcaulation

Hi Gary's Student,

When I run my macro which contains your method, F5 press became F9 press
that means a break point is set at the line I press F5 instead of running the
macro.
Could you tell me the reason. The same thing happened to me before.

Clara
--
thank you so much for your help


"Gary''s Student" wrote:

Sub kick_it()
Application.SendKeys "{F9}"
DoEvents
End Sub

will cause a single calculation, but will leave the mode in Manual
--
Gary''s Student - gsnu200731


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

  #9   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 415
Default "%^{F9}" doesn't cause calcaulation

Keys are sent to the active application, whichever that is.
So you cannot run such code from the VBA IDE and consequently cannot debug
it.
Run from the click a button will work.

NickHK

"clara" ...
Hi Gary's Student,

When I run my macro which contains your method, F5 press became F9 press
that means a break point is set at the line I press F5 instead of running
the
macro.
Could you tell me the reason. The same thing happened to me before.

Clara
--
thank you so much for your help


"Gary''s Student" wrote:

Sub kick_it()
Application.SendKeys "{F9}"
DoEvents
End Sub

will cause a single calculation, but will leave the mode in Manual
--
Gary''s Student - gsnu200731


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help



  #10   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 6,953
Default "%^{F9}" doesn't cause calcaulation

CalculateFull does a more complete recalculation of the workbook. It doesn't
just recalculate the cells which excel considers in need of calculation -
this is what calculate does. Since you didn't write the macro, the original
author appeared to want to do a CalculateFull (which did not exist as a macro
command in xl97 and thus many used the sendkeys combination you show).

From VBA help:
CalculateFull:
Forces a full calculation of the data in all open workbooks.
CalculateFullRebuild: (added in xl2002 I believe)
For all open workbooks, forces a full calculation of the data and rebuilds
the dependencies.

-------------------------------------------
Calculate:
Calculates all open workbooks, a specific worksheet in a workbook, or a
specified range of cells on a worksheet, as shown in the following table.

When using "calculate", To calculate Follow this example
All open workbooks - Application.Calculate (or just Calculate)
A specific worksheet - Worksheets(1).Calculate
A specified range - Worksheets(1).Rows(2).Calculate
----------------------------------------


Whether the more thorough calculation is actually required or not, I can't
say.

--
Regards,
Tom Ogilvy


"clara" wrote:

Hi Tom,

Could you tell me the difference between the two method? They all works well.

Clara
--
thank you so much for your help


"Tom Ogilvy" wrote:

Application.Calculation isn't equivalent to the sendkeys you show.

Try using Application.CalculationFull

--
Regards,
Tom Ogilvy


"clara" wrote:

Hi,

it is in Excel 2000.
--
thank you so much for your help


"JLatham" wrote:

How about using the .Calculate method? Is this code in Excel or another
application?


"clara" wrote:

Hi all,


I use Application.SendKeys "%^{F9}", True to cause calculation, but it
failed. My Excel version 2000.

Clara

--
thank you so much for your help

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
Excel - Golf - how to display "-2" as "2 Under" or "4"as "+4" or "4 Over" in a calculation cell Steve Kay Excel Discussion (Misc queries) 2 August 8th 08 01:54 AM
change "true" and "false" to "availble" and "out of stock" inthestands Excel Worksheet Functions 2 July 19th 07 07:05 PM
HELP on "left","right","find","len","substitute" functions serene83 Excel Discussion (Misc queries) 5 June 27th 06 02:23 AM
Count occurences of "1"/"0" (or"TRUE"/"FALSE") in a row w. conditions in the next BCB New Users to Excel 7 May 13th 06 10:02 PM
If changed array formula reduce ""\""\""\ - signs to #Missing, will it make ... Maria J-son[_2_] Excel Programming 2 March 5th 06 12:20 PM


All times are GMT +1. The time now is 11:44 PM.

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

About Us

"It's about Microsoft Excel"