asp.net-core


(Resolved) #Url.Action in ASP.NET Core does not exist


I can't use #Url.Action in ASP.NET Core because I have error:
IUrlHelper has no applicable method named Action
I want to use #Url.Action for:
page i
In ASP.NET MVC it generated me urls for example:
/Home/List?page=5&search=abc
In ViewBag.routeValues I pass additional parameters, for example: search=abc&active=true and paste it to url after 'page' parameter.
I think I can't do the same using tag helper and 'asp-route' - so what can I do?
-----------------------------------------------------
Ok - I need to cas ViewBag to string:
page i
You should first read the ASP.NET Core Documentation to find out what tag helpers are and how to use them.
In ASP.NET Core's Razor implementation, tag helpers are used instead of helper methods.
page i
would translate into
<a asp-controller="#ViewBag.actionName" asp-action="#ViewBag.controllerName" asp-route-id = "#i">page i</a>
"asp-route" can be either a route parameter or a query parameter (if the given action has no such route parameter). so asp-route-xyz="abc" would add ?xyz=abc to the url.

Related Links

dnu restore : unable to restore all packages
#Ajax.ActionLink in ASP.NET 5 MVC6
ChildTag appears outside parentTag in TagHelper
Multiple ASP.NET 5 apps using DNX-watch command
Framework DNX451 working in a Mac or Linux
dnx : Error: Unable to load application or execute command 'ef'
Where is the taghelper for asp-area or how to create a hyperlink with an area?
Include properties passing a string parameter
ASP.NET 5: Error with Nuget package in Class library Package
Asp.Net 5 MVC 6 Startup.cs Assembly Decoupling in Beta8
How to get a session value in layout file in ASP.NET 5 MVC6
ASP.NET 5 beta8 app with virtual directories/applications
RenderPartialAsync returns System.Threading.Tasks.Task`1[System.Threading.Tasks.VoidTaskResult]
Method not found: 'Void Microsoft.AspNet.Razor.CodeGenerators.GeneratedTagHelperContext
Unable to load libuv in windows server 2012 r2?
dvnm not a recognized as an internal or external command,operable program or batch file

Categories

HOME
openlayers
keycloak
omnet++
magnific-popup
homebrew
layout
session
fme
electron
amortized-analysis
datastax-java-driver
add
virtualization
etl
correlation
jplayer
usergrid
hex-editors
circuit
iolanguage
transformation
google-static-maps
solaris-10
interop
text-rendering
visual-composer
jtextfield
kvc
mmap
vlsi
apache-commons-io
facet
phpfox
buck
opentype
nat
binary-data
yadcf
karaf
picasso
hexo
stacked
libraries
streamsets
theano.scan
hilbert-curve
leading-zero
particles.js
janrain
android-mediaprojection
midl
node-sass
eclipse-gef
prolog-setof
gabor-filter
carrot
jspdf-autotable
orthogonal
yt-project
xcb
vmware-tools
bonobo
adxstudio-portals
dstu2-fhir
google-web-starter-kit
nessus
php-internals
javax.sound.midi
separator
wso2cloud
interrupted-exception
sailfish-os
createprocessasuser
fluid-dynamics
composite
dd
gulp-less
issuu
mesa
dealloc
terminal-services
flexmojos
cdc
dexterity
jplaton
chronoforms
yui-compressor
random-seed
kyotocabinet
datawindow
wse3.0
reddot
asyncfileupload
locationlistener
oncheckedchanged
android-sdk-2.1
sortable-tables
.nettiers
dmx512
webkit.net
microsoft-virtualization
eqatec
spec#
misv

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App