html.actionlink Questions

4

I want to use "data-toggle" wiht actionLink. Like this; Html.ActionLink("Delete", "Users", "Admin", new { item.UserId , strRole = strRole }, new { id = "cmdDelete", href="#myAlert", data-toggle="...
Amateurism asked 19/10, 2012 at 14:12

7

Solved

Currently in a link Customer/businessunit/RepresentativeDetails?RepresentativeId=cd3a7263-78f7-41bd-9eb0-12b30bc1059a I have following code for view @Html.ActionLink("Back to List", "Index") ...
Hohenstaufen asked 27/8, 2013 at 12:48

4

Solved

The problem in Html.ActionLink() is that you can't add additional html content inside the tag that it generates. For example, if you want to add an icon besides the text like: <a href="/Admin/U...
Morentz asked 20/5, 2015 at 5:50

10

Solved

I have a view with a button. When the user clicks the button I want them redirected to a data entry view. How do I accomplish this? I should mention the views are created, tested, and functioning. ...
Brunelle asked 2/7, 2010 at 19:28

6

Solved

I would like to use custom @Html.ActionLink I am trying to use the following code:- public static class LinkExtensions { public static MvcHtmlString MyActionLink( this HtmlHelper htmlHelper, ...
Reverso asked 2/10, 2012 at 14:14

21

is there anyway to have an image act as an ajax actionlink? I can only get it to work using text. Thanks for your help!
Goulder asked 4/12, 2008 at 18:40

3

Solved

I need to be able to dynamically retrieve the current action and controller name of whatever page you're on, and actually use them to create a new HTML.ActionLink that links to the same action and ...

2

Solved

In my controller I have this: ViewBag.lstIWantToSend= lstApps.Select(x => x.ID).ToList(); // creates a List<int> and is being populated correctly I want to pass that list to another con...
Badajoz asked 15/3, 2017 at 17:15

3

Solved

I have the following ActionLink: @Html.ActionLink("Upload", "Upload", "File") yet when I hover over the link, the url displayed in the browser is http://localhost:44334/Upload. Where is the cont...

4

Solved

I was trying to create an option to switch between a list view and widget view in ASP.net MVC (with razor view engine). However, I am having some trouble trying to both add an image, as well as s...
Sunroom asked 6/10, 2014 at 9:47

4

Solved

Is it possible to use HTML tags in the linkText of Html.ActionLink? For instance, if I wanted to bold part of the text of a link I would try something similar to this: <%= Html.ActionLink("Some...
Bookbindery asked 8/2, 2011 at 18:11

3

Solved

This works <a href="@Url.Action("edit", "markets", new { id = 1 })" data-rel="dialog" data-transition="pop" data-icon="gear" class=&...
Lifework asked 5/11, 2010 at 18:32

5

Solved

how to insert image in html.actionlink - asp.net mvc? i did it so, but it doesnt works. <a href="<%= Html.ActionLink("search", "Search", new { searchText = "txtSearch" }, null); %>"> ...
Silent asked 8/9, 2010 at 13:2

3

Solved

I have an actionlink in view, I need it to pass parameter containing hyphen (-). Changing the name convention is not possible. How do I do this? <li>@Html.ActionLink("abc", "abc", "abc", new...
Adalbert asked 17/12, 2014 at 17:52

3

Solved

i have @Html.ActionLink("Remove 1034, 1035, 1036", "RemoveSelected") Now i want to set each id from Controller for example: @Html.ActionLink(ViewBag.RemoveSelectedTitle, "RemoveSelected") //t...
Fiveandten asked 9/6, 2011 at 12:31

3

Solved

Is there anything wrong with this html? I want to have a link in the masterpage to navigate to "CreateParts" view. I have action 'CreateParts' which have a parameter parentPartId in the controller ...
Selfaggrandizement asked 28/11, 2011 at 9:39

1

Solved

I have an object containing searching, sorting and paging parameters as well as an id of a record to be edited. I'd like to pass this object into Html.ActionLink() as a route value object, so that...
Pillsbury asked 19/5, 2014 at 16:55

3

Solved

I have an ASP.NET MVC 4 application. There is a razor view in my application that works with List type as a model. @model List<MeetingLog.Models.UserModel> @{ Layout = null; } . . . I am...
Agnew asked 14/10, 2013 at 11:29

1

Solved

I'm trying to pass an object through an ActionLink to a method in an MVC controller. The razor syntax: @Html.ActionLink("Export to Excel","ReturnExcelOfViewableResponses",new { SearchObject = Mod...
Absorbed asked 23/8, 2013 at 22:47

1

Solved

I am passing this : <%: Html.ActionLink("Edit", "EditCRMRequest", "CRM", new { Id = item.Id })%> and I am getting in browser : http://something.com/CRM/EditCRMRequest?Length=3 with Erro...
Pournaras asked 4/2, 2013 at 13:19

1

Solved

in asp.net mvc, I have a view with name index that show one html table as a grid. suppose this is this my html table: <table> <tr> <th> Caption </th> <th></th&...
Harmonic asked 18/1, 2013 at 20:15

2

Solved

I am trying to make a MVC website with Ajax call. I have no problem using directly jquery, but when i use @Ajax.ActionLink, i don't get the result i want. Here is my view: <script type="text/j...
Clemens asked 12/10, 2012 at 14:37

3

Solved

I have an MVC3 C#.NET web app and need to call a view using Html.ActionLink. I can't tell from the documentation if I can specify the POST or GET. Below is my HTML, is there a way to specify GET or...
Caniff asked 7/12, 2011 at 19:13

2

Solved

I am attempting to utilise KnockoutJS and MVC 4 in order to display a table with ActionLink definitions in the first column of the table. Displaying the data itself is extremely straight-forward an...

4

Solved

Is there a way to create a strongly typed T4MVC ActionLink with a hash/pound/fragment in it? For example, here is the link I'd like to create: <a href="/Home/Index#food">Feed me</a> ...
Acro asked 27/5, 2010 at 12:19

© 2022 - 2024 — McMap. All rights reserved.