Search results

  1. J

    Is this a normal behavior in Access?

    Unfortunately, this is the “comfort functionality” of VBA/VB6 that I would prefer to turn off. :)
  2. J

    Is this a normal behavior in Access?

    is equal to Function test() as Variant In principle, functions behave in the same way as variables. Dim X as String Dim Y ' ... equals: Dim Y as Variant
  3. J

    Is this a normal behavior in Access?

    Because the compiler assumes that the parameter is not the parameter of the function but the parameter of the default property of the object returned by the function. Dim frm as Form set frm = Forms("...") dim ctl as Variant ' ... or Control set ctl = frm("ControlName") ' <--- this is not a...
  4. J

    Is this a normal behavior in Access?

    Thanks Philipp, that's exactly the explanation why the compiler can't report an error. I hadn't thought about default properties. And since Variant/Object performs a late binding on object return, the compiler cannot know whether the default property of the “expected” object supports the parameter.
  5. J

    Is this a normal behavior in Access?

    The compiler error only occurs if the function is declared with a variant return. (see #13) The compiler does not complain if the function is declared with a variant return. Private Sub Form_Open(Cancel As Integer) SetTestMode Me End Sub Public Function SetTestMode() As Variant MsgBox...
  6. J

    Solved Correct way of Clone data on a single form in Access

    To be on the safe side, a question of understanding: What do you expect from Form.RecordsetClone? If you expect a copy of the data, RecordsetClone is not the method you are looking for. ;)
  7. J

    Solved Unicode compression when creating a table

    dim cnn as adodb.Connection set cnn = CurrentProject.Connection cnn.execute ... It works with adodb.
  8. J

    Solved Unicode compression when creating a table

    Try ADODB.Connection.Execute CurrentProject.Connection.Execute "CREATE TABLE TEvents " _ & "(EventDate DATETIME, Name CHAR WITH COMP)" or CurrentProject.Connection.Execute "CREATE TABLE TEvents " _ & "(EventDate DATETIME, Name...
  9. J

    benefit of GPT

    I see AI (specifically ChatGPT and GitHub CoPilot) as tools that help me complete routine programming tasks faster. It doesn't do the thinking for me, but CoPilot makes pretty good suggestions about what I need next when writing code - not complete methods - but if you use good names that...
  10. J

    Solved Managing SQL Server Logins in MS Access Frontend

    This does not appear to be an exception: https://www.devhut.net/another-day-another-deleted-feedback-portal-suggestion/
  11. J

    Window version >= 22H2 combo misbehave

    .TestCbo.RowSource = "Op-A,Op-B,Op-C" Which list separator is set in Windows (regional settings)?
  12. J

    VBA code with Date() function not working in runtime mode

    I only see one line where the date function is used. Simple test to see if there is a problem with Date: Msgbox "Current date: " & Date Is QuoteRequestDate an AccessField or a Control/TextBox? If you change the data source dynamically, you could try Me!QuoteRequestDate instead of...
  13. J

    QR code or Bar Code

    Note: (But it doesn't fit the initial topic - just a suggestion) There is a special standard for barcodes (or QR codes) that supports this functionality for different informations: GS1 see: https://www.gs1.org/standards/barcodes GS1 application identifiers: https://ref.gs1.org/ai/ Example...
  14. J

    Solved MS Access Forms cannot allow edit and shows #deleted record in Link tables in MySQL

    What is the data type of the bit data field in the linked table?
  15. J

    Solved Cannot see the wood for the trees :(

    Is there perhaps another Excel instance running in the background with this workbook?
  16. J

    Solved Cannot see the wood for the trees :(

    Does the code work with a manually created new empty Excel file? You may see a message if you make the application visible before opening it. Set xlWBk = ApXL.Workbooks.Open(strPath) ApXL.Visible = True => ApXL.Visible = True Set xlWBk = ApXL.Workbooks.Open(strPath)
  17. J

    multiplying values from different rows

    Product of records = Exp(Sum(Log(x))) ;-)
  18. J

    Extracting varying length string between two characters

    I was of the same opinion until I realized that the test was running too fast (with rs.movelast). Then I inserted a Debug.Print into a function and saw that nothing was output via Debug.Print.
  19. J

    Extracting varying length string between two characters

    If something is slower in a test, that is not necessarily a reason to use it.
  20. J

    Extracting varying length string between two characters

    I also prefer to work without VBA in SQL. The speed of execution (of the select part) is not an argument in this case. ;)
Back
Top Bottom