Recent content by GKIL67

  1. G

    Mode function using WorksheetFunction produces error

    Solved. It should be: Function Mode(ParamArray dblNos()) As Double '?Mode(1,2,5,8,12,13,1,1) returns 1. Mode = WorksheetFunction.Mode(Array(dblNos)) End Function
  2. G

    Mode function using WorksheetFunction produces error

    If I use ?WorksheetFunction.Mode(Array(1,2,5,8,12,13,1,1)) it works OK, but the following function gives the Error "Unable to get the Mode property of the Worksheetfunction class". Function Mode(strString As Variant) '?Mode("1,2,5,8,12,13,1,1") Dim VarOut As Variant VarOut =...
  3. G

    Using an Option Group to control a Loop produces error

    Here is the code that produces the Error (attached is the mdb copy): Option Compare Database Option Explicit Dim bnStartStop As Boolean Private Sub Form_Load() bnStartStop = False Me.gStartStop = 1 'STOP End Sub Private Sub gStartStop_AfterUpdate() If Me.gStartStop = 2 Then...
  4. G

    Using an Option Group to control a Loop produces error

    The special about the option group is the visual effect - pressed/not pressed buttons :) jdraw, no doubt that your recommendation works, I've tried it already - still one more reason for me to :banghead: why I can get it done with the option group - WHY I get the Makes no sense...
  5. G

    Using an Option Group to control a Loop produces error

    If I use a Toggle button to control the Option Group, I get two(2) errors, the one I described above and also: "Error 2110: Microsoft Office Access can't move the focus to the control gStartStop." Obviously the two errors are related. However, if I use a use a regular Command button, then it...
  6. G

    Using an Option Group to control a Loop produces error

    ... nothing unexpected is happening! I use the START/STOP buttons so that the user, whenever he chooses, can start/stop the filling of records (a series of calculations) . What I just noticed is that the code works if I use an extra button to change the value of the option group. Of course it...
  7. G

    Using an Option Group to control a Loop produces error

    I have a form with unbound fields and using an option group (gStartStop) with two buttons, Start/Stop, I want to control the execution of a DO WHILE loop where a series of actions are performed, including action queries. Code of the option group: Private Sub gStartStop_AfterUpdate() If...
  8. G

    Recursion or too many records lead to "Not Responding"

    Well, for this kind of job I would go for your CPU - mine is an Atom and that makes a whole lot of a difference... Also, I run memtest overnight and Defrag, but found no errors... Morever, I disabled all visual effects (under mycomputer/Performance/Settings), but still no noticeable...
  9. G

    Recursion or too many records lead to "Not Responding"

    I guess it’s a hardware issue - what I have available for the time being is an MCI N270 1.6GHZ 1GB and I also tested it on an ASUS 1015BX C50 1GHz 2GB. None of them are quite up to the job... The 720 records give me 239 milsecs whilst the 3628800 records anywhere from 436951 to 1529083...
  10. G

    Recursion or too many records lead to "Not Responding"

    Thank you Chris for straightening my code up... :banghead: The message "Not responding" still appears and the screen appears "hanging", however the table gets filled correctly, after about 15min. I tried to insert the DoEvents in several places and it does make a huge difference, no message...
  11. G

    Recursion or too many records lead to "Not Responding"

    Using Access 2003, the following snipset produces 3.628.800 records. It is actually a permutation procedure, in this example, call GRListWords("", "ABBREVIATE", 10) 10 letters to form all possible words in groups of 10 letters. My problem is that I can not get them into a table - execution holds...
  12. G

    Passing a boolean operator string to a stored query

    Solved by following spikepl suggestion above, thanks! 1. Put in the design grid of the query something like: [Forms]![Form]![txtField] 2. Then use a sub/function like: Sub dummy Dim dbs As DAO.Database Dim qdf As DAO.QueryDef Dim stDocName As String Dim strSQL As String, strWHERE...
  13. G

    Passing a boolean operator string to a stored query

    jdraw, The "6 OR 8 OR 10" means to restrict the values of the records to those that contain 6 OR 8 OR 10. But these numbers could change either in value or in amount of ORed numbers together.
  14. G

    Passing a boolean operator string to a stored query

    Just to make it clear... Lets say that there are like 10 numbers to be ORed, that means to build a WHERE clause that keeps on repeating (loop) something like: strSQL = strSQL & " OR myfield = " & me.myfield.Value Please advise, Thanks!
  15. G

    Passing a boolean operator string to a stored query

    I have a stored query. I want to run this query via a button from a form and pass a boolean such as "6 OR 8 OR 10" that is in a txtField on the form. So, I put in the respective field - in the design grid of the query this: [Forms]![Form]![txtField] and in the button: DoCmd.OpenQuery Query...
Back
Top Bottom