Calling a VBA procedure from an excel cell function

L

Luke Bellamy

Hi,
Just wondering is you can call a VBA subroutine in an excel
cell function?

Example:
' Function in Sheet 1
Public Function MyName() as String
MyName = "Luke"
End Function

Then in an cell, say "A1" put something like
=MyName() and it shows "Luke" in that cell.

I read a little on a function called "CALL" but it
didn't seem that friendly and I couldn't get it to work.

Thankyou
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top