i have problem mvc3
i'm trying use @html.actionlink()
generate link titles in blog project.
using constant strings in actionlink
works dandy, if use posts.title
(the title of current post model being looped), exception:
cs1973: 'system.web.mvc.htmlhelper<dynamic>' has no applicable method named 'actionlink' appears have extension method name. extension methods cannot dynamically dispatched. consider casting dynamic arguments or calling extension method without extension method syntax.
"consider casting dynamic arguments or calling extension method without extension method syntax."
posts.title doesn't have type (hence dynamic argument).
just cast via (string)posts.title.
Comments
Post a Comment