I am moving an existing asp site to C# .net site. I have decided to move forward with a Web application. I have my home page display a list of all our servers. I next want to have the server_name column be a hyperlink for complete informaiton regarding
that server. In asp I would just do a query.string and pull a list of all data out of a table where server_name like the query.string. Is there a "Best Practice" method I should follow or what would be the right way moving forward.
I'm sorry if this question is vague but I guess I don't know how I'm suppose to move forward.
Thank you for the information. The blog gave me some ideas, however I initially started my home page with a Gridview to show all available servers and from there I wanted to convert the first column to a hyperlink. Do I need to scrap the gridview to incorporate
a hyperlink? I'm searching the web for a method to begin our web application.
snteran
Member
45 Points
43 Posts
True Newbie converting Classic ASP to .Net site. - Hyperlink for main page.
Feb 11, 2012 10:13 PM|LINK
I am moving an existing asp site to C# .net site. I have decided to move forward with a Web application. I have my home page display a list of all our servers. I next want to have the server_name column be a hyperlink for complete informaiton regarding that server. In asp I would just do a query.string and pull a list of all data out of a table where server_name like the query.string. Is there a "Best Practice" method I should follow or what would be the right way moving forward.
I'm sorry if this question is vague but I guess I don't know how I'm suppose to move forward.
fred_b
Member
362 Points
81 Posts
Re: True Newbie converting Classic ASP to .Net site. - Hyperlink for main page.
Feb 12, 2012 01:09 AM|LINK
try this:
ramiramilu
All-Star
95493 Points
14106 Posts
Re: True Newbie converting Classic ASP to .Net site. - Hyperlink for main page.
Feb 12, 2012 08:09 AM|LINK
Query String would work in ASP.NEt too...other ways fo trasnfering data from one page to other page - http://www.intstrings.com/ramivemula/articles/data-transfer-between-two-asp-net-pages/ That link got good explanation on when to use each technique...
Thanks,
JumpStart
snteran
Member
45 Points
43 Posts
Re: True Newbie converting Classic ASP to .Net site. - Hyperlink for main page.
Feb 12, 2012 04:47 PM|LINK
Thank you for the information. The blog gave me some ideas, however I initially started my home page with a Gridview to show all available servers and from there I wanted to convert the first column to a hyperlink. Do I need to scrap the gridview to incorporate a hyperlink? I'm searching the web for a method to begin our web application.
Thanks
snteran
Member
45 Points
43 Posts
Re: True Newbie converting Classic ASP to .Net site. - Hyperlink for main page.
Feb 12, 2012 04:59 PM|LINK
OK, I was able to find the answer here on the forum.
In the gridview:
original:
<asp:BoundField DataField="SERVER_NAME" HeaderText="SERVER_NAME"
SortExpression="SERVER_NAME" />
Removed the first column to the following:
<asp:HyperLinkField DataNavigateUrlFields="SERVER_NAME" DataNavigateUrlFormatString="info.aspx?ID={0}"
DataTextField="SERVER_NAME" HeaderText="Server Name" SortExpression="SERVER_NAME" />
Now I just need to create my list for all the information in the DB concerning that server.
Thousand mile journey. - One step at a time.