DataNavigateUrlFormatString - not navigating

5 posts, 0 answers
  1. King Wilder
    King Wilder avatar
    240 posts
    Member since:
    Oct 2007

    Posted 25 Jun 2008 Link to this post

    I'm trying to have a HyperLink column in my grid where it links to another page in my web site application, but the link is not active.  What am I doing wrong?

            <rad:GridHyperLinkColumn AllowFiltering="False"  
                DataNavigateUrlField="AppraisalID" ShowSortIcon="False" Text="View"  
                UniqueName="column"  
                DataNavigateUrlFormatString="~/Appraisals/Details.aspx?id={0}"
            </rad:GridHyperLinkColumn> 
     

  2. Princy
    Princy avatar
    17421 posts
    Member since:
    Mar 2007

    Posted 26 Jun 2008 Link to this post

    Hi,

    Try setting the NavigateUrl property of the HyperLinkColumn as shown in the code snippet below.

    ASPX:
    <rad:GridHyperLinkColumn UniqueName="Hyper" DataTextField="Grid"  NavigateUrl="DataGrid.aspx" HeaderText="Grid Details"
    </rad:GridHyperLinkColumn> 
     
    Thanks
    Princy.
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. King Wilder
    King Wilder avatar
    240 posts
    Member since:
    Oct 2007

    Posted 26 Jun 2008 Link to this post

    Princy,

    The page I want to redirect to is NOT in the same folder.  This is similar to the structure of my site.

    /root/destination_folder/default.aspx
    /root/Controls/myUserControl.ascx
    /root/source_folder_with_UserControl/default.aspx

    I have a page in the source folder with a UserControl that has the RadGrid, and when the link in the grid is clicked, I need to go to the destination folder/default.aspx page.  That's why I used the ~/Appraisals/default.aspx path.

    I have been able to link to pages inside the current folder, but not to pages outside the current folder.

    Shouldn't this work?  Please tell me how this is done.

    Thanks,

    King
  5. Dimo
    Admin
    Dimo avatar
    8333 posts

    Posted 27 Jun 2008 Link to this post

    Hello King,

    The code that you have pasted is OK. The problem should be somewhere else (Javascript errors, some client-side validation?)

    Feel free to send us a simple working project, which reproduces the problem and we will readily investigate.


    All the best,
    Dimo
    the Telerik team

    Instantly find answers to your questions at the new Telerik Support Center
  6. King Wilder
    King Wilder avatar
    240 posts
    Member since:
    Oct 2007

    Posted 27 Jun 2008 Link to this post

    My bad.  I'm really sorry for taking up bandwidth on this, but I wasn't returning the AppraisalID in the result set.  It works now.

    King
Back to Top
UI for ASP.NET Ajax is Ready for VS 2017