Search results

  1. M

    OPen a specific file

    Could you copy your code?
  2. M

    BeginTrans, CommitTrans & RollbackTrans

    This was an older article related to transactions, so I will post for future readers. To clarify what Pat has said, transactions commit, or save, the value of many fields at one time. For instance if you were to change a business's phone number and address. Instead of updating the address and...
  3. M

    BeginTrans Rollback CommitTrans withing Access

    This was a while ago, but in case anyone was ever wondering, yes there is a limit. Not on how many times you can use it, but on the number of locks. I believe that the initial lock parameter permits 9500 records being locked at a time per transaction.
  4. M

    Listbox Columns?

    Listboxes may have multiple columns, but the first column is what is used as the "value"
  5. M

    Help with bracketing

    Chr(34) = " You could alternatively use the following: stLinkCriteria = "[CompanyName]=""" & Me![CompanyName] & """" since in program code "" is equal to a displayed "
  6. M

    LDAP ADO Query

    I forgot to mention that *xternal* was a search being performed with two wildcards much like any other SQL. In regular SQL the Where clause would be something like: WHERE userreferencedn Like "*xternal*" *xternal* could be replaced with any other value being searched
  7. M

    Unbound Subform Control

    The best way to handle this is to show you what it looks like and go from there, so please see the attachment. I have a subform used to track machine-part orders. The subform is bound to a table that has: - Part Num (PK/FK) - PO Num (PK/FK) - Paid Price - QTY The Part Num field is a combo...
  8. M

    Avoiding duplicate records

    What Pat is saying, which I agree with, is setting a primary key to those values. In the table. Or index them so that they cannot produce duplicates. Doing the actual validation/verification to assure it's not a duplicate costs your database more clock cycles and time, not to mention it is a...
  9. M

    I need Help with Case Statement

    You can do this many ways. You can manipulate the report's recordsource to be bound to a new query. You can create a report that covers all posibilities and just filter down which "form" to show You could pass values through the OpenArgs Also you can make fields "invisible" when the report...
  10. M

    I need Help with Case Statement

    You can do this many ways. You can manipulate the report's recordsource to be bound to a new query. You can create a report that covers all posibilities and just filter down which "form" to show You could pass values through the OpenArgs Also you can make fields "invisible" when the report...
  11. M

    Query output to emails

    VBA, load a recordset and loop through it. You can send one at a time or BCC them all.
  12. M

    Query

    you can use yoru choice of "m", "mm", "mmm" or "mmmm"
  13. M

    Find which field has focus

    Perfect, yes that is what I was looking for... completely forgot about it. I was using the GotFocus/LostFocus method to store in a variable what had focus, but I'd rather not waste global resources, plus it demands more processing on the pc to call the function every time one of the textboxes...
  14. M

    Find which field has focus

    I have a button that has the ability to change two text boxes, depending on which one has focus. Does anyone know how to verify if a conrol hasfocus? If Me.ControlName1.hasFocus Then Me.ControlName1 = GetValue() Else If Me.ControlName2.hasFocus Then Me.ControlName2 = GetValue() Else...
  15. M

    Paste from Excel Not Firing AfterUpdate Event

    Try using the Change event if there is one, if not then the KeyPress or KeyUp event and see if that does the trick, since a Copy/Paste is a key feature (ctrl+v). AfterUpdate is usually triggered when the control loses focus.
  16. M

    Resetting the primary key

    When you renumber these, you will have to renumber every place they appear in other tables as foreign keys. Your wanting to do this is rediculous, but just create a copy of the table. Delete the primary key field, then recreate the primary key field, then copy the data in.
  17. M

    Split OpenArgs to Multi-Dimension Array

    I really didn't want to use more than one variable (trying to keep it neat) but i used two temp variables to get: Dim args() As String Dim tmp() As String Dim tmp2() As String tmp = Split(Me.OpenArgs, ";") ReDim args(UBound(tmp), 1) For i = 0 To UBound(args, 1)...
  18. M

    Split OpenArgs to Multi-Dimension Array

    My openargs look something like this: "Form=Main;MondayOnly=True;X=2500;Y=800" Dim args() As String ReDim args(UBound(Split(Me.OpenArgs, ";")),1) 'resizes the 4 by 2 array args = Split(Me.OpenArgs, ";") 'correctly puts each section into array '--------------------------------...
  19. M

    Reset Form

    Hey guys, take your time with this - i'm not in a hurry, it's just slipped my mind. I'm reseting the form controls back to their default value. My code is as follows. For Each ctl In Me.Controls If ctl.Name Like "cbo*" Or ctl.Name Like "txt*" Then ctl.Value...
  20. M

    formatting a txtbox within a report via VBA

    Not possible.
Back
Top Bottom