How to compare inserted text in (textbox1.text) with
existing database value in (Sqldatasource1) in visual
studio 2005 ?
Answer Posted / amol
Dim strValue As String
strValue = txtValue1.Text
Dim rstData As ADODB.Recordset
rstData = New ADODB.Recordset
rstData.Fields.Append("A",
ADODB.DataTypeEnum.adInteger, 0,
ADODB.FieldAttributeEnum.adFldKeyColumn)
rstData.Fields.Append("B",
ADODB.DataTypeEnum.adVarChar, 10,
ADODB.FieldAttributeEnum.adFldIsNullable)
'rstData.Fields.Append("C",
ADODB.DataTypeEnum.adVarChar, 0)
rstData.Open()
rstData.AddNew()
rstData.Fields("A").Value = "1"
rstData.Fields("B").Value = "Amol"
rstData.Update()
rstData.MoveFirst()
If UCase(Trim(rstData.Fields("B").Value)) =
UCase(Trim(strValue)) Then
MsgBox("True")
Else
MsgBox("False")
End If
Is This Answer Correct ? | 3 Yes | 2 No |
Post New Answer View All Answers
Can you create a tabletype of recordset in Jet connected ODBC dbengine.
How do I get the number of free bytes on a disk?
Specify technical & functional architecture of your last 2 projects.
How to down load image properties.
____ property of menu cannot be set at run time.
How many ways you can access file using VB?
How can I access a record by record number?
What do you know about user forms.
how to make unlimited id(1rimjim,2rimjim,3rimjim....etc) login grp chat pogram for jabber?
How many File System Controls are there ? Explain.
Explain the usage of Web Browser Control?
What is ActiveX Control?
What are the properties of datacontrol?
what are the Default cursor Type and LockEdit type in DAO?
I have several megabytes of memory. Why do I get an "out of memory" error?