PC Review


Reply
Thread Tools Rate Thread

DataSet refresh question

 
 
Agnes
Guest
Posts: n/a
 
      3rd Aug 2005
I will use binding manager to add new or remove record and save it
sucesfully,
I test my programe, I addnew , input the new one, save it. Then search it at
once, I found that I cannot search my record.
Do I need to refill the dataset before search ???
If I refill the dataset after "SAVE", my doubt "[ the record will be showed
the 1st one or the last one, how can I point to that 'fresh records'
--my save button'
bmBase.EndCurrentEdit()
If dsBase.HasChanges() Then
daBase.Update(dsBase, "chartofaccount")
dsBase.AcceptChanges()
ENDIF
--- mySearch Button
Dim dvBase As New DataView(dsBase.Tables("ChartOfAccount"))
dvBase.Sort = "acctcode"
Me.pPosition = dvBase.Find(strSearchKey)

If Me.pPosition < 0 Then
MessageBox.Show("Record Is Not Found !", "Error Message",
MessageBoxButtons.OK, MessageBoxIcon.Error)
blnFlag = False
Else
bmBase.Position = Me.pPosition <--- It will show the wrong one
record.
endif




 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How do I refresh a dataset? Larry Bud Microsoft ASP .NET 1 19th Jan 2008 05:39 PM
Ado.net DataSet Refresh =?Utf-8?B?TWFuanJlZSBHYXJn?= Microsoft ADO .NET 45 10th Aug 2007 09:00 AM
Refresh DataSet - please Help Me :-( chreo Microsoft VB .NET 12 1st Apr 2005 06:09 PM
best way to refresh a dataset. jaYPee Microsoft ADO .NET 10 23rd Nov 2004 07:39 PM
best way to refresh a dataset. jaYPee Microsoft VB .NET 10 19th Nov 2004 08:36 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 08:02 AM.