databinding to a text box
am 22.01.2008 20:09:53 von JJ297How do I bring text back from the database to populate two text boxes.
I have a details view on the page plus two text boxes I want shipdate
text box and due date text box to poplutaed with info from the
database.
Do I bring back all of the info in one stored procedure (even the text
box info), such as...
CREATE procedure GetRequestInfo
@Requestorid int
AS
select distinct requestors.Requestorid, titles.title,
requestors.requestorEmail,Requestors.requestdate, fname, lname,
phonenum,
StreetAddress1, City, State, Zip,
libraryrequest.shipdate,libraryrequest.duedate
Cast(DATEPART(m, requestors.requestDate) as Varchar(5)) + '/' +
Cast(DATEPART(d, requestors.requestDate) as Varchar(5)) + '/' +
Cast(DATEPART(yy, requestors.RequestDate) as Varchar(5))
from Requestors
join Titles on titles.Titleid = requestors.Titleid
join libraryRequest on LibraryRequest.requestorid =
Requestors.requestorid
where Requestors.requestorid = @requestorid
Do I need to put something in the page load to populate the text boxes?