473,396 Members | 1,773 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Re-use data from sqldatasource control?

On the page, I have a formview which shows details of a job, including its
title and location. The data is fetched by a sqldatasource. Now I want to
take the job title and location and create a page title out of it as well.
Something like:

(pseudo-code)
protected void Page_Load(object sender, EventArgs e)
{ Page.Title = <jobtitle+ " " in + " " + <location>;}

I kind of understand that the data is available to the formview because the
sqldatasource is bound to it, but how do I access the data outside of the
formview without running the select statement again?

Thanks

Mike
Dec 11 '06 #1
1 1092
No worries. I have the answer now.
"Mike" <xx*@xxx.xxxwrote in message
news:Oc**************@TK2MSFTNGP04.phx.gbl...
On the page, I have a formview which shows details of a job, including its
title and location. The data is fetched by a sqldatasource. Now I want
to take the job title and location and create a page title out of it as
well. Something like:

(pseudo-code)
protected void Page_Load(object sender, EventArgs e)
{ Page.Title = <jobtitle+ " " in + " " + <location>;}

I kind of understand that the data is available to the formview because
the sqldatasource is bound to it, but how do I access the data outside of
the formview without running the select statement again?

Thanks

Mike

Dec 12 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Craig Bailey | last post by:
Anyone recommend a good script editor for Mac OS X? Just finished a 4-day PHP class in front of a Windows machine, and liked the editor we used. Don't recall the name, but it gave line numbers as...
11
by: James | last post by:
My form and results are on one page. If I use : if ($Company) { $query = "Select Company, Contact From tblworking Where ID = $Company Order By Company ASC"; }
10
by: James | last post by:
What is the best method for creating a Web Page that uses both PHP and HTML ? <HTML> BLA BLA BLA BLA BLA
6
by: Chris Krasnichuk | last post by:
Hello every one, Does anyone know how to make php work on your computer? please reply I need help Chris
2
by: Frans Schmidt | last post by:
I want to make a new database with several tables, so I did the following: <?php CREATE DATABASE bedrijf; CREATE TABLE werknemers (voornaam varchar(15), achternaam varchar(20), leeftijd...
2
by: sky2070 | last post by:
Parse error: parse error, unexpected T_OBJECT_OPERATOR, expecting ')' in c:\inetpub\wwwroot\session.php on line 19 can anyone tell me what is wrong with this code??? <? // Define the Session...
3
by: Dell Sala | last post by:
I have recently enabled the PHP 4.2.1 that comes pre-installed on OS X. After making all the prescribed changes to the httpd.conf file php seems to work fine. I would like to make some changes...
20
by: bb | last post by:
I'm not a Perl programmer nor a Linux adherent. What are the advantages of LAMP vs.the Java model for building data-driven websites? I do a fair amount of development using Tomcat/JSP/Servlets...
1
by: Randell D. | last post by:
Folks, I use Apache/PHP with Webazlier to view the log files. I get a number of user agents (web browsers?) that visit the website - For example: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT...
5
by: Scott D | last post by:
I am trying to check and see if a field is posted or not, if not posted then assign $location which is a session variable to $location_other. If it is posted then just assign it to...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
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,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.