Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 77
Default Run only part of a macro for testing

Is it possible to run only a portion of a macro?

I am writing a long involved macro and I need to test each section to make
sure it is producing the desired result before I write the next section of
the macro. I was hoping I could run Section 1, write section 2, run section
2 only, write section 3, run section 3 only...

How can I do that?
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 400
Default Run only part of a macro for testing

Press F9 on the first line of the macro, hen run it: it will stop on that
line. Press F8 to jump through the lines. If you hover the mouse pointer over
any variable names above the cursor line, the values of those variables are
shown as tooltips. Alternatively, query the variables in the Immediate
Window. If you want to jump n lines below, click on the line you want to go
to, click Debug, Select Set Next Statement and Press F5. If you want to stop
altogether, click the reset icon on the standard toolbar.

"Josh O." wrote:

Is it possible to run only a portion of a macro?

I am writing a long involved macro and I need to test each section to make
sure it is producing the desired result before I write the next section of
the macro. I was hoping I could run Section 1, write section 2, run section
2 only, write section 3, run section 3 only...

How can I do that?

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 184
Default Run only part of a macro for testing

Hi Josh,

Is it possible to run only a portion of a macro?


in the VBA Editor you'll find everything you need in menu "debug". (F8,
F9, CTRL+F9.... F5)

arno

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
testing range of cells for part of cell content Daniel Excel Worksheet Functions 5 March 25th 10 08:14 PM
Replace Old Part Numbers with New Part Numbers in a Macro. Jeffery Keown Excel Discussion (Misc queries) 5 October 17th 06 03:45 PM
Testing Spreadsheet Cells while in a Macro Amaross Excel Discussion (Misc queries) 2 May 2nd 06 09:03 PM
Testing in a macro for bad range name? Don Wiss Excel Programming 1 November 3rd 04 02:26 AM
Macro Date Testing BKBK Excel Programming 0 October 28th 04 05:42 PM


All times are GMT +1. The time now is 04:00 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"