Search results

  1. T

    On Load Event of Report

    That actually works and many thanks. I am now somewhat confused as I guessed that the on load was more likely to come before the on open event :confused: My terminology logic was load it into memory and then open it on screen, not open it into memory and then load to screen.
  2. T

    On Load Event of Report

    Thanks Ridders, I am beginning to see the problem. To make the report I used the base table as the record source and then generated the code in the on load event. Opening the report by right clicking in the side pane of access causes the report to load using the on load event, either of the two...
  3. T

    On Load Event of Report

    I have a very complex piece of VBA generating a report, for what it is worth the details are below: Private Sub Report_Load() 'Populate results according to criteria on main form Dim scandata As String Dim OrderBy As String Dim BladesOnly As String Dim SearchStg As String SearchStg = ""...
  4. T

    Dashboard Scaling for 42" TV Screen

    I have found the simple solution for large screens is to leave access alone and reduce the resolution of the large screen until it looks right. After all, in most circumstances you are after a big view rather than a high resolution view.
  5. T

    Limiting lines in a table

    Unless of course he is doing averages :eek:
  6. T

    Limiting lines in a table

    Set the properties of the form to Data Entry - NO and this will remove the additional blank record.
  7. T

    Black record with PK

    The simplest approach of all is to make one of the other fields in the table a required field. When it tries to save the record you will just get a message box saying it can't save it.
  8. T

    Hyperlinks showing full network path rather document name

    Maybe this is a change in recent years? All hyperlinks are now stored with two parts, the text to display and the address, for example: "12345#c:\documents\12345.pdf#" will show the text as 12345 and the hyperlink will go to c:\documents\12345.pdf , I believe that unless this is set it will...
  9. T

    importing CSV file - problem with data conversion

    In my experience Excel can deal with this type of date but Access cannot, you need to change the 1/1/2018 to 01/01/2018, I usually fix this in a temp table.
  10. T

    Import specific columns in excel to access table using button

    Try googling DoCmd.TransferSpreadsheet , this will give you a good start.
  11. T

    Order by IIf statement?

    Unfortunately I need the 'contains' logic so cannot remove the one wildcard, I have however added an index to some other fields to speed it up but more importantly noticed that I was calling the procedure 'on click' and re-querying the sub-form 'on-update', removing the double load has helped...
  12. T

    Order by IIf statement?

    Hi Minty, Unfortunately combos are not really an option as I need to just put a letter or two or the entire value into the text box, the actual application is quite unusual. The query takes about ten seconds to process with 140000 records, what is strange is that I was hoping to speed things...
  13. T

    Order by IIf statement?

    This seems to work: Public Function scanresults() 'Populate results according to criteria on main form Dim scandata As String Dim OrderBy As String Dim BladesOnly As String scandata = "SELECT Scans.Scanned, Len([Scans]![Blade]) AS Expr1, " & _ "Scans.ID, Scans.Blade...
  14. T

    Order by IIf statement?

    This now works except for a syntax error when chkfan is ticked: Public Function scanresults() 'Populate results according to criteria on main form Dim scandata As String Dim OrderBy As String Dim BladesOnly As String scandata = "SELECT Scans.Scanned, Len([Scans]![Blade]) AS Expr1, " & _...
  15. T

    Order by IIf statement?

    One final question, I am trying to get rid of a pre-query to speed things up and have tried to add a string using the same methodology but keep falling over on the syntax. What I am trying to do is have a search box on the main form which searches the blade field for any value but also have a...
  16. T

    Order by IIf statement?

    Hi CJ, Many thanks for your help but I opted to go with the solution from ArnelGP. This is probably due to a bodge from long ago, to make the form load all data if no selection was made (on form load), I had a * in the default value of the combobox so it gave a value of * until something was...
  17. T

    Order by IIf statement?

    Oops, no it wasn't. As I was using an underlying query (qryscans) I assumed it would force on the form re-query but it didn't, obviously the form re-queried but the criteria for the query were unchanged. Now works a treat and many thanks for all your help, now I may just use the same logic and...
  18. T

    Order by IIf statement?

    I have a textbox on my form for diagnostic purposes with it's control source =Nz(Forms!frmMain!Check59.Value, 0) so I am sure it is correct.
  19. T

    Order by IIf statement?

    Currently: Public Function scanresults() 'Populate results according to criteria on main form Dim scandata As String Dim OrderBy As String scandata = "SELECT qryScans.Scanned, " & _ "qryScans.ID, qryScans.Blade, qryScans.Engine, " & _ "qryScans.Part...
  20. T

    Order by IIf statement?

    Interestingly, if I invert the ifs it sticks the other way around. It isn't a re-query issue as I can force this and it still makes no difference.
Back
Top Bottom