View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Dave Peterson Dave Peterson is offline
external usenet poster
 
Posts: 35,218
Default calling a macro within an excel formula

Nope.

You can use a user defined function in that formula, but (almost) all that it
can do is return a value to the cell that contains that function/formula.

Maybe you can add a button from the Forms toolbar and assign your macro to
that. Then tell the user to hit the button to run the macro when they need it.

rahne059 wrote:

Is it possible to call a macro from within and excel 2003 If statement as
follows:

=If(IF(M2 <=LASTSN,copymacro[then i want to call a print macro and move down
a row and repeat this formula for M3, until M# is no longer <= LASTSN)

I have been unsuccessfully trying to find and modify macros that others used
to create sequential serial numbers for a week now, and have not yet got them
to work; probably because I have never worked with Visual Basic before and do
not really understand its syntax.

--
rahne059


--

Dave Peterson