Search results

  1. J

    Converting One Record Into Multiple Records

    I had a similar issue where I wanted to derive an intraday coverage graph by hour given someone's shift start time and end time. These types of issues I always try to solve via query rather than VBA, if possible. I would make 2 seed tables: list of months (1 - 12), list of years (some range...
  2. J

    need some help is there a better way

    I'd try to tidy it up a bit: Dim strControlName(27 to 52) As String Dim ctl(27 to 52) As Control Dim booPassed As Boolean Dim i As Integer For i = 27 to 52 'I'd have to wrestle with this to get it to work - might need to use Eval strControlName(i) = "read" & CStr(i) set ctl(i) =...
  3. J

    Microsoft Access Has Encountered a Problem

    Sorry to hear about the degree of complexity - This post addresses some of those limitation issues. But now that you're being confronted in earnest with a re-design, you may want to consider working from the ground up and conceptually rework an efficient data model and table structure (i.e...
  4. J

    Microsoft Access Has Encountered a Problem

    You may dread doing this, but have you tried starting from a blank form and copying over the controls and code into that (including blank start-overs for your subforms)? It may or may not have anything to do with the Access crash you're running into, but I know there's a limit to how many...
  5. J

    option group

    Hello and Welcome! Depending on your circumstances, you can create/keep a "Lookup" table - the values 1,2,3 & 4 will be the Autonumber field. Your names pertaining to each option will be the myOptionName field. Then you link this table with your main table in the query. Apart from a Lookup...
  6. J

    Select entire contents of Combo Box

    You might want to consider (perhaps at this point for any future time-editing app) to use a Spin Control in conjunction with a text box . . . I'm doing that right now with one of my apps and it seems to work quite nicely - that way the user doesn't fuss at all with the direct time-string, and...
  7. J

    Select entire contents of Combo Box

    Hi Brett, Seems another poster has run into the same issue My other thought is that you might want to experiment with the cursor behavior in the Options menu. Or, further to the suggestions from the other post, maybe try using an event other than GotFocus . . . Regards, John
  8. J

    Select entire contents of Combo Box

    Just hazarding a guess here - I'm usually suspicious of combo box references that don't include the .Value property So if possible, I'd try to pop it in your Len expression just so the content is explicitly pointed to. Hope that helps. Regards, John
  9. J

    Consolidation of Permutation combination code

    Hi Bob, Not of my making, but mathematically speaking, it's pretty straightforward. Here's a link to a factorial function put together by Marshall Barton. Regards, John
  10. J

    Consolidation of Permutation combination code

    Hi Adam, One thought is that your permutation model is based on a factorial. So recursively speaking, the number of permutations can be represented as: Factorial(PlayType) = PlayType * Factorial(PlayType - 1) The tough part though is that you need to interrogate each element of your...
  11. J

    Combine multiple rows into one cell

    You might need to pop a semi-colon onto the end of the SELECT statement: "SELECT ... ORDER BY OrgID, OrgRef;" Otherwise, double-check that your tables have the correct field names. OrgTable is your source table, tbl_OrgBundled is the table you're writing to. If this all checks out, then...
  12. J

    Report shows number instead of lookup item

    Hi Jack, That's a good sign you're using the "Foreign Key" values (numbers) to populate your main data table. When it comes time to display your data in a report or form, then you'll need to reconnect ("join") the 'Foreign Key' field in your main data table to the corresponding 'Primary Key'...
  13. J

    Filtering a query

    Hello and Welcome! And let me congratulate you on your move from Excel to Access :D To address your issue, I'm assuming you're using a form to populate your Mining table. (But if the combo you speak of is in the table itself, I recommend in the strongest terms to get rid of it - don't do it...
  14. J

    Combine multiple rows into one cell

    You're welcome and glad to hear you've got something setup and working in the meantime - I'm afraid any way you dice it, it's gonna be a lengthy proposition (including what I posted), but if it works and gets the job done on time, then everyone else is happy I suppose :) Anyway, all the best...
  15. J

    Count total fields in a record with null values

    Hello and Welcome! First, concerning your Duplicates situation, it sounds like you don't have a Unique ID to represent your Contacts (i.e., EmployeeID, etc) - but you may want to consider if there are a combination of elements which uniquely identifies each Contact (i.e., First and Last Name in...
  16. J

    Cross tab month/year headers not in the correct order

    Have you tried: Format([myDateField],"yyyy-mm")
  17. J

    Combine multiple rows into one cell

    Apologies for not getting back sooner - it's been a busy week where I really had to concentrate on a couple things . . . Anyway, first you'd build a table, let's call it: tbl_OrgBundled Give it the following fields: OrgID (presumably "Number" data type) OrgRefBundled (use "Text" datatype)...
  18. J

    Average Fields and Null Values

    Hi hotrodsue, I agree with the last part of the quote you refer to: you should seriously consider restructuring - i.e., "normalizing" - your table(s). The problem you're attempting to overcome is indicative that your data structure is flawed. The use of the repeating groups (3 numeric fields...
  19. J

    Combine multiple rows into one cell

    Hello and Welcome! Well you've started with quite a poser :D Unfortunately, what you're asking Access to do is not within its capabilities if you're trying to do this entirely with queries. At the very least, you would have to create a custom function and combine it with a query to produce...
  20. J

    Object Required Error

    Did you try removing the parentheses from the MsgBox statement? MsgBox "The Phone Number is Incorrect" With parentheses, I believe Access interprets the statement as an expression to be calculated (i.e., as part of an 'If' statement) Hope this helps John
Back
Top Bottom