Click here to Skip to main content
15,885,767 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
In my project, there are five navigation links, represented using @html.ActionLinks as Partial view.Every link represents a different page. When the user is at first page all the links should be disabled

when the user is directed to second page on clicking a button, only first link becomes active and other all links remain inactive.

In every view I am calling this partial view by @html.RenderPartial("_partialViewName")

So how can I change the behavior of ActionLinks dynamically in a controller?
Posted

achor tag has property of enable and disable.you can use it
 
Share this answer
 
Comments
Member 11065455 8-Sep-14 1:19am    
i am using a partial view containing all links, which will be rendered on all five views...so each view will need different enable/disable options.

In this case I cannot add properties in partial view ..i need to do w.r.t every page
sushil7350 29-Sep-14 9:12am    
u can do it by css by finding page Url
fiddle for this[^]

Please check the above fiddle, may this help you
Thanks
:)
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900