so the legend never moves no matter what the putcoords are?
my code for a creating/placing a legend (using putcoords to place it) is pretty long but i can post it up if it will help.
I think that is correct. For example, if I replace the PutCoords line with this one, it simply resizes the legend (making it larger) and appears to keep the same position:
pEnv.PutCoords(1, 1, 4, 4)
Here is the full Sub that I am using to add the Legend:Public Sub AddMapSurrounds()
Dim pMxDoc As IMxDocument
Dim pActiveView As IActiveView
Dim pEnv As IEnvelope
Dim pId As New UID
Dim pMapSurround As IMapSurround
pMxDoc = m_pApp.Document
pActiveView = pMxDoc.PageLayout
pEnv = New Envelope
pEnv.PutCoords(0.4, 1.3, 1.75, 2.75)
pId.Value = "esricore.Legend"
pMapSurround = CreateSurround(pId, pEnv, "Index Reporting", pMxDoc.FocusMap, pMxDoc.PageLayout)
pMapSurround.Refresh()
pActiveView.PartialRefresh(esriViewDrawPhase.esriViewGraphics, Nothing, Nothing)
End Sub