|
-
Sep 2nd, 2003, 09:53 PM
#1
Thread Starter
Fanatic Member
WARNING: Newbie question.
This should be an easy one; it involves editing records.
Here's the situation:
I am displaying the contents of a database inside a listview. I am wanting to edit the listview, and when I finish, it will first search the database for the old value (held in a String-type variable called OldVal), and then update it with the new value (what I put in the listview.)
One more thing: I'm not using a bound control, so a simple rs.Update is out of the question.
-
Sep 3rd, 2003, 01:10 AM
#2
Lively Member
I dont think you can edit the values in the listview itself.
This is what I do...
Populate the listview and with the records
including the Primary Key (either as item key or listview text)
when u double click the Listview execute a similar Query
"SELECT (fields) FROM (table) WHERE (primary key) = " & listview.selectedItem.Text
All you have to do is populate textboxes with the Recordset.
Do While Not RS.EOF
text1.text= RS!FieldName
loop
It helps setting the Listview labelEdit property to manual and FullRowSelect to true.
Hope this helps,
If you find a way to edit in listview please let me know
-
Sep 3rd, 2003, 07:36 AM
#3
Thread Starter
Fanatic Member
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|