Hello
I thought if I linked a datagrid column to a field containing something like
this ... <a href="http://www.google.com"
target="_blank">http://www.google.com</a> ... that it might appear
hyperlinkable in the grid. But alas, no.
What I currently have is a non-template bound column connecting a data field
which may contain, amongst other text, a URL (or maybe an Email address). Is
there any way to have just the URL part hyperlinkable so user can click and
redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is that
I only want the URL part hyperlinkable; not the complete text (which could
be several sentences).
Any ideas most welcome.
Thanks
Graeme 6 1521
"Graeme" <ma***@NOSPAMwave.co.nz> wrote in message
news:uX**************@TK2MSFTNGP09.phx.gbl... Hello
I thought if I linked a datagrid column to a field containing something
like this ... <a href="http://www.google.com" target="_blank">http://www.google.com</a> ... that it might appear hyperlinkable in the grid. But alas, no.
probably this is escaped to <a href= ... hope you get the idea, thats why
its not hyperlink in the grid What I currently have is a non-template bound column connecting a data
field which may contain, amongst other text, a URL (or maybe an Email address).
Is there any way to have just the URL part hyperlinkable so user can click
and redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is
that I only want the URL part hyperlinkable; not the complete text (which could be several sentences).
simplest way to accomplish this would be to use TemplateColumn
HTH
Konrad
Any ideas most welcome.
Thanks Graeme
Thanks for quick response, Konrad! Well, I did try template but still stuck
.... how to make it grab the tags and make it hyperlinkable? Can you help
more? Thanks
"Konrad Rotuski" <konrad@_SPAM_KILLER_eracent.com> wrote in message
news:%2******************@TK2MSFTNGP09.phx.gbl... "Graeme" <ma***@NOSPAMwave.co.nz> wrote in message news:uX**************@TK2MSFTNGP09.phx.gbl... Hello
I thought if I linked a datagrid column to a field containing something like this ... <a href="http://www.google.com" target="_blank">http://www.google.com</a> ... that it might appear hyperlinkable in the grid. But alas, no.
probably this is escaped to <a href= ... hope you get the idea, thats
why its not hyperlink in the grid
What I currently have is a non-template bound column connecting a data field which may contain, amongst other text, a URL (or maybe an Email
address). Is there any way to have just the URL part hyperlinkable so user can click and redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is that I only want the URL part hyperlinkable; not the complete text (which
could be several sentences).
simplest way to accomplish this would be to use TemplateColumn
HTH
Konrad
Any ideas most welcome.
Thanks Graeme
<asp:TemplateColumn>
<ItemTemplate>
some text, not hyperlinkable <a
href='http://www.google.com'>hyperlink text</a> some more nothyperlinkable
text <%#DataBinder.Eval(Container.DataItem, "SomeColumn")%>
<ItemTemplate>
</asp:TemplateColumn>
what do you mean by 'grab the tags' .. i dont get it .. ?
Konrad
"Graeme" <ma***@NOSPAMwave.co.nz> wrote in message
news:Of**************@TK2MSFTNGP14.phx.gbl... Thanks for quick response, Konrad! Well, I did try template but still
stuck ... how to make it grab the tags and make it hyperlinkable? Can you help more? Thanks "Konrad Rotuski" <konrad@_SPAM_KILLER_eracent.com> wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... "Graeme" <ma***@NOSPAMwave.co.nz> wrote in message news:uX**************@TK2MSFTNGP09.phx.gbl... Hello
I thought if I linked a datagrid column to a field containing
something like this ... <a href="http://www.google.com" target="_blank">http://www.google.com</a> ... that it might appear hyperlinkable in the grid. But alas, no.
probably this is escaped to <a href= ... hope you get the idea, thats why its not hyperlink in the grid
What I currently have is a non-template bound column connecting a data
field which may contain, amongst other text, a URL (or maybe an Email address). Is there any way to have just the URL part hyperlinkable so user can
click and redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is that I only want the URL part hyperlinkable; not the complete text (which could be several sentences).
simplest way to accomplish this would be to use TemplateColumn
HTH
Konrad
Any ideas most welcome.
Thanks Graeme
Just my uneducated terminology. I'll have a play with this tomorrow. Thanks!
"Konrad Rotuski" <konrad@_SPAM_KILLER_eracent.com> wrote in message
news:O%****************@TK2MSFTNGP15.phx.gbl... <asp:TemplateColumn> <ItemTemplate> some text, not hyperlinkable <a href='http://www.google.com'>hyperlink text</a> some more nothyperlinkable text <%#DataBinder.Eval(Container.DataItem, "SomeColumn")%> <ItemTemplate> </asp:TemplateColumn>
what do you mean by 'grab the tags' .. i dont get it .. ?
Konrad
"Graeme" <ma***@NOSPAMwave.co.nz> wrote in message news:Of**************@TK2MSFTNGP14.phx.gbl... Thanks for quick response, Konrad! Well, I did try template but still stuck ... how to make it grab the tags and make it hyperlinkable? Can you help more? Thanks "Konrad Rotuski" <konrad@_SPAM_KILLER_eracent.com> wrote in message news:%2******************@TK2MSFTNGP09.phx.gbl... "Graeme" <ma***@NOSPAMwave.co.nz> wrote in message news:uX**************@TK2MSFTNGP09.phx.gbl... > Hello > > I thought if I linked a datagrid column to a field containing something like > this ... <a href="http://www.google.com" > target="_blank">http://www.google.com</a> ... that it might appear > hyperlinkable in the grid. But alas, no.
probably this is escaped to <a href= ... hope you get the idea,
thats why its not hyperlink in the grid
> > What I currently have is a non-template bound column connecting a
data field > which may contain, amongst other text, a URL (or maybe an Email address). Is > there any way to have just the URL part hyperlinkable so user can
click and > redirect? > > Or do I HAVE to use a Hyperlink column for this? Problem I see here
is that > I only want the URL part hyperlinkable; not the complete text (which
could > be several sentences). >
simplest way to accomplish this would be to use TemplateColumn
HTH
Konrad
> Any ideas most welcome. > > Thanks > Graeme > > > > > >
You can also use the SPAN tag:
<span onclick="...">some text</span>
But this only works with web browsers that support HTML 4.
"Graeme" <ma***@NOSPAMwave.co.nz> wrote in message
news:uX**************@TK2MSFTNGP09.phx.gbl... Hello
I thought if I linked a datagrid column to a field containing something
like this ... <a href="http://www.google.com" target="_blank">http://www.google.com</a> ... that it might appear hyperlinkable in the grid. But alas, no.
What I currently have is a non-template bound column connecting a data
field which may contain, amongst other text, a URL (or maybe an Email address).
Is there any way to have just the URL part hyperlinkable so user can click
and redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is
that I only want the URL part hyperlinkable; not the complete text (which could be several sentences).
Any ideas most welcome.
Thanks Graeme
Sorry ... worked all the time! I wasn't storing it in correct format in db.
Graeme (AKA Oaf)
"Graeme" <ma***@NOSPAMwave.co.nz> wrote in message
news:uX**************@TK2MSFTNGP09.phx.gbl... Hello
I thought if I linked a datagrid column to a field containing something
like this ... <a href="http://www.google.com" target="_blank">http://www.google.com</a> ... that it might appear hyperlinkable in the grid. But alas, no.
What I currently have is a non-template bound column connecting a data
field which may contain, amongst other text, a URL (or maybe an Email address).
Is there any way to have just the URL part hyperlinkable so user can click
and redirect?
Or do I HAVE to use a Hyperlink column for this? Problem I see here is
that I only want the URL part hyperlinkable; not the complete text (which could be several sentences).
Any ideas most welcome.
Thanks Graeme This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Jeremy |
last post by:
In a datagrid which contains a hyperlink column, can I programatically
change a specific row's hyperlink ?
The hyperlink build in by the designer applies to all rows - I'd like to
change each...
|
by: kh |
last post by:
Hi. If I set DataGrid.AllowSorting=True my column headers are automatically rendered as hyperlinks. How can I explicitly tell the DataGrid what CssClass to use for these hyperlinks?
Note that this...
|
by: Mark Rae |
last post by:
I've inherited an ASP.NET app and have been asked to fix the following
problem with a page which is used to display and/or delete records from a
database. When the page loads, it displays a list of...
|
by: BobRoyAce |
last post by:
I am brand new to ASP.NET and am now required to take over maintenance of a
..NET/C# web application. On one of the pages I'm working on there is a
DataGrid which has multiple columns. One of the...
|
by: Ray |
last post by:
I am trying to add a "Next >" and "<Prev" button to the pager of my datagrid.
I have been able to add the hyperlinks to the pager. I am now trying to
determine the correct postback script to...
| |
by: ypul |
last post by:
Hi ,
Getting to the point directly,
my query output doesnt have fixed columns , so I choosed "autogenerate
columns" datagrid.
I assign this dataset to my datagrid, but now I want my data should...
|
by: Trint Smith |
last post by:
Can a datagrid have thumbnails and hyperlinks?
Does anyone have a good sample of that?
And is a datagrid better than results pages on searches of a sql server
database?
Thanks,
Trint
.Net...
|
by: Jason L James |
last post by:
Hi all,
I have datagrid with a column that is to contain hyperlinks
to other documents. The is in the columns from a bound
data source but I would like to format them as hyperlinks
so that I...
|
by: Jonathan |
last post by:
In the sample code below, how do I make the various text items in a datagrid
column have a clickable hyperlinks?
e.g. Ford Mustang
should be a link to www.mysite.com/mustang.htm
</head>
|
by: Mark B |
last post by:
I have a Datagrid working fine, outputting:
Group
Most Popular Product Code
--------
-------------------------------
Earth.New Zealand
32
Earth.New Zealand
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
| |
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...
| |