User Profile

Collapse

Profile Sidebar

Collapse
billw1100
billw1100
Last Activity: Apr 28 '15, 08:08 AM
Joined: Jul 12 '14
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • Thanks NeoPa for your suggestion, but prefixing the form name with "Form" isn't necessary for me because I always start my form names with "frm".

    Thanks MTB. KIS principal wins again :) I don't even recall how I ended up with Me.Module.Name originally (copy and paste I expect).

    As you might have guessed, I am fairly new to VBA programming, so please excuse me if I ask dumb questions in the future...
    See more | Go to post

    Leave a comment:


  • Now it makes total sense regarding the modules.

    I've defined a constant for each form and it works fine now (less lines of code than before).

    Thanks very much for your quick advice.
    See more | Go to post

    Leave a comment:


  • I've found the offending line of code:
    Code:
    strModName = Me.Module.Name
    It seems that Me.Module.Name works fine in accdb, but not in accde format. I have no idea why it should be different (but it would be nice to find out).

    I need to know the module name so that I can include it in my error table.

    As a work-around, I can manually type in the module name for every sub, but if anyone knows another way to programmaticall y...
    See more | Go to post

    Leave a comment:


  • After a lot of good old "trial and error", I've nailed the problem down to the error code (if I delete the error code lines, it works OK).

    I will try to limit it down further, then post another message.

    The thing that is really concerning me is: why does it work in accdb format, but not in accde format?
    See more | Go to post

    Leave a comment:


  • Sorry about that. Here is the code.

    Code:
    Private Sub UserName_DblClick(Cancel As Integer)
    
    'On Error GoTo Err_Handler
    Dim strModName As String
    strModName = Me.Module.Name
    
        If (Form.Dirty) Then
            DoCmd.RunCommand acCmdSaveRecord
        End If
        
        'Opening Argument at end of following command is used to show/hide some buttons on details form
        DoCmd.OpenForm
    ...
    See more | Go to post

    Leave a comment:


  • Errors with VBA Code in Class Objects in accde database

    Hi, this is my first post here, so I hope I'm doing it right.

    After converting an Access 2007 accdb database to accde, the vba code in my modules runs OK, but the code in my class objects (forms) wont run. In these cases, I always get the error message "The expression On Dbl Click you entered as the event property setting produced the following error: Can't perform operation since the project is protected" (or something similar...
    See more | Go to post
No activity results to display
Show More
Working...