VB - Server Error in '/' Application.

I'm having trouble adding a hyperlink tag to my document. Currently I'm getting a server error which is below. My code is attached, could someone please try to help me figure out what I'm doing wrong. Thanks.

Parser Error

Description: An error occurred during the parsing of a resource required to service this request. Please review the following specific parse error details and modify your source file appropriately.

Parser Error Message: The server tag is not well formed.

Source Error:

Line 59: <asp:TemplateField HeaderText="Document" >
Line 60:      <ItemTemplate>
Line 61: <asp:HyperLink  
Line 62: text="<%# Eval("doc_loc") %>"  
Line 63: navigateurl="<%# Eval("doc_loc") %>" target="_blank" runat="server" />

Source File: /admin_eenvelope_delete.aspx    Line: 61
Who is Participating?
JosephEricDavisConnect With a Mentor Commented:
When you are using server side includes like that you need to use single tick marks instead of full double quotes to surround the attribute values...

For instance,

text='<%# Eval("doc_loc") %>'  

instead of

text="<%# Eval("doc_loc") %>"  
Additionally there is generally a better way to do things than to use those ASP classic style server side include tags.  If this is a gridview control that you are utilizing you can manipulate the values of those controls from the code behind in the OnRowDataBound event.

For an example, take a look at this question...
elliottbenzleAuthor Commented:
Thanks for the help.
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.