Click here to Skip to main content
15,913,773 members
Home / Discussions / Web Development
   

Web Development

 
AnswerRe: ASP.NET Write permissions Pin
Guffa6-May-07 3:40
Guffa6-May-07 3:40 
AnswerRe: ASP.NET Write permissions Pin
Fred_Smith6-May-07 4:31
Fred_Smith6-May-07 4:31 
QuestionDeployment Pin
sangramkp4-May-07 21:07
sangramkp4-May-07 21:07 
AnswerRe: Deployment Pin
Hesham Amin4-May-07 22:04
Hesham Amin4-May-07 22:04 
Questionregarding server error Pin
PhanindraTSK4-May-07 19:55
PhanindraTSK4-May-07 19:55 
AnswerRe: regarding server error Pin
steffw8-May-07 5:00
steffw8-May-07 5:00 
GeneralRe: regarding server error Pin
PhanindraTSK8-May-07 19:20
PhanindraTSK8-May-07 19:20 
QuestionHOW TO GET THE VALUE? Pin
hifiger20044-May-07 8:41
hifiger20044-May-07 8:41 
Hi Guys,

I have an ASP.Net code below. How can I get the value of "OrderID" field?

Dim strConnString As String = ConfigurationManager.ConnectionStrings("MyConnectionString").ConnectionString
Dim sqlConn As New Data.SqlClient.SqlConnection(strConnString)
Dim cmd As New Data.SqlClient.SqlCommand
Dim da As Data.SqlClient.SqlDataAdapter
Dim ds As New Data.DataSet

cmd.CommandText = "Select Top 1 OrderID, OrderTracking From tblOrders " _
& "Where OrderTracking = '" & Trim(CType(sender, DropDownList).SelectedItem.Text) & "' "
cmd.CommandType = Data.CommandType.Text
cmd.Connection = sqlConn
da = New Data.SqlClient.SqlDataAdapter(cmd)
da.Fill(ds)

If ds.Tables.Item(0).Rows.Count > 0 Then
txtOrderID.Text = ds.Tables.Item(0).Columns(0).ToString
End If

da.Dispose()
ds.Dispose()

sqlConn.Close()

RefreshGridView()

hifiger2004

AnswerRe: HOW TO GET THE VALUE? Pin
Tarakeshwar Reddy4-May-07 10:02
professionalTarakeshwar Reddy4-May-07 10:02 
GeneralRe: HOW TO GET THE VALUE? Pin
hifiger20047-May-07 1:50
hifiger20047-May-07 1:50 
QuestionTime format Pin
No-e4-May-07 4:46
No-e4-May-07 4:46 
AnswerRe: Time format Pin
Arun.Immanuel4-May-07 6:04
Arun.Immanuel4-May-07 6:04 
GeneralRe: Time format Pin
No-e4-May-07 6:43
No-e4-May-07 6:43 
AnswerRe: Time format Pin
Guffa4-May-07 9:40
Guffa4-May-07 9:40 
AnswerRe: Time format Pin
Guffa4-May-07 6:10
Guffa4-May-07 6:10 
Questionvalidate CheckListBox using JavaScript Pin
Vinay Dornala4-May-07 3:42
Vinay Dornala4-May-07 3:42 
QuestionActiveX read file path Pin
militiaware4-May-07 2:36
militiaware4-May-07 2:36 
AnswerRe: ActiveX read file path Pin
forest2100015-Mar-11 13:57
forest2100015-Mar-11 13:57 
GeneralRe: ActiveX read file path Pin
militiaware15-Mar-11 21:34
militiaware15-Mar-11 21:34 
QuestionURL using Digest HTTP Authentication ? Pin
fx92003-May-07 22:35
fx92003-May-07 22:35 
QuestionDevelop web application with Live communication server Pin
Hardik Patel (GTL)3-May-07 5:10
Hardik Patel (GTL)3-May-07 5:10 
QuestionFavorite Icon Pin
Exelioindia3-May-07 3:32
Exelioindia3-May-07 3:32 
AnswerRe: Favorite Icon Pin
kubben3-May-07 5:08
kubben3-May-07 5:08 
QuestionIIS Problem Pin
paranth3-May-07 2:20
paranth3-May-07 2:20 
AnswerRe: IIS Problem Pin
Hesham Amin4-May-07 22:06
Hesham Amin4-May-07 22:06 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.