Thanks CognosChicago and JerryKlmns,
I shall create query as you both suggest.
However I have one question... In the creation of a form based on a query or queries shall I be able to edit all the data from the three tables on the form?
I need to be able to update all three tables directly from...
I have three Access 2000 tables linked by one key field named JobNo. In Access I was able to create a form which displayed all the fields from each table and was able to scroll through the records for each JobNo.
However I am having difficulty trying doing the same with a form created in VB6.
I...
Thanks HarleyQuinn
I shall be using variables throughout my project. So what you posted...
strsql = "UPDATE QPStatusNEW SET QPStatus.DocPresent = True WHERE QPStatus.JobNo='" & yourVariable & "'"
is exactly what I need. I used the hard coding in my initial post just to get started and now I have...
Thanks Chris,
Your code was just what I needed.
I did have to change it a little as I was getting a "type mismatch" error.
So here is the final coding...
Private Sub Command4_Click()
Dim Conn As ADODB.Connection
Dim strsql As String
Set Conn = New ADODB.Connection
Conn.Open...
Can anyone help me code the following. I have picked up help on various bits of this in other forums but would like to see an example of coding from start through to finish so I am posting on this forum which may be more appropriate since it deals with databases...
From a Control Button on a VB6...
Hi Remou and PHV,
Remou...
The Excel sheet holds data like Job Numbers (in cell J:6 example 222555), Part Numbers (B:4 example P123456) and a object/signature in cell J:48 to say the Test to which this document refers has been completed and is signed off which completes the document.
It is this...
Remou and PHV,
Hi guys, here is what I have to date. I have put the two pieces of code each of you have given me behind two control buttons...
Remou..
Private Sub Command1_Click()
Dim cn As ADODB.Connection
Dim rs As ADODB.Recordset
Dim strsql As String
Set cn = CreateObject("ADODB.Connection")...
Remou
I had to leave project over the last week however I am back at it.
The latest I have now is when connecting to the spreadsheet I get the following error...
"No value given for one or more required parameters".
Any thoughts?
Thanks
Hi Remou,
That looks like the answer but as I said earlier it will be a few hours before I can try it.
Just one question though... Do I need to insert the cell location 6:10 (F10) into the sheet name like so... [Eamination$, 6:10]
Thanks again ( I feel a star coming on)
Hi Remou,
Your correct. I didn't realise the excel sheet was named "Examination" and not "Sheet1".
I shall rename this but it will be in about 7 hours from now.
My project is at home and I am working just now.
I am sure I will now be able to connect to sheet and if so would like to move to last...
Sorry Remou
I am getting the following errors...
strsql = "SELECT * FROM [sheet1$6:10]" this gives error "Too many fields"
strsql = "SELECT * FROM [sheet1$:6,10]" this gives error "JET db can't find object '[sheet1$:6,10]'
And I am not sure how the following last two lines will place cell...
Hi Remou,
Can you tell me how or what I need to correct when you said I need to correct this...
cn.Open "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\000-QCProgram\JobsFolder\222222-LPI.xls" _
& ";Extended Properties=""Excel 8.0;HDR=Yes;IMEX=1"";"
strsql = "SELECT * FROM [sheet1$6:10]"
It...
Thanks Remou
I have tried your code but wonder if I am getting it correct.
I think I need to know where to place this code so that when an Null value cell (6:10) in the excel file "222222-LPI.xls" is changed to a text value of "closed" then this is sent to Access database file QPSatus.db where...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.