When calling a page with Redirect is giving error

0

This is the error you are giving:

Unable to evaluate expression because the code is optimized or a native frame is on top of the call stack.

And this is the complete call code in my master.

protected void lkbConsultarProcessos_Click(object sender, EventArgs e)
        { 
            try
            { 
                Response.Redirect("/frmPVListaProcessos.aspx");
            }
            catch (Exception Ex)
            {
                wucMasterMensagens.ExibirMensagem(WUC.wucMensagens.TipoAlerta.Erro, Ex.Source, Ex.Message, Ex.StackTrace);
            }
        }
    
asked by anonymous 24.11.2014 / 20:01

1 answer

1
Request.Redirect(url, false);

Use the value false in the endResponse! parameter

    
24.11.2014 / 20:50