Search results

  1. S

    Moving Script to ThisWorkbook

    Hi I have VBA script that operates as it should, but I want to move it from the sheet to "ThisWorkbook" so when it opens it executes When I do that, I get RunTime 9 Error Any help is appreciated The script: Private Sub Workbook_Open() Dim main As Workbook Set main = ThisWorkbook...
  2. S

    Open, Filter & Import

    Thanks everyone for your help. because the excel workbook was a report on a server from another system, I didn't want to hang it, so I've created a temp excel file that will extract only the columns I need, which brings it down to 145 columns. Now I just need to link Access DB to the excel file
  3. S

    Open, Filter & Import

    theDBguy 42,166 rows by 352 columns So I will need to hide a few columns before I import the file
  4. S

    Open, Filter & Import

    Hi, It's been a while since I have tried my hand at VBA and need some help to get me going again. in Access VBA, I'm trying to open a spreadsheet, filter it (because the file is too large) and then import into a table. Any help would be appreciated. Thanks
  5. S

    Change date format display in mail merge document

    try this: In the word doco select the mailmerge field. Right click Select Edit field Select Field codes (bottom left corner) at the end of the field codes insert: @\"mmm-yyyy" You may need to set the field in your table to be a text field for this to work 100%
  6. S

    Auto Kick & Compact

    I am finishing up my job but there will be nobody to take over from me when I leave. So what I want to be able to do is have code in the db that will automatically kick everybody out and compact the db every Friady night. Can anyone please help regards
  7. S

    copy from excel & paste to word

    I want to have code in my db that will enable me to to copy a range of cells from excel and paste then into a table in word. The word document will be new. Any ideas? Thanks in advance
  8. S

    Copy and Paste excel

    I remember seeing this some time ago but can not find it now. I have two workbooks and I want to select the columns from workbook 1 and paste them to workbook 2. and save the sheet as a something besides sheet1 Can anyone help Thanks in advance
  9. S

    Data in Text field changing to symbols???

    I had the same problem some time ago but not too sure what was wrong. I do know it wasn't to do with indiviual machines. Have you copy and pasted anything into the field recently? Or, you or someone has changed the memo field characteristics? is it only with data entered recently?
  10. S

    formatting excel cells

    Hi guys, I just cant get this sucker worked out. I hope someone here can help me. I want to export a query to excel which I have done. but I want to add formulas to the spreadsheet preferably at the end of the record I have just export. for the cell I though something like this would be...
  11. S

    exporting to excel with color

    I have a query that I export to excel. What I want to do is make some of the text Bold. I have a fields called "Forecast_survey_date" once that field is updated I have it set up so that field "Date_Changed" updates the current date when "Forecast_survey_date" was changed. I not too sure what...
  12. S

    Change Text Colour

    I currently import data from a spreadsheet and update a table with the information using an update query. What I want to do is if the data in the table is changed with the data in the spreadsheet than change the colour of the text. Is this possible
  13. S

    exportting to excel

    I want to be able to export a query to excel, but I want to export each record to it's own workbook. the data would like like this: Site | Contact | Phone number ------------------------------------------- Here | Joe B | xxxxx-xxxxxxx This what I have so far...
  14. S

    E-mailing CERTAIN fields from a query

    this will help you get started. I can only get this to email one set of records. But at least it's a start. If you work out how to get it to send more than one let me know. ------------------------------------- Dim rst As DAO.Recordset Dim qdf As QueryDef Dim prm As DAO.Parameter Dim oOutlook...
  15. S

    exporting to excel error

    I am trying to import an Access query into an excel spreadsheet. but I get this error: Too few parameters. Expected 1 I have looked at the query in my db and it works well. from excel I am using the "New database Query". If I use "Import data" the query does not appear in the list in the db.
  16. S

    Update query problems

    I don't fully understand it. But here it goes. When updating a table froma query Access does not seems to like it when the query is grouped. Go figure
  17. S

    Update query problems

    I created a update query a few days ago. It worked fine at the time. Now I get a error: "Operation must use an updateable query" Nothing has changed on my database. Other update queries still work. If I create another database and import the query and the table I want to update i can create a...
  18. S

    email coding

    Can anyone tell me why my code doesn't work? Just a run down on the code. It opens a word template and export data from a query and saves the word doco to my C drive. It then emails the word doco. This works well with once record in the query. But, If I have moew than one record it will sen the...
  19. S

    How to set up a word doc on templet

    Sorry I added to many lines. here it is again. ------------------------------------------------- Dim objword As New Word.Application Dim objdoc As Word.Document objword.Application.Visible = True Set objdoc = objword.Documents.open("C:\Template.dot") objword.Visible = True...
  20. S

    How to set up a word doc on templet

    I hope this helps. ------------------------------------------------------- Dim objword As New Word.Application Dim objdoc As Word.Document DoCmd.OpenQuery "qrxDelMailMergeItems" DoCmd.OpenQuery "qrxAddMailMergeItems" objword.Application.Visible = True Set objdoc =...
Top Bottom