how do i set a value to a range using a function from module in excel vba?
Posted
by gadym
on Stack Overflow
See other posts from Stack Overflow
or by gadym
Published on 2010-04-23T14:41:51Z
Indexed on
2010/04/23
15:03 UTC
Read the original article
Hit count: 152
hello all,
i want to do a simple function in a module in excel vba, so i can use it as a custom function in excel. (i use excel 2003, or 2007 , it's doesnt matter)
i create a function(!) in a new workbook and it's looks like this:
Function a() Sheets(1).Range("A1").Value = 4 end function
but when i try to use it on the sheet1 it's wont work! i tried many things.
how can i make this work (with no workarounds, i want to use it as a custom function) ?
please help. thanks, gadym
© Stack Overflow or respective owner