Search results

  1. G

    Multiple Form Instances in Northwind2 and Query Criteria

    I open form instances with a somewhat clunky way of getting a single record PK into the recordsource query, so I was interested to see how it's done in Northwind2. To my surprise one of the two forms that are opened as instances has an unqualified query as recordsource. In Form_Load, there's a...
  2. G

    Discard form design changes on normal close (unhide columns counts as design change)

    I have a sub form in a tab control which is a datasheet. The column filters are all available. By default there are some hidden columns but they can be unhidden which is ok. But on close of the main form, using the X, Access asks if I want to save the changes. How do I stop this message...
  3. G

    Unbound Lookup with Search form and Query Builder (Beta, WiP)

    My first submission. To be honest I'm always amazed by how the experts here can get so much done with so little code. This might be an example of how little is done with a ton of code, not really sure. If this makes the grade tell me if it should go in Code Repository or Sample Databases...
  4. G

    CBOOL does not affect return db Data Type in query

    I've hit a snag whilst following Allen Browne's recommendation to not use Yes/No fields in tables. Instead, he says use Integer data type and Type 106 Check Box. I have a pseudo "boolean" type in a table defined as number, integer and with field type 106. The issue I have is that when I run...
  5. G

    Modal Pop-up can't be set Visible

    Here's the issue: A form (#1) opened acDialog, can open another form (#2), Modal Pop-up with WindowMode:=acHidden but not acDialog and then set itself (form #2) Visible = true after stuff is passed in. When form #2 is done it sets itself me.visible=false and form#1 gets the return values. As...
  6. G

    DB performance musings, FAYT, John Big Booty vs MajP

    I've been using this lookup routine in my application: https://access-programmers.co.uk/forums/showthread.php?t=188663 I've just been having a closer look at MajP FAYT which has some nice additional features. I commented out three lines of code in the class, so that when the user enters a...
  7. G

    F5 to Step Through brings up Module List

    Trying to step through some code using F5 and it brings up a Macros window. This didn't use to happen. There's a list of procedures, all Public. Just 3 of them are from my own code, but the list seems arbitrary. For example, one of my code modules has 3 Public subs but just 2 of them appear...
  8. G

    Can't focus sub form in tab control on first binding

    Per the title. In my TabCtlDetail_Change sub, I try to set focus to the sub form, then the sub form control. It doesn't work. Despite, Access reporting that that is where focus is. TabCtlDetail_Change calls a sub to bind the page, then attempts to set focus as the last two lines. I put a...
  9. G

    Confused by data types and precision

    A long time ago as a total novice I made my price fields as Currency which gives me prices to 4 decimal places of one UK pound. How can I increase the decimal places stored ? I need up to 5 for prices, and possibly more for another function, with total precision. Looking at the table design...
  10. G

    How do I diagnose Access repeatedly crashing ?

    I have two main forms, functionally similar but sufficiently different to justify separate forms. Each form opens a detail form on a double click event in a tree view control. The detail forms are also functionally similar. So, two main forms, each of which displays a tree view control, and two...
  11. G

    Lock all edits whilst query is running ?

    I've got a form view which takes a second or two to populate and has to make three passes on the same table to get a result. I need to lock out all users for the period that the union query is running or the result may not be valid. I could read data in Pass 1 and if a user then edits...
  12. G

    Solved Focus on form open via VBA

    I have a login form which opens to the user name field which is what I want. On login, it opens a menu form and closes itself. When we log out, it opens the login form and the menu form hides. But on subsequent opens the focus goes to the Access object list. I have to click in the user name...
  13. G

    Organisation for Queries

    Just wondering .. how do you organise your queries ? Naming conventions ? Main vs. sub ? After a form ? Now I have more than a handful of saved queries I'm feeling the need for some kind of method of knowing how each one is used. There's nowhere to save a narrative about the query, unless I...
  14. G

    Join Table on Expression ?

    Can I join a table on an expression ? I have a field in a table called thAcYrPrd which is a long in the format 202006 where 06 = 6th period of year 2020. I decided to do it this way because it makes selection between a period range in the query straightforward. (Periods do not necessarily...
  15. G

    Beginner question I should know the answer to - Form Filters

    Having trouble with un-setting a filter in VBA. It may be to do with master-child relationships, not sure, everything works apart from an Automation Error I'm getting. I have a sub form with a query with no parameters. So if I run the query manually it selects every record from the table...
  16. G

    Can't remove old form filter command in Design Mode

    I've ended up in a situation where my form seems to be 'stuck' with a filter and I can't get rid of it. I've got a form which has a sub form TransLineLedger. The column headings have the drop down arrows to filter on the contents. I also built in one filter on a command button but it seems to...
  17. G

    Query results returned into one column

    I have a query which returns the values I need, but I would like them returned into one column. By that, I mean, I can get three columns in the dataset, called Balance_Grp, Balance_PL, and Balance_BS. I want to consolidate them into one value, OR, format a string according to whether the...
  18. G

    Align text in ActiveX control or some way of doing it

    Just working on getting my tree view form (thanks MajP !) populated with data. I have the text column and a debit and credit column. How can I get them to line up ? I see that the tree view window is an ActiveX control so I don't know if there are any formatting options. I suppose I could go...
  19. G

    SetFocus and Form Footer

    I put my form command buttons in the footer and I'm thinking it may be a design mistake. I like to set my forms up for fast data throughput. So I put a SetFocus in the exit event of the last field to jump to the Save and Close button, user just presses return and all is done. Form footer...
  20. G

    Sub Query, Inconsistent Results

    What is going on with this query to give me these results? The problem column is AcBalance which is giving me garbage or sometimes the right result. Of 130 records I get c.40 with the right result. The sub query qry_gross_value_total when run in isolation give me a correct result with all rows...
Top Bottom