So when it gets returned from the db, the string looks like "google#www.google.com#"?
Your going to have to run a template field in your datagrid, and run a function to return a value, split out of the parsed string. You may be able to use the "format" field. I'll work up a code example and post it.
My users have been working years with the same mdb that have a hyperlink field in one of the tables
i was asked to make a webpage where its possible for every one to see the project name and the hyperlink of that project
what they do in access form is right mouse click on the selected file and then press add a hyperlink then ok ! they love it because its easy they like to keep it that
way.
Input in MS access output webpage cos. not everyone have access to the mdb
when I open the table in MS Access I see a hyperlink field called Google only. and when u click it goes to
www.google.com
I formatted the field to a normal string “text” in access it self ..
what happened was is this :
google#www.google.com# and my user cant add a hyperlink to the database like they used to do
Well rather than change the way your users work, lets see if we can figure this out in code so it's transparent to them.
Return the field to a hyperlink field, and do a query from an asp page based on that field and see what it returns so I can see how I need to format the string to get it into a hyperlink on the asp page.
If you dont have the ability to change the field in your access table to a string / text column, then your going to have to run replace code at either bind, or display time. Turn the column in VWD or VS into a template column, and do something like this...
String
Member
15 Points
3 Posts
Hyperlink in Container item
Feb 23, 2006 08:49 AM|LINK
guys am just starting to use mdb
but I have a problem I have a
in my access table there is a filed as hyperlink example;
google#www.google.com#
in aspx am using a “Container.DataItem”
how can I let the Google show as my hyperlink and the target is www.google.com
any suggestions ? [:S]
Freakyuno
Star
12518 Points
1952 Posts
Re: Hyperlink in Container item
Feb 23, 2006 12:29 PM|LINK
My suggestion is to get rid of the hyperlink field if possible, store it just as a string / text field.
In your page, where it renders the item, turn it into a template field, and bind a hyperlink to it.
My Blog
String
Member
15 Points
3 Posts
Re: Hyperlink in Container item
Feb 23, 2006 03:02 PM|LINK
hmm , i cant
there must be a way for doing that .. plzz ppls help !
Freakyuno
Star
12518 Points
1952 Posts
Re: Hyperlink in Container item
Feb 23, 2006 06:48 PM|LINK
So when it gets returned from the db, the string looks like "google#www.google.com#"?
Your going to have to run a template field in your datagrid, and run a function to return a value, split out of the parsed string. You may be able to use the "format" field. I'll work up a code example and post it.
My Blog
String
Member
15 Points
3 Posts
Re: Hyperlink in Container item
Feb 24, 2006 07:07 AM|LINK
My users have been working years with the same mdb that have a hyperlink field in one of the tables
i was asked to make a webpage where its possible for every one to see the project name and the hyperlink of that project
what they do in access form is right mouse click on the selected file and then press add a hyperlink then ok ! they love it because its easy they like to keep it that way.
Input in MS access output webpage cos. not everyone have access to the mdb
when I open the table in MS Access I see a hyperlink field called Google only. and when u click it goes to www.google.com
I formatted the field to a normal string “text” in access it self ..
what happened was is this : google#www.google.com# and my user cant add a hyperlink to the database like they used to do
Freakyuno
Star
12518 Points
1952 Posts
Re: Hyperlink in Container item
Feb 24, 2006 12:27 PM|LINK
Well rather than change the way your users work, lets see if we can figure this out in code so it's transparent to them.
Return the field to a hyperlink field, and do a query from an asp page based on that field and see what it returns so I can see how I need to format the string to get it into a hyperlink on the asp page.
My Blog
Superfly
Member
84 Points
38 Posts
Re: Hyperlink in Container item
May 05, 2006 11:19 AM|LINK
Hi String,
Did you manage to find a solution for this?
I have a similar problem in that I've a Hyperlink field in a table in my Access database. When viewing this in my GridView, it is displayed like this:
#http://www.asp.net/#
Best Regards,
Stewart.
Freakyuno
Star
12518 Points
1952 Posts
Re: Hyperlink in Container item
May 05, 2006 01:07 PM|LINK
If you dont have the ability to change the field in your access table to a string / text column, then your going to have to run replace code at either bind, or display time. Turn the column in VWD or VS into a template column, and do something like this...
<%# replace(container.dataitem("field"), "#", "") %>
My Blog