Search results

  1. H

    Continuous Forms - Different Properties For Each Row

    I have a form containing a sub form. The main form is for orders, the sub-form contains items against the order and is set to continuous form view. We have a price field set to a double in the DB back-end that is generally displayed to 2 decimal places on the sub form. Very occasionally I'd...
  2. H

    255 character limit on query fields

    I have a query, the results of which are pasted into a spreadsheet template for a monthly KPI report that goes to one of our biggest customers. The problem is (and I know that this is old news) Access's 255 character limit on fields in a query. Even fields set to longtext or blob get cut off at...
  3. H

    acCmdSubformDatasheetView - command not available

    I came across this thread as I was struggling to get the acCmdSubformDatasheet command to work as I constantly got the errors: Run-time error '2046': the command or action 'Formview' isn't available now For anyone in the same situation, you need to ensure that on your Form Properties, under...
  4. H

    255 Character Limit on Query Fields

    Hello guys. I am having a problem with a query in that it truncates longtext fields to 255 characters. Having read up on this, it seems this is a restriction enforced by Access, for whatever reason. Does anyone know of a way around this? I have to use a query as opposed to a report as the...
  5. H

    Programmatically Change Form Views

    I came across this thread as I was struggling to get the acCmdSubformDatasheet command to work as I constantly got the errors: Run-time error '2046': the command or action 'Formview' isn't available now For anyone in the same situation, you need to ensure that on your Form Properties, under...
  6. H

    Detecting when Access, and not a specific form, has lost focus

    Thanks for your comprehensive response The_Doc_Man. It's never quite made any sense to me, either. But I have seen this behaviour happen on numerous occasions. Basically my user will be working on an Order or Quotation in Access and will have added items to it. She'll then switch to Excel to...
  7. H

    Detecting when Access, and not a specific form, has lost focus

    Also, how the hell can I change my stupid username on here? :D
  8. H

    Detecting when Access, and not a specific form, has lost focus

    Hello, I am using a Microsoft Access .mdb front end and a MySQL back end. I have a bound form containing a sub form. For one of my users, sometimes when she switches from Access to Excel and then back to Access a minute or two later, she gets a #DELETED error in the subform and one or more of...
  9. H

    Long Query Being Broken by Line Breaks

    The query is generated by the following code. As you can see I even tried reducing the length of the lines in the str_sql_select part of the string but that makes no difference as they're all concatenated. Dim str_sql_select As String Dim str_sql_from As String Dim str_sql_where As String Dim...
  10. H

    Long Query Being Broken by Line Breaks

    The full query is: SELECT tbl_orders.sales_order_id AS [order], tbl_companies.company_name, tbl_order_details.product_code, tbl_order_details.item_number AS item, tbl_order_details.quantity AS qty, [tbl_orders].[currency_rate]*[tbl_order_details].[price] AS price_sterling...
  11. H

    Long Query Being Broken by Line Breaks

    Hello, I'm trying to run a long query through VBA code. The query itself works just fine, but when run through VBA is being broken because Access is adding line breaks in the middle of words and thus breaking the query. For example, it's trying to run: SELECT * FROM MY_TA BLE WHERE id = 1 AND...
  12. H

    Use two decimal places only when required

    That's not a bad idea, actually. But it's a little tricky given this is a long-established project with many thousands of lines of records I'd have to go back and modify.
  13. H

    Use two decimal places only when required

    I am using continuous forms, so do need to format each line individually. I could format each quantity as a string in the main query, however, I do calculations on the quantity, too, which would mean I'd need to call the quantity twice, once as a double and again as a string, which seems...
  14. H

    Use two decimal places only when required

    Is it possible to modify a control on a form so that it shows to 2 decimal places only when required and show to 0 decimal places the rest of the time. I'm working on our invoicing system and the field quantity. 99% of the time we are dealing with whole numbers and 2 decimal places is not...
  15. H

    Access Crashes When Connecting to DSN

    I'm a bit late to the party on this one but I had the exact same issue. The way around it is to establish the link between your DB and Quickbooks using the QODBC setup wizard rather than by using a DSN.
  16. H

    Which Form Event would be generating the "No current record" error?

    I've been getting this error a lot on bound forms when I save the final currently live record. This seems to have fixed it for me. Now if only I could solve my constant SQL write conflict error messages.
  17. H

    acCmdSubformDatasheetView - command not available

    I'm having this exact same issue, and what's particularly annoying is that I've done exactly the same thing on a different form and it works just fine. For the record, the subform doesn't have to be linked to the main form for you to be able to switch between data and form view - I say this...
  18. H

    Sorting on a calculated field producing unexpected results

    That seems to have done the trip. Thanks a lot obeylele. :)
  19. H

    Sorting on a calculated field producing unexpected results

    If I run the query (as a new query) without any WHERE clauses, if I then do a manual sort on the days_late column, it still does exactly the same thing. The first 4868 records in my result set are sorted in order, but the remaining 600+ are then sorted again separately. The next hundred or so...
  20. H

    Sorting on a calculated field producing unexpected results

    I have a relatively complex query that shows delivered orders and calculates the number of days they were late. I want to sort the results of the query by the field days_late which is [delivery_date]-[despatch_date] but as you can see by the screenshot below, It partially sorts the results but...
Back
Top Bottom