We have answer of your question!

100% solved queries, no empty question

Question: Disposable Ajax.ActionLink like Ajax.BeginForm


0

I can write form and it's content like this:

@using(Ajax.BeginForm(...)){
    // html content here
}

Rendered as:

<form>
    // html content here
</form>

Is it possible to do same with Ajax.ActionLink?

@using(Ajax.ActionLink(...)){
    // html content here
}

Rendered:

<a>
    // html content here
</a>
Question author Karaxuna | Source

Answer


1


No you can't, Ajax.ActionLink returns MvcHtmlString which is not disposable.

You can instead create the link yourself as in this extension method example.

Answer author Grayking

Tickanswer.com is providing the only single recommended solution of the question Disposable Ajax.ActionLink like Ajax.BeginForm under the categories i.e c# , html , asp.net-mvc , asp.net-mvc-3 , . Our team of experts filter the best solution for you.

Related Search Queries:


You may also add your answer

Thanks for contributing an answer to Tick Answer!