PDA

Click to See Complete Forum and Search --> : Calling all VB Guru's - Help on DBgrid/ saving records - Urgent


raj
Apr 26th, 2000, 02:46 AM
Hi guyz;
i was wondering if there is any way to do this:
I'm using a true DB Grid and connecting it to Access database. Is there any way i can save the whole grid(all the records in the grid)as one record in other different access database????
details:
there's a form that contains other txtbox fields and a DBGrid. so i wanna save all the fields in access database
along with all the records in DB Grid...relating to same
record on form....so whenever i find that record on the form, it should display those records in datagrid which were entered along with those txtbox fields
again:
DBGrid is bound to different table and i'm adding records in that. Now that grid can contain many records.....
but on the other hand the form only contains one record
so what i want is when after saving the record along with DBGrid records in databse.then searching that record again n it should display those records in datagrid related to that perticular record....could be 1 , 2....any

All ideas are greatly apppreciated...
thanx a lot in advance
Cheers
Raj

curlywink
May 3rd, 2000, 06:52 AM
Hi there,


I've implemented this before using DAO... Try this ...

I'm assuming you have two data controls to go w/ each table, and your controling navigation via data control bound to the textbox, right ? now on the data control bound with Textbox add a code to its Reposition Event ....

Private Sub Data1_Reposition ()
Data2.Recorsource = "Select * from <yourtable> where <youfield> =' " & Text1.text & "'"
Data2.Refresh
End Sub