Click here to Skip to main content
15,912,082 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: Multiple column dropdown menus Pin
RichardGrimmer3-Jan-07 1:16
RichardGrimmer3-Jan-07 1:16 
Questionasp.net: input string not in the right format Pin
aransiola3-Jan-07 1:03
aransiola3-Jan-07 1:03 
AnswerRe: asp.net: input string not in the right format Pin
Venkatesh Mookkan3-Jan-07 1:13
Venkatesh Mookkan3-Jan-07 1:13 
GeneralRe: asp.net: input string not in the right format Pin
aransiola3-Jan-07 2:03
aransiola3-Jan-07 2:03 
GeneralRe: asp.net: input string not in the right format Pin
aransiola3-Jan-07 2:06
aransiola3-Jan-07 2:06 
GeneralRe: asp.net: input string not in the right format Pin
Venkatesh Mookkan3-Jan-07 15:46
Venkatesh Mookkan3-Jan-07 15:46 
GeneralRe: asp.net: input string not in the right format Pin
aransiola4-Jan-07 3:43
aransiola4-Jan-07 3:43 
GeneralRe: asp.net: input string not in the right format Pin
Venkatesh Mookkan4-Jan-07 15:24
Venkatesh Mookkan4-Jan-07 15:24 
aransiola wrote:
Dim intCount As Integer = 0
Dim strSQL As String = "Select ClientID,CPassword From Client Where "
strSQL &= "ClientID='" & CustCode.Trim & "'"
strSQL &= " AND CPassword='" & PinID.Trim & "'"

oConn = New OleDbConnection
oConn.ConnectionString = strConn
oConn.Open()

With oCmd
.CommandText = strSQL
.Connection = oConn
intCount = .ExecuteScalar
End With

ValidCustomer = False
If intCount > 0 Then
ValidCustomer = True
End If
oConn.Close()



Hey Aran,
ExecuteScalar returns a single scalar value. But your query seems to select ClientID and CPassword. That is not possible in ExecuteScalar. Use Count(ClientID) in the SELECT query.

Your query should be,
Dim strSQL As String = "Select COUNT(ClientID) From Client Where "
strSQL &= "ClientID='" & CustCode.Trim & "'"
strSQL &= " AND CPassword='" & PinID.Trim & "'"




Regards,
Venkatesh Mookkan.
Software Engineer, India
My: Website | Yahoo Group

AnswerRe: asp.net: input string not in the right format Pin
RichardGrimmer3-Jan-07 1:18
RichardGrimmer3-Jan-07 1:18 
AnswerRe: asp.net: input string not in the right format Pin
nagendra rao s.v.3-Jan-07 2:39
nagendra rao s.v.3-Jan-07 2:39 
GeneralRe: asp.net: input string not in the right format Pin
aransiola3-Jan-07 3:16
aransiola3-Jan-07 3:16 
QuestionMultiple Columns of Checkbox in GridView Pin
varshavmane2-Jan-07 23:33
varshavmane2-Jan-07 23:33 
AnswerRe: Multiple Columns of Checkbox in GridView [modified] Pin
rama charan3-Jan-07 0:09
rama charan3-Jan-07 0:09 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
varshavmane3-Jan-07 0:22
varshavmane3-Jan-07 0:22 
AnswerRe: Multiple Columns of Checkbox in GridView Pin
Venkatesh Mookkan3-Jan-07 0:33
Venkatesh Mookkan3-Jan-07 0:33 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
varshavmane3-Jan-07 0:58
varshavmane3-Jan-07 0:58 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
Venkatesh Mookkan3-Jan-07 1:10
Venkatesh Mookkan3-Jan-07 1:10 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
varshavmane3-Jan-07 1:14
varshavmane3-Jan-07 1:14 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
Venkatesh Mookkan3-Jan-07 1:21
Venkatesh Mookkan3-Jan-07 1:21 
GeneralRe: Multiple Columns of Checkbox in GridView Pin
varshavmane3-Jan-07 1:31
varshavmane3-Jan-07 1:31 
Questiondate functions in asp.net Pin
david boon2-Jan-07 23:29
david boon2-Jan-07 23:29 
AnswerRe: date functions in asp.net Pin
Pete O'Hanlon2-Jan-07 23:43
mvePete O'Hanlon2-Jan-07 23:43 
QuestionDesign View issues Pin
The ANZAC2-Jan-07 23:09
The ANZAC2-Jan-07 23:09 
AnswerRe: Design View issues Pin
Howard Richards3-Jan-07 0:58
Howard Richards3-Jan-07 0:58 
AnswerRe: Design View issues Pin
Chetan Ranpariya3-Jan-07 2:33
Chetan Ranpariya3-Jan-07 2:33 

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.