Search results

  1. L

    Variance In Crosstab

    Hi All, Im not having much luck with this - Ive tried DVar but maybe Im not understanding the function correctly. I have a crosstab query that will only ever return 2 columns of data (sales for the current month and the previous month). I want to add a column that will show the variance...
  2. L

    Outlook calendar category colour

    Hi All, I have been using the below code for a number of years to send reminders to Outlook and colour them red (my category colour for certain items). I've been asked to roll out this code to all members of my dept but the category for other people assigned to the red colour is different to...
  3. L

    Calculated Field

    Hi All, I'm having trouble thinking of a way to create a formula to work out ratio of cost. The table below shows what I want to see. My query pulls out the Cust ID, number of days, and USD value (it shows how quickly customers are paying their bills). The Ratio I've manually added and...
  4. L

    Keep Preceding 0 in VBA

    Hi All, I'm sure this has annoyed others and hope someone knows of a simple soloution. I want to create an IF statement based on: If Right(DMax("[MyField]", "[MyTable]"), 2) < 06 Then But VBA automatically removed the preceding 0 showing: If Right(DMax("[MyField]", "[MyTable]"), 2) < 6...
  5. L

    Get first working date after specific date.

    Hi All, I've searched Google for a bit and can’t find quite what I'm looking for. There are a variety of date functions but I specifically want to show the date or the first working day after the 25th of each month. Eg: if 25 Oct is a Monday then result = 25 Oct if 25 Oct is a Sunday then...
  6. L

    UNION / UNION ALL Query Crashed Access

    Hi all, I'm having a problem with a UNION / UNION ALL query. It seems there is a application crash fault when running the query that MS are aware of and have issued a hot fix. Unfortunately it will take my IT dept some time to check and install the hot fix – If they agree to do it at all...
  7. L

    Update Table Using Union Query

    Hi All, I'm having trouble with something that should be straight forward. I have a table with a field I want to update with the value of a Union Query The field I want to update is Yes/No format and I can update using 0 or -1 OK. However, when I link in the union query (and check that I...
  8. L

    Change Field Format in Query

    Hi All, I'm having a format problem I'm hoping someone can advise me on. I have a query (Q1) that, among other things format a date field as YYYYMM (Field1). I have a second query (Q2) whose data source is Q1. In Q2 I need to link Q1 to a table but Field1 is being reformatted as text...
  9. L

    Get column name based on record

    Hi all, This may seem like a strange request but I wonder if anyone can help? I have a table with 3 columns (Col1, Col2, Col3). I have a record like: Col1=A, Col2=B, Col3=C. I want to be able to do a sort of DLookup but searching all columns for "C" and returning the name of the coloumn "C"...
  10. L

    Auto Email Using Word Template

    Hi all, I have a lot of automated email in a database with the body of the email written in the VBA code. It suits me fine but I'm the only person who can update the text of the email. I've been looking at putting the text into Word which I have working just fine… BUT the content of the email...
  11. L

    Dynamic Sheet Range When Importing Excel To Access

    Hi All, I receive an Excel workbook frequently from a third party that’s I want to import to Access using TransferSpreadsheet. This is all well and good but the sheet I want to import has a different name everytime. The third party are unable/unwilling to amend the sheet naming process...
  12. L

    Calendar Control 12.0 Date Changing

    Hi all, Very strange going on with calendar control 12.0. I'm using it to append deadlines to a table. When the date is selected and cmd button pressed, it write a row of text including Me.Cal1 (my controls name). The code below is my SQL which I run through VBA. I have added a line of...
  13. L

    Query "Enter Parameter" Multiple Items

    Hi All, This may be something quite basic... or not. I have a query in which I am asking for a parameter to be entered. Works fine! My question is how do I enter multiple items ("Item1" or "Item2")? Many thanks
  14. L

    Access made PDF not printing correctly

    Hi all, I have a database which selects Excel files and turns them to PDF. If I open the PDF it shows each Excel sheet as a page. The PDF shows the document the right way up regardless of orientation (some pages look portrait and some look landscape). Even though the sheets look as Id...
  15. L

    Shell command to close Acrobat

    Hi all, I'm using Shell Command to select PDF files via Access and print them (code below) Shell "C:\Program Files (x86)\Adobe\Reader 10.0\Reader\AcroRd32.exe /p /h " & MySQL This is great BUT when the file has printed it leaves Acrobat open. Can anyone tell me the She Command to exit...
  16. L

    Access to save existing Excel workbook as PDF

    Hello all, Does anyone know if it is possible in Access 2007 to select an Excel workbook and create a PDF file of the visible sheets? Thanks
  17. L

    Sending Email From Shared Mailbox

    Hi All, Im having a hard time finding a decent example on Google so hoped someone could point me to one, or let me know how... I use Access/Outlook to send automated emails a lot but now Ive been asked to set it up so that all emails are sent from a shared account. MSDN seem to have an...
  18. L

    Export to Excel changes format from number to text

    Hi all, Ive tried searching for an answer to this but it seems there isnt on (that I can find). I have some code that exports data from Access to Excel. The data in Access is numer formatted. hen Excel opens, the data has changed to text which the pivot tables wont show (unlss I use text to...
  19. L

    Runtime 7874

    Hi all, I'm having a problem with Runtime 7874 (Cant find the object INSERT INTO...). I run all my queries from VBA but haven’t come across this yet. The query runs perfectly from Query Design, but debugs when running from VBA. Can anyone see whats wrong? Thanks for any help. --- SQL...
  20. L

    Cbo box defualt value

    Hi All, I have a cbo box with user names in. It has 2 columns (showing actual name and user name), and I have included an “All” option (its based on a union query). The “All” option returns the value “*”. When a user opens the database, the cbo box defaults to their name. Bu I want to amend...
Top Bottom