Search results

  1. B

    CurrentDb.OpenRecordset

    This particular part of my project has been so unique and specific that I had no choice but to do it in a non-conventional way because of the limitations of the number of fields you can have in a query...and yes I broke all the rules with that one. I may never need to use this code for anything...
  2. B

    CurrentDb.OpenRecordset

    I don't even know how to thank you. This worked so perfectly and it did it exactly as I had hoped. I've learned so much from this project and knew NOTHING about VB when I started (I know only a little more than that now). Thank you so much for your time and patience.
  3. B

    CurrentDb.OpenRecordset

    Plate Name is the name of the control on a form with a command button and a combo box. The module is a stand alone module.
  4. B

    CurrentDb.OpenRecordset

    Module: Public Function SendTQ2XLWbSheet(strTQName As String, strSheetName As String, strFilePath As String) ' strTQName is the name of the table or query you want to send to Excel ' strSheetName is the name of the sheet you want to send it to ' strFilePath is the name and path of the file...
  5. B

    CurrentDb.OpenRecordset

    yes when I run the query on it's own using the same search criteria it returns 96 records, so I don't think that is the problem...
  6. B

    CurrentDb.OpenRecordset

    Something so simple and it worked perfectly. Thank you. Now the code opens my Excel file and runs the query but only exports the headers from the query into the worksheet and kicks back a runtime error 3020 No current record. Even tho the query works fine by itself. The debbuger says it's...
  7. B

    CurrentDb.OpenRecordset

    And that made sense, so I made a small form with a command button. Control on form = PlateName. The command button on click code: Private Sub Command2_Click() Call SendTQ2XLWbSheet("qryExportToExcel", "TFDNA311SampleInfo", "C:.....\TF-DNA311_Template.xlsx") End Sub and the module code...
  8. B

    CurrentDb.OpenRecordset

    What is the TEXTBOX portion of the statement supposed to do? I'm having difficulty getting it to run with no errors. Latest error: Run-time error 3075 Syntax error (missing operator) in query expression Plate Name ='". and the debugged line: Set rst = CurrentDb.OpenRecordset(strSQL...
  9. B

    CurrentDb.OpenRecordset

    Thanks you guys! I'm excited to try this now! This might be a dumb question but should I code that on the module or on the query?
  10. B

    CurrentDb.OpenRecordset

    I need the user to be able to put in a plate name for instance WAP001 would return all the samples that are on that plate and export that data to an existing range on an existing worksheet in an Excel file. This is my ultimate goal.
  11. B

    CurrentDb.OpenRecordset

    Yes, and on further investigation I realized that it is a query that has criteria [Enter Plate Name]. When I deleted the criteria from the query it worked like a charm but I NEED it to filter this data before exporting it...ie it needs to be user defined not defined withing the module. any...
  12. B

    CurrentDb.OpenRecordset

    Reviving this post because I'm having the same sort of issue. I'm am exporting the results of a query to an exisiting worksheet in an Excel file. Eventually would like to specify a Cell Range but for now I'd just like to be able to make this work. It seems that others have used this code...
Back
Top Bottom