Hello and thank you for looking at my thread.
I am working on a project that will take a pile of reports and email them to specific people for me. This is a generic version of the spreadsheet I will use to control who is emailed the various reports --> reportemails.xlsx
I am at the beginning of the project right now. I want to build a function that will read the values of the A1 cell and will create a menu that offers the user a list of all of the communities described in that cell. The user will then either shift-click and/or ctrl-click from the built menu. The selections that the user chooses will be stored in an array for later processing in another function.
I have no clue how to build this menu. All I have is the following code that reads A1 and breaks it into an array (ComCodeArray) and then plays a little bit with it. The ComCodeAll string is only there so I know I am building the array right and using the proper syntax.
Function SetCommunities()
Dim ComCodeArray As Variant
Dim ComCodeAll As String
Dim ComCodeIndex As Integer
ComCodeArray = Split(Range("A1").Value, "|")
For ComCodeIndex = LBound(ComCodeArray) To UBound(ComCodeArray)
ComCodeAll = ComCodeAll & vbCrLf & ComCodeArray(ComCodeIndex)
Next ComCodeIndex
MsgBox ComCodeAll
End Function
Thank you for any help that you can offer me.
Bookmarks