Search results

  1. G

    Solved Sequential numbers

    I'm kind of wishing I hadn't linked the article, yes it's old but it's something I discovered as an Access beginner and it seemed to fit the bill. The dbDenyRead was a kind of 'ah-ha' moment. Does no-one use this? The issue of duplicated Autonumbers mentioned in the article is really a red...
  2. G

    Solved Sequential numbers

    I may have misunderstood your original question. Almost all of my tables have meaningless autonumbers. as keys. Some have natural keys. But I don't use autonumbers for any business purpose. Just as an aside, I have a table with a natural key which turned out to be a mistake, not because I...
  3. G

    Solved Sequential numbers

    I adapted this code. You can code it to have any kind of prefix/suffix you like. You need a table to maintain the last picked number for each document type. Built for multiple users but my implementation doesn't test that. What it doesn't do, is recover the number for a deleted record. In...
  4. 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...
  5. G

    Greatest ONE LINE in a song ever

    It would have to Born Under A Bad Sign. But as a folk guy as well some of Ewan MacColl's lyrics are priceless.
  6. G

    Greatest ONE LINE in a song ever

    And when he died, all he left us was alone I once loved a maid, a spot welder by trade If it wasn’t for bad luck, I wouldn’t have no luck at all you keep lyin', when you oughta be truthin' Look pretty young but I’m just backdated
  7. G

    Build query from form

    Wow. You guys have just described what I'm polishing off right now. tmyers, I have more or less exactly what you want and I’m preparing it for upload here (some days, a week, maybe). However it builds from queries, not tables, so you would build a query for each table and use that instead...
  8. G

    On No Data

    Keep what you have shown in post #8 in the report code module. Or, it may work with Allen Browne's public routine, I don't know for sure. Change your command button code to this: Private Sub cmdOutstanding_Click() On Error GoTo cmdOutstanding_Click_Error DoCmd.OpenReport "rptAllInvoices"...
  9. G

    CBOOL does not affect return db Data Type in query

    I'm building a generic query builder where I feed it a base query, and for each query field I populate some combo boxes according to what can be done with the field. So for a numeric type, the combo shows options Equals, Between, Greater than, etc etc. The idea is that for Boolean types...
  10. 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...
  11. G

    Label Caption In Data Sheet

    Do you mean you want to change the datasheet column headings? This works for me (A2016) where text2 is a datasheet textbox. No labels on the form just the text boxes. Me.Text2.Properties("DatasheetCaption") = "SomeText"
  12. G

    32 bit references running on 64 bit Access

    I don't know if this is a universal fix but try this: For the declaration of the interface function or sub, where it says (eg) Private Declare Function FunctionName () as long or whatever, change it to Private Declare PtrSafe Function FunctionName () as long To code the job properly I think...
  13. G

    Modal Pop-up can't be set Visible

    Ranman256, I think you've got me on the road to recovery. Actually I was setting stuff in the Modal form, as long as the acDialog form was opened first. So maybe it only had the right 'Modal' priority then. But once it was already open and hidden, re-opening the acDialog form maybe then took...
  14. 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...
  15. G

    Record won't delete using db.execute

    Here's an article about transactions in bound forms: How to use transactions in Microsoft Access VBA - Codekabinett I haven't tried it largely because of the warning against user input within a transaction.
  16. G

    Strange Gremlin in Search Field

    Don't think you've put the code suggested by Shanemac51 in the right place. Post #26, get rid of your new code that starts 'New Sub routine to convert ANSI to character string In the search form properties sheet, select the search field and click the ellipsis (...) On Key Press event. Pick...
  17. G

    Problems With Office Version 2201

    This fixed it for me. Perpetual Access 2016. I was on build 14827.20158 but this link reverted to 14701.20206. Lock file no longer remains on closing Access. Link: Lock File Problems with Access 16.0.13801.21086 - Microsoft Community The reply 4th February listing 5 steps to download...
  18. G

    Solved Form-specific codes in reusable class modules

    This (the save error, not the class module) might be something that an Access less-than-expert can answer. I too have ancient non-event driven coding experience. You've coded some stuff that is still beyond my skill set but you are experiencing the same relatively simple issues that I did, so...
  19. G

    Solved Determine Column Width in Datasheet View

    This works for me in a datasheet: Public Function cm2twips(cm As Variant) As Integer ' returns the twips for moving and resizing a form from a metric input Const TwipsPerCm = 567 cm2twips = cm * TwipsPerCm End Function Testing: Me.txtDescription.ColumnWidth = cm2twips(6.5)...
  20. 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...
Back
Top Bottom