Search results

  1. O

    New line on IF Statement

    Hi, I am trying to split this long IF statment up across two lines so its not on one huge long line but it won't let me, what am I doing wrong?! Thanks If Me.Chk2Discipline = True And Me.Chk3Discipline = True And Me.Chk4Discipline = True And Me.Chk5Discipline = True And Me.Chk6Discipline =...
  2. O

    VBA Insert Into

    Hi, I have the following insert into statement: Dim RS As DAO.Recordset Set RS = CurrentDb.OpenRecordset("SELECT * FROM OrdersCheckBoxes") RS.MoveLast RS.MoveFirst Do Until RS.EOF If RS!FireCheckBox = True Then...
  3. O

    Using Cross Tab Query In Report

    Hi, I have built a dynamic cross tab query to return the last 3 years of invoicing totals per customer which works fine. I intended to then use this for a report but didn't realise its not as simple as this. My dynamic crosstab query is as follows: PARAMETERS...
  4. O

    Printing/Saving Multiple Reports to PDF

    Hi, I have the following sub routine which loops through a number of records and outputs and saves a PDF of the report in its respective folder. I am trying to make the process more efficient by it not opening the report each time and rather have it do it in the background. The trouble is when...
  5. O

    Changing Query Criteria

    Hi, I have a simple form with list box on showing data from a query that the user can filter by changing dates in two date boxes. In the query the criteria on the [SentDate] field is as follows which all works fine: Between [Forms]![frmFindQuoteRecord]![txtStartDate] And...
  6. O

    Office 365 Recent Items

    Hi, In our DB a lot of our reports are PDF'd out of Access for which we use VBA functions to achieve. In some cases these PDF's are saved to a local directory for use/distribution by the user. In all the office apps if you create a document or PDF something it automatically appears in the...
  7. O

    List box filter on form

    Hi, I have a form which shows a list of records. To help the user find the record they want I have a text box txtSiteName which the user types into. On the OnChange event of this there is the following code: Private Sub txtSiteName_Change() Me.txtSiteNameX = Me.txtSiteName.Text...
  8. O

    VBA Counting Records Based on Select Case

    Hi, I have been toying with this module for a while and wonder if anyone can help. I have the following code which looks up some files relevant to a project record and then copies them to various directories so they are correctly catalogued for distribution to a client. As it stand the module...
  9. O

    Running Row/Record Number

    Hi, I have a totals query that returns any number of results sorted in date order. What I need is to then create a column called [Sequence] that then shows the row/record sequence number as per below: Year OrderNumber SumOfQuoteValue Sequence 2023 MJ0092763 5987.76 1 2024 MJ0092763...
  10. O

    SQL Server - Is it faster? Speeding ACCESS Up!

    Hi, I have a split DB with the BE (0.5GB) residing on a network drive. All users have an FE file on their local machine. All machines are at least i5's, mostly i7's with plenty of RAM running on a gigabit network. There are usually around 12 users using the DB simultaneously. I have been...
  11. O

    Using CASE in VBA

    Hi, I have a module that within it I have to use the same CASE argument several times as it loops through a number of different processes as per below: Select Case rstDetail.Fields("CategoryID") Case 20, 32, 33, 34, 35, 36, 37, 56, 58, 59, 60, 125 There is the...
  12. O

    Query - Dates

    Hi, I have a query I am filtering dates with criteria as follows which works perfectly: Between [Forms]![SalesAnalysisQuotes]![txtStartDate] And [Forms]![SalesAnalysisQuotes]![txtEndDate] However I want to introduce an IIf into this as follows...
  13. O

    Solved Access/Office Title Bar Width Has Changed

    Hi, Does anyone else have the issue where the Access application title bar at the top of the screen has changed width? A number of forms in my DB were sized exactly to an HD screen running 100% font sizes and now because the application title bar has increased in width by 4mm I am losing 4mm of...
  14. O

    SQL to VBA Conversion

    Hi, I have the following working SQL which I need to convert to VBA which I have done. When I run my VBA I get a syntax error which through a process of elimination relates to the embedded IIF statement. Can anyone see where I have gone wrong with this? SELECT Min(tblVisits.VisitDate) AS...
  15. O

    Query Read Only

    Hi, I have a fairly basic query based on a single main table 'Quotations'. The query has a join to a subquery which contains 2 further subqueries which are 'Totals' queries which enable the sum cost of all products in one and labour hours in another which are then combined to give the 'Quote...
  16. O

    Add two values where another field equals given value

    Hi All, I'm either missing something obvious or just have total brain block! I have a series of complex queries which collate a load of data together into a single query which is then shown on the report as per below. In the footer of the report I would like to perform some simple calculations...
  17. O

    Solved IsLoaded in query criteria?

    Hi, Does anyone know if you can use the IsLoaded function in a query criteria? I have tried: IIf(IsLoaded([Forms]![Purchase Orders]),[Forms]![Purchase Orders]![OrderID],[Forms]![Purchase Orders NEW]![OrderID]) But I keep getting an error......!?
  18. O

    Manipulating Text Strings; InStr InStrRev Mid Right Left Len!!

    I am going mad here trying to work out the InStr, InStrRev, Len, Mid, Right, Left VBA functions!!! Can you help end my struggles please……!? I have a foldername = "c:\TEST\tempfoldera\" (example) And using one/mix of the above functions I want to retrieve everything AFTER the 2nd “\” from the...
  19. O

    Folderpath Edit VBA

    Hi, I have some code which alters the final subfolder name in a folderpath. The code works fine. However, I now want to be able to edit the name of a folder in the middle of the path, i.e. a folder that contains a number of sub-folders. The code I am using errors when I try this. Does anyone...
  20. O

    Totals Query VBA

    Hi, I have a totals query in VBA which has only 1 column which creates a single totalled value. Can anyone advise how I can then take this value and then assign it to a variable so I can use it elsewhere? Thanks
Top Bottom