This is just to let you know that I have now successfully fixed my problem.
I had the pastespecial in the wrong place. I put it at the end instead of the begining where the sheets were created.
this is my code now. It pastes the logo on to all the created worksheets in position (1,7) and then...
Thank you for your help the code works perfect.
The only problem I am having now is that I am exporting to one workbook with multiple worksheets by looping through the data.
I am putting the logo onto Cell G1 this works on all the sheets except the last one where the logo is put on to cell A1...
Please can anyone help me. I have a form in Access 97 which has parameter fields that are used to extract
data from my database and Export to Excel when a button is clicked. We have Access 97 and Excel 2000 using the EXCEL9.OLB
My code is quite long as it loops though recordsets and...
...DB.Execute "DROP TABLE [PaymentCertificatetmp];"
'Now Create the table with new values
DB.Execute "SELECT PaymentCertificate.* INTO " _
& "[PaymentCertificatetmp] FROM PaymentCertificate;"
' Delete the ContractNametmp table first before making a new table...
Please can anyone help me. I am trying to supply two variable input dates to an SQL Specific passthrough query from and Access 97 Database.
The table is on a remote server.
This is the query I have so far it works if the table is in my database but not when I use the linked table.
select...
Thank you jerry the code is now finished and works perfect.
Thank you so much for your time and help.
I didnt know enough about vb to get this going.
Best regards Sid.
Thank you Jerry, this works perfect. I get only the qualifications for each employeeID.
The last Problem I have now is that my code only makes writes one record to the table.
I think its this area where all the loops are written to the table.
Do Until rsPeople.EOF
rsMaster.AddNew...
I have managed to solve the loops by changing the master table fileds to memo.
This fixed the problem and writes the data to the master table now. But it puts all the qualifications from the table into each of the memo fields instead of only the qualifications for each employeeId.
thank you...
I have managed to debug the recordset part of the code now
" WHERE (((tblEmpHistory.DateFinish)is null))")
I fixed the is null problem it only needed ))")
the last closed bracket closes the sql part off.
I am trying to get the loops working now.
Loop
rsMaster!NRWSA = strNRSWAQual
Loop...
Thank you so much.
I substituted the quote markes with apostraphies and that fixed it.
I have other errors now with
WHERE (((tblEmpHistory.DateFinish)is null") the is null does not work. But at least I have got over the worst.
Thank you.
regards,
Sid.
Thank you for your help.
I have put this code behind a button on an On Click event.
When the button is clicked to run the code this error message is displayed:
Run-time-error '3421'
Data type conversion Error.
I am trying to get the name, Marconi Id and Personal details to be captured in the...
...'must be just name of output table
Set rsMaster = db.OpenRecordset("tblBadgeCrdsNew2")
' Set rsPeople = db.OpenRecordset("SELECT * from tblEmployee")
strsql = "SELECT tblBase.BaseName AS Depot,"
strsql = strsql & "UCase([FirstName]) & ', ' & UCase([Surname]) AS Employee_Name...
..."Getting Data for Export ......Please Wait ....."
'this sets the windows open save filters to be excel
strFilter = ahtAddFilterItem("Excel Files (*.xls)", "*.xls")
'This calls the windows open save window
strsavefilename = ahtCommonFileOpenSave( _...
...DB_OPEN_DYNASET)
Criteria = "ContractName=" & rsCriteria("Contract")
rsCriteria.MoveFirst
strsql = "SELECT * FROM PaymentCertificatetmp where "
strsql = strsql & "[ContractName]= '" & rsCriteria![Contract] & "'"
'*** loop to move through the records in Criteria table
Do Until...
I forgot to say the criteria for selecting the Certificates each week is the Week Ending Thursdays.
and The Organisation name which is the suppliers name.
This is supplied through my form.
which also makes a table from the data where I am trying to get the output to exel from called...
Thank you for your reply. I have all the data in an Access 97 Database it would be easy just to send out an Access report that puts all the data on to the correct pages. I have to send out the certificates each week in Excel format so that they can be reconciled and modified at head office. I...
...[ContractName]as Contract,[OrderNumber]as OrderNo,[DepotName],[EstimateNo],[ExchArea],[Description],[Planned]+[DFE] as Qty,[Rate],[Qty]*[Rate] as Total,[organisation] FROM PaymentCertificatetmp where ContractName = '67325712'")
Set rs2 = db.OpenRecordset("SELECT [ContractName]as...
Thank you for your reply.
I am getting Compile error Variable not defined on all the
Variables. I am trying to work out how to do my own.
lcYear
lcMonth
rsEmployeeHeader
lnColCnt
wks
llArchiveFlag
lnProcessRow
Are the variables from a report?
Can I use a report as a recordset for...
I am trying to export a large query to excel and be able to group each contract and put on to a separate worksheet the same as a report would do. As their are many contracts it is not possible to be able to define each contract to go on to a named worksheet.
I need to be able to somehow...
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.