I'm getting an error using NavigateURL ='<%# Eval("Url") %>', it works when using NavigateURL="intro.aspx"

I'm getting an error using NavigateURL ='<%# Eval("Url") %>', it works when I use NavigateURL="intro.aspx"

Server Error in '/orthoassist' Application.

The resource cannot be found.

Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable.  Please review the following URL and make sure that it is spelled correctly.

Requested URL: /orthoassist/intro.aspx

<asp:HyperLink runat="server" ID="hl1" Text='<%# Eval("title") %>' NavigateUrl='<%# Eval("Url") %>'></asp:HyperLink>      - GET ERROR

<asp:HyperLink runat="server" ID="hl1" Text='<%# Eval("title") %>' NavigateUrl="intro.aspx"></asp:HyperLink>       - works correctly

0
jayd_21
8/13/2008 3:38:06 PM
asp.net.presentation-controls 72751 articles. 3 followers. Follow

8 Replies
1111 Views

Similar Articles

[PageSpeed] 52

This is what is coming from Eval(): /orthoassist/intro.aspx

If that doesn't work in the second line than it looks like you need to clean up the databound data.


If everything happens for a reason what is the reason for this error?
0
mpaterson
8/13/2008 3:50:30 PM

If I enter a file name that does not exist in NavigateURL="nofile.aspx" I get the exact same error message as with NavigateURL='<%# Eval("Url") %>' when the file does exist.

0
jayd_21
8/13/2008 3:56:36 PM

What happens if you enter /orthoassist/intro.aspx?

Do you get the same error?


If everything happens for a reason what is the reason for this error?
0
mpaterson
8/13/2008 4:08:50 PM

Hello Jayd,

I checked your code, I think you are not going to get error when you run the application, and you will get error when you click the URL right? and I think you are updating this files into the Folder called 'orthoassist' right?

Now your trying access from 'orthoassist' Folder to /orthoassist/intro.aspx.. so your complete URL is going to be "orthoassist/orthoassist/intro.aspx" ....

So, you don't have any files like that in your Folder ('orthoassist'). So, you will get error. but when you access from Folder 'orthoassist' to intro.aspx, you have the file "intro.aspx" in your folder. So, it is working correctly.

So, make a change in your database 'Url'

I hope this will help you,


-Sugan

Remember to click “Mark as Answer” on the post If you get answer from this post(s) !
0
sugan
8/13/2008 4:24:07 PM

That causes this error-

Requested URL: /orthoassist/orthoassist/intro.aspx

0
jayd_21
8/13/2008 4:30:04 PM

Then try something like this:

String.Format("~/{0}", Eval("Url"))

That may not be quite right but it should be something like that.

As you are already in orthoassist directory you need to either strip out "orthoassist" or go to the root of the application which is "~/"


If everything happens for a reason what is the reason for this error?
0
mpaterson
8/13/2008 4:38:56 PM

That's it! Thanks Jay

0
jayd_21
8/13/2008 4:55:01 PM
Reply:

Similar Artilces:

Why Response.Write("<script>window.open("newWind.aspx','report','');</script>") not working?
I need to open a new web browser of url=newWind.aspx and tried the code below; Response.Write("<script>window.open('newWind.aspx','report','');</script>")However nothing happens, what can I do to make it work? Try RegisterClientScriptBlock("OpenWin","<script language=javascript>window.open('newWind.aspx','report','');</script>")I think that is the name of it...Also look at RegisterStartupScriptBlock (I think)MajorCats Thanks. But, it was same difference. Is there anything that blocks the new browser from showing up in the setting of IE or system?   &nbs...

Cannot get Label inside Brands.aspx page to display using Text='<%# Eval("BrandName") %>'>
I have a Brand Class that contains the following.public class Brand : BaseStore{ private int _brandID;private int _categoryID;private string _brandName = "";private List<Category> _category = null;public Brand(){}public Brand(int brandID){BrandID = brandID;}  public Brand(int brandID, string brandName) {BrandID = brandID;BrandName = brandName;} public int BrandID{get { return _brandID; }set { _brandID = value; }}public string BrandName{get { return _brandName; }set { _brandName = value; }} public int CategoryID{get { return _categoryID; }set { _categoryID = value...

When I use Response.Write("<script type='text/javascript' language='javascript'>window.close();</script>"); it produces error
Hi, When I use command below in my web application  it produces error. How can I solve this problem? Thanks.Response.Write("<script type='text/javascript' language='javascript'>window.close();</script>");   Error:  Microsoft JScript runtime error: Sys.WebForms.PageRequestManagerParserErrorException: The message received from the server could not be parsed. Common causes for this error are when the response is modified by calls to Response.Write(), response filters, HttpModules, or server trace is enabled.Details: Error parsing near &#...

RFC: interactions between "use bytes", "use locale", and "use feature 'unicode_strings'
I am waiting for blead to reopen before I submit a patch for extending feature unicode_strings to matching \s, and \w. In documenting it, it occurred to me that the existing implementation is wrong, along with the existing interaction between use bytes and use locale. To refresh your memory, "use feature 'unicode_strings'" is supposed to mean that even non-utf8 data is to be considered to have Unicode semantics. In practice, this only affects the characters from 128-255. It is new in 5.12, and is implemented there only on functions that change case, such a...

how can i use coulumname instead of "/detayliurun.aspx?urunnumarasi={0}" in <a href='<%# DataBinder.Eval(Container.DataItem,"urunnumarasi",Request.ApplicationPath+"/detayliurun.aspx?urunnumarasi={0}"
hello friends how can i use coulumname instead of "/detayliurun.aspx?urunnumarasi={0}" in below code.. because i want to send different page.aspx:) i insterted different page.aspx in coulumanem before..  <a href='<%# DataBinder.Eval(Container.DataItem,"urunnumarasi",Request.ApplicationPath+"/detayliurun.aspx?urunnumarasi={0}") %>'> cheersMark as me if my question or my answer can be helpful for you :) Hi friend, I think you can assign "detayliurun.aspx?urunnumarasi=1" to the coulumname(table field) to ...

help with: BackColor='<%#iif((eval("timecode") = 1),"#993366","#993366") %>'
I have a panel and I wish to toggle its background color based on a databound value.  the expression returns all OK. Butit reutrns a string and it creates a casting error it returns "#993366" BackColor='<%#iif((eval("timecode") = 1),"#993366","#993366") %>' I know it is the declaration... something to do with the # in the <%# or ???   Hi That's the problem when you type it in there directly. It's a pain in the ass to debug/manage.Maybe you can take a look at this example. You add a function in your code-be...

Can't get away from: "Could not open in Design View. Quote values differently inside a '<% ... "value" ... %>' block."
I keep getting this error message when I try to switch to design view. This is the code that is causing it. OnClick="javascript:void(0);ToggleRowDisplay(this,'row<%# DataBinder.Eval(Container.DataItem, "Equipment_ID") %>');" When I take out this section I can go into design view without a problem. Any ideas?? is the word row has to be there?mess with the best...die like the rest...

Template field and href?? <a href='<%# DataBinder.Eval(Container.DataItem,"urunnumarasi",Request.ApplicationPath+"/detayliurun.aspx?urunnumarasi={0}") %>'> ....how can i send categor, category1 with u
hi friends my code is below.. how can i send categor, category1 with urunnumarasi with below code?  catagory and category1 are other coulumname <a href='<%# DataBinder.Eval(Container.DataItem,"urunnumarasi",Request.ApplicationPath+"/detayliurun.aspx?urunnumarasi={0}") %>'> cheersMark as me if my question or my answer can be helpful for you :) Hi oguzkaygun, Try this: <a href='<%# Request.ApplicationPath+"/detayliurun.aspx?" + DataBinder.Eval(Container.DataItem, "category") + "=" + DataBinder.Ev...

I am trying to dynamically change the binding code of controls in a listview with codebehind. How do I present a double quote as in the following '<%# Eval("ArtificialID") %>'
I am tyring to set the text property as in the following. label1.text = "'<%# Eval("ArtificialID") %>'" I have a problem were double quotes exist such as "ArtificalID".  It thinks that I am done with the string when I am not.  I have forgotten how to do this. It doesnt work to use a singel quote instead.  Any help woudl be very much appreicated. Thanks  I am not quite sure what you are trying to do but you can try this "'<%# Eval(\"ArtificialID\") %>'";   take note of t...

RFC: Make "use 5.14" select "use re '/a' " ?
I have pushed to blead (with Jesse's permission) the last commits (besides doc and any bug fixes) that enable the /a regular expression modifier. Presuming it works ok, should this become the default method of operation, signified by a "use 5.014" ? On 1/17/11 11:02 AM, Karl Williamson wrote: > Presuming it works ok, should this become the default method of > operation, signified by a "use 5.014" ? So when I upgrade my code, I have to put "no re '/a'" in every file? Why, oh why? On Mon, 17 Jan 2011, Elliot Shank wrote: > ...

[ID 20020307.006] [BUG][use encoding] use encoding 'greek'; print "not" unless pack("U*", 0x3af) eq pack("C*", 0xdf) prints "not"!
This is a bug report for perl from "Anton Tagunov" <tagunov@motor.ru>, generated with the help of perlbug 1.33 running under perl v5.7.3. ----------------------------------------------------------------- Hello, developers! Hello, Jarkko! Please consider the following test being added: --- lib/encoding.t.orig Fri Feb 8 07:12:05 2002 +++ lib/encoding.t Thu Mar 7 19:38:39 2002 @@ -1,4 +1,4 @@ -print "1..19\n"; +print "1..20\n"; BEGIN { if (ord("A") == 193) { @@ -89,3 +89,7 @@ print "not " unless "\x...

<img src='<%=PathPrefix + "Comm/Images/sp.gif" %>' height="8" width="20">- What is PathPrefix
<img src='<%=PathPrefix + "Comm/Images/sp.gif" %>' height="8" width="20"> What is PathPrefix ?-----------------------------------------------Please click Mark as Answer if this helped. PathPrefix is a public shared variable in the code behind file of this pageDo mark as answer if it helpsBest RegardsAli Sufyan ButtSoftware EngineerElectronic Solutions Pvt. Limited...

what's the different from "<page src="">" and "<page codeBehind="">"
what's the different from "<page src="">" and "<page codeBehind="">" Thank YOU how to make session' life longer? Thank You This very question was asked only 5 days ago. Searching the forums would have yielded the answer you require. However, see this thread. Steven BeyRecursion: see Recursion You can set a new value for the Session Timeout in your web.config file. Or, you can do it in a page through this property: Session.Timeout Note that if you choose the second method, the timeout will only be modified on this page,...

Using cdate function but got error "Conversion from string " " to type 'Date' is not valid."
I want to control user's input in Due date text box like below to make sure that user does not input date earlier than today: If Me.txtDueDate.Text <> "" Then      If (DateDiff("d", CDate(Me.txtDueDate.Text), (Date.Today)) > 0) Then     // Message: due day should not be earlier than today      exit sub End If  The problem is: if user did not input anything in txtDueDate box, I still got error: Conversion from string "  " to type 'Date' is not valid How to fix it? Help!!!   I'd use a RequireFie...

Web resources about - I'm getting an error using NavigateURL ='<%# Eval("Url") %>', it works when using NavigateURL="intro.aspx" - asp.net.presentation-controls

Resources last updated: 12/15/2015 11:25:30 AM