Search results

  1. C

    VBA - Pass value from form to report for group/sorting options

    Use OpenArgs parameter to pass criteria string on DoCmd.OpenReport: DoCmd.OpenReport stDocName, acPreview, WhereCondition:=BuildFilter OpenArgs:="something you want to pass" and then read it in Report_Open event sub: Dim CriteriaString as txt CriteriaString=Me.OpenArgs
  2. C

    Add date and team ID when using Insert Into query

    OpenArgs should work, as RuralGuy suggested. You could pass both as one delimited string, then split it back in two variables in OnOpen event.
  3. C

    How to Disable a button on a form

    You need to set timer interval as well. In properties window for the form, on the Event tab - Timer Interval, it's in miliseconds so 1000 means 1s. Also I'd avoid spaces and special characters in object/control names, that's asking for trouble. Maybe change name of the button to...
  4. C

    How to Disable a button on a form

    Create a timer on the form. Then in OnTimer event: If Hour(Now) > 14 Then YourButton.Enabled = False End If Your Timer can have interval of 1 minute unless you want to be more precise then set it to 5 seconds or even 1. Up to you.
  5. C

    Win 10 keyboard Location

    AFAIR settings for touch keyboard are in Settings->Devices->Typing (not 100% sure and can't check it right now).
  6. C

    Getting a combo box to show an update to a new record in a table

    Have you tried Me.YourComboBox.Requery ? Edit: sorry, didn't see a "macro builder" part. I never used it so no idea here.
  7. C

    Several different queries use a date as criteria - each need updating manually...

    If you'd like to go this way you can use DMin function. DMin("YourDateFieldName","YourDedicatedDatesTableName") Don't name your fields Date, Name etc. as those are reserved words and may cause trouble later on.
  8. C

    Several different queries use a date as criteria - each need updating manually...

    One idea: create a standard module with public function that returns your wanted date and use it in query. You can't use vba variables as query parameters but you can use functions.
  9. C

    How to find X consecutive occurences?

    Thank you guys, I got it sorted using principles from Allen Browne's website. Very helpful reading indeed.
  10. C

    How to find X consecutive occurences?

    Hi All, I got a table with records of inspections of some sort: Parts may come from different suppliers. I need to find every PartID from supplier with 4th consecutive positive InspScore but, to make it harder (at least for me) I need that 4th to be last inspections (chronologically). So in...
  11. C

    Find active record on a given date

    Your query to base the report on will be: SELECT EmpID, JobTitle FROM tblTestData WHERE StartDate<=YourSetDate AND EndDate>=YourSetDate
  12. C

    After Decompile and Import all objects - Last form closes but leaves Access open

    Maybe try Application.Quit instead of DoCmd.Quit? I read somewhere that despite those two do exactly the same, DoCmd.Quit is more for legacy purposes.
  13. C

    Week Numbers Error (DatePart)

    It's not error really, it's because of using default values for parameters you omitted. DatePart function looks like that: DatePart ( interval, date, [firstdayofweek], [firstweekofyear]) If you don't input [firstdayofweek] and [firstweekofyear] parameters then Access uses default ones for it...
  14. C

    Filter in msoFileDialogSaveAs

    My sample is exactly your sample. Only thing I had to do is declare WskazPlik variable as it's not in your function. Public Function Plik(TytulOkna As String, TytulPrzycisku As String, Filtr As String) As String Dim wskazMiejsce As FileDialog Dim WskazPlik As Variant Set...
  15. C

    Syntax Error in SQL for updating Date field

    Date for SQL string should be provided in format MM/DD/YYYY
  16. C

    Filter in msoFileDialogSaveAs

    Yes, that. And it works for me, I can see only accdb files and "Save as type" shows "All files (*.*)"
  17. C

    Filter in msoFileDialogSaveAs

    Why? Because MS says so here: https://msdn.microsoft.com/en-us/library/aa190813(v=office.10).aspx
  18. C

    Filter in msoFileDialogSaveAs

    You can't directly set filters on msoFileDialogSaveAs. However if you set the InitialFileName to *.accdb then dialog will force that extension. The filter will still say "All Files" but it will not show files with different extensions.
  19. C

    Unable to view code

    Another idea is to remotely enable special keys, something about it in this thread: http://www.utteraccess.com/forum/lofiversion/index.php/t1263110.html See TheSmileyCoder's post.
  20. C

    Downward arrow as part of MsgBox prompt text (AC2007)

    MsgBox can't use Unicode characters, only plain ascii.
Back
Top Bottom