Sharepoint Forum

 
Home » Forum » Sharepoint       Ask a questionRSS Feeds

CAML query return of Hyperlink field

  Asked By: Katharine Hubbard         Date: Jul 05, 2009      Category: Sharepoint      Views: 1063
 

I have a CAML Query that returns a Hyperlink column which I then bind
to a GridView control.

My Gridview column is defined:

<asp:HyperLinkField
DataTextField="Organization_x0020_Name"
DataNavigateUrlFields="URL" />
.....
<asp:HyperLinkField

The problem is that the returned hyperlink contains the full data of
the Web Address and the Description:

"www.thesite.com, The Site Name"

which makes the URL invalid

How do I parse this out?

Tagged:            

 

2 Answers Found

 
Answer #1       Answered By: Maggie Benson          Answered On: Jul 05, 2009       

What if you add an OnDataBind sub that takes this field  and parses out the
piece you need?

 
Answer #2       Answered By: Lane Trujillo          Answered On: Jul 05, 2009       

I did end up using the RowDataBound.

 
Didn't find what you were looking for? Find more on CAML query return of Hyperlink field Or get search suggestion and latest updates.


Your Answer
  • Answer should be atleast 30 Characters.
  • Please put code inside [Code] your code [/Code].