Text fields lock up

Core

Registered User.
Local time
Today, 11:08
Joined
May 27, 2008
Messages
79
I have a form with text boxes (I'm great I know)

However they are often locking up (cannot get focus and type in them), it seems if i click on some other text boxes then click back in the locked up one it lets me in... not sure what the issue is.

Any idea what it could be? It does not happen on any other forms.

Regards,


---

code:

Code:
Option Compare Database
Option Explicit
Dim msgAnswer

Private Sub Command107_Click()
search.Visible = True
TabCnt.Value = 0
Course.Visible = False
End Sub

Private Sub Command98_Click()
If Programme <> "" Then
    Course.Visible = True
    TabCnt.Value = 1
    search.Visible = False
    cCODE = CourseCode
    cTITLE = CourseTitle
    Prog = Programme
    Exit Sub
Else
    msgAnswer = MsgBox("You have not selected a Programme, do you wish to continue?", vbQuestion + vbYesNo, "Please check")
        If msgAnswer = vbNo Then
            Exit Sub
        Else
            Course.Visible = True
            TabCnt.Value = 1
            search.Visible = False
            cCODE = CourseCode
            cTITLE = CourseTitle
            Prog = Programme
        End If
End If
End Sub
Private Sub Command109_Click()
On Error GoTo Err_Command109_Click


    If Me.Dirty Then Me.Dirty = False
    DoCmd.Close

Exit_Command109_Click:
    Exit Sub

Err_Command109_Click:
    MsgBox Err.Description
    Resume Exit_Command109_Click
    
End Sub
Private Sub Command110_Click()
On Error GoTo Err_Command110_Click


    If Me.Dirty Then Me.Dirty = False
    If STARTDATE <> "" And ENDDATE <> "" And FUNDING <> "" Then
        Me.ID = OpenArgs
        DoCmd.Close
    Else
        MsgBox "You must enter a start date, end date and funding stream before adding a course.", vbOKOnly, "Course Information Incomplete"
        Exit Sub
    End If
    

Exit_Command110_Click:
    Exit Sub

Err_Command110_Click:
    MsgBox Err.Description
    Resume Exit_Command110_Click
    
End Sub
Private Sub Command121_Click()
On Error GoTo Err_Command121_Click


    If Me.Dirty Then Me.Dirty = False
    DoCmd.Close

Exit_Command121_Click:
    Exit Sub

Err_Command121_Click:
    MsgBox Err.Description
    Resume Exit_Command121_Click
    
End Sub

Private Sub Form_Close()
Forms!frontend!Learndirect.Form.Requery
End Sub

Private Sub Form_Load()
DoCmd.GoToRecord , , acNewRec
End Sub

Private Sub txtSearch_Change()
txtSwap = txtSearch.Text
TITLE.Requery
End Sub
 
Check what the default property settings are for the fields when the form opens. Also check for any events that unlock the fields on other text boxes on your form.

Remember, Access will only do what you tell it to do.

David
 
Check what the default property settings are for the fields when the form opens. Also check for any events that unlock the fields on other text boxes on your form.

Remember, Access will only do what you tell it to do.

David

Yeah I understand. I have gone over the code and the settings I just cannot seem to find anything. The boxes are not set to locked and there is no code that sets them to locked.

I am at a miss with it.
 
Can you post a sample of the mdb?

Okay here is a sample of the form and related tables.

Edit: Before I started this project I didn't know a lot about Access/VBA so please ignore the poor commenting/naming/sloppy code etc etc :((

Regards,
 

Attachments

Last edited:
When attaching a copy of your database, please state that it is in v2007 format. People not running 2007 are still in the majority, and downloading the attachment is a complete waste of time for them.

I think you're in luck in that I believe Dave does happen to run the Holy Terror!:D
 
Sorry MissingLinq, I don't, not at work anyway. I have it on my laptop at home for certain situations.

David
 
I knew you'd answered something about 2007 as if you had first hand experience, unlike many of us!
 

Users who are viewing this thread

Back
Top Bottom