I have a field to my db which is external link and one that is a file. I need to display these fields to my view. I have this code where I call my data.
@Html.DisplayFor(model => model.announcement_Link)
and for the file
@Html.DisplayFor(model => model.announcement_Uploaded_File)
It brings the url and the file name . How can I make the 1st to be a link and the second to be linked to the file and to be downloaded? thank you
In Database :
1. For A Link:
eg
SQL
:2. For A Downloadable Link: (Note: saving uploaded file link with filename in column like:)
In asp mvc view
1. For A Link:
2. For A Downloadable Link:
hope this helps.