Recent content by June7

  1. June7

    Solved What is going on here?

    Seems Access recognizes hyphen as date part separator when enclosed with # or within string in CDate(). ?#2-2-2025# 2/2/2025 ?CDate("2-2-2025") 2/2/2025 Otherwise, you get subtraction. ?CDate(2-2-2025) 6/14/1894 Allen Browne shows forcing a date to U.S. MM/DD/YYYY arrangement...
  2. June7

    Solved What is going on here?

    Pat, the #'s are included in the strcJetDate constant. See post #2. Tested and works.
  3. June7

    Solved What is going on here?

    strcJetDate is a declared constant, don't enclose in quote marks. You didn't in Immediate Window so don't in your procedure.
  4. June7

    Solved Combining IIf Statements

    Local means variable can be accessed only within the procedure where it is declared. Cdbl() is a function that converts a value to Double data type. Your function won't work. You have made too many bad edits to the code Isaac provided. The first being the function declared name. Then you put...
  5. June7

    Solved Combining IIf Statements

    The function requires input for 4 arguments. You provide only 2 then you throw in AND ... . This makes no sense. Look at Isaac's example again.
  6. June7

    Working with VBA and where it starts

    VBA code goes in a VBA module, not in a query. Do you know how to open the VBA editor? VBA code can be behind forms and reports or in independent modules. I expect the code you reference needs to be in an independent module. An expression in query can call a VBA Function procedure (not a VBA...
  7. June7

    How to use a search form by launching it from different forms?

    Some Options: 1) pass calling form name to frmArticoliCerca with OpenArgs 2) pass other info to frmArticoliCerca with OpenArgs 3) calling forms set global variables or TempVars that are available anywhere
  8. June7

    Solved Combining IIf Statements

    Hard to say. What do you already know about programming? Ever programmed in any language? The basic concepts are transferrable. Start with review of https://support.microsoft.com/en-us/office/introduction-to-access-programming-92eb616b-3204-4121-9277-70649e33be4f It's considered good etiquette...
  9. June7

    export and transpose problem

    Rearranging data from horizontal to vertical is a red flag that data is not normalized. But as long as you have it handled and solution works, call it done.
  10. June7

    Solved Combining IIf Statements

    If you want to get this resolved, really need to provide file - follow instructions at bottom of my post. That way we can design and test with your schema.
  11. June7

    Update records on a SQL Table

    I did suggest saving the discount % was an option. Would be interesting to know how retail store programs document discounts: member and sale discounts on specific products, mfr coupon, then maybe a discount off the entire purchase. I expect a record for each.
  12. June7

    Update records on a SQL Table

    I don't see need to save SellingPrice to Products table. It can be calculated when needed. Only reason to save in OrderDetails is if the percentage can vary over time. In which case, maybe the percentage should be saved, not the calculated result. This is the same justification for saving...
  13. June7

    Solved Combining IIf Statements

    Don't see how your original expressions could work. They really make no sense. Looking at one: IIf([tblEmployees].[Marital Status]=1,[tblEmployees].[Basic Salary]<[tblpayrolltaxes].[Lower],[tblpayrolltaxes].[Amount from Column A]-[Exemption credit]) What that does is if Status = 1 then the...
  14. June7

    export and transpose problem

    Transpose from horizontal to vertical in Access would be a UNION query. Looping recordset is really inefficient. Might want to explore CopyFromRecordset method. Or look at TransferSpreadsheet method again. And there is OutputTo method. Review https://accessmvp.com/KDSnell/EXCEL_MainPage.htm...
  15. June7

    Solved Combining IIf Statements

    Could provide sample data and desired output as tables in post. Also, show the two working expressions.
Back
Top Bottom