View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
joel[_483_] joel[_483_] is offline
external usenet poster
 
Posts: 1
Default CommandCombo BOX want to populate all named ranges in it


Try this code


Set BookNames = Application.Names
NamesCount = BookNames.Count

For Each Nm In BookNames
NmReferto = Nm.RefersTo
'remove equal sign
NmReferto = Replace(NmReferto, "=", "")
MsgBox ("Name : " & Nm.Name & " ; RefersTo : " & NmReferto)
'set to a variable
Set MyRange = Range(NmReferto)
Next Nm


--
joel
------------------------------------------------------------------------
joel's Profile: 229
View this thread: http://www.thecodecage.com/forumz/sh...d.php?t=167027

Microsoft Office Help