You can capture the calling page URL and store it in Session or ViewState.
For example with Session, in Page_Load,
Session["PreviousPage"] = Request.Url.ToString();
Session["PreviousPage"] = Request.ServerVariables("HTTP_REFERER");
And then in your final event (perhaps Savebutton_Click or CloseButton_Click), you can do a redirect in either of these ways:
Response.Redirect(Session["PreviousPage"].ToString(), false);
Response.Redirect(Request.ServerVariables("HTTP_REFERER"), false);