Create a generic method that both buttons call to show the modal popup.
Give each button a different CommandArgument.
Create a hidden field in the modal popup and save this value there.
Public Sub SowModal(ByVal sender As Object, ByVal e As System.EventArgs)
Dim strWhichButton As Button = CType(sender, Button)
Dim strArgument As String = strWhichButton.CommandArgument
' Populate the hidden field in the modal popup
hdnButton.Value = strArgument
' Show the modal popup
myModal.Show()
End Sub
When closing the modal popup, retrieve the value from the hidden field and that will determine which textbox to populate.
Tim