View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Gary Gary is offline
external usenet poster
 
Posts: 273
Default How to add this function to Personal Workbook

I have this *.bas file with the following code -

Attribute VB_Name = "Module1"

Function ConCatRange(CellBlock As Range) As String
Dim cell As Range
Dim sbuf As String
For Each cell In CellBlock
If Len(cell.Text) 0 Then sbuf = sbuf & cell.Text & ", "
Next
ConCatRange = Left(sbuf, Len(sbuf) - 1)
End Function


How would I add this as a module or add-in so it would be available for use.
Right now, if I import the file it works but would rather not have to do
that for each new file.

Thanks.