Combobox misbehaving (1 Viewer)

John Sh

Member
Local time
Today, 12:55
Joined
Feb 8, 2021
Messages
463
In the PWChange form, if I type in a name I can change the password.
If I try to open the dropdown list the form shuts down.
There is one name in the table, "Me" and the password is "g"
Running compact and repair has no effect and compiling the code returns no errors.
For ease of checking I have set the password as plain text.
 

Attachments

  • PWChange.accdb
    1.4 MB · Views: 21

Josef P.

Well-known member
Local time
Today, 04:55
Joined
Feb 2, 2023
Messages
898
What is written in the code is executed ;)
Code:
Private Sub cboLogin_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If IsNull(Me.cboLogin) Then closeIt
End Sub
 

John Sh

Member
Local time
Today, 12:55
Joined
Feb 8, 2021
Messages
463
What is written in the code is executed ;)
Code:
Private Sub cboLogin_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
    If IsNull(Me.cboLogin) Then closeIt
End Sub
I've no idea where that came from.
That module was working correctly up until recently and suddenly started acting up.
I have had a series of strange goings on lately but this is almost as crazy as the query that suddenly had two "B's" in in the name. Qbox became QBBox and this in that same module.
I thank you for spotting this.
John
 

GPGeorge

George Hepworth
Local time
Yesterday, 19:55
Joined
Nov 25, 2004
Messages
2,090
Do you have an assistant who helps edit your code when you're not expecting it?
 

GPGeorge

George Hepworth
Local time
Yesterday, 19:55
Joined
Nov 25, 2004
Messages
2,090
Actually, yes. He's called msaccess.
Touché.

I was suggesting that perhaps a name change to an object was the act of someone other than your self who edited your accdb.

Obviously, a line of code in a Sub that you didn't recall creating could also suggest someone else added it.

Is this the master copy of the accdb? Or a development copy?
 

John Sh

Member
Local time
Today, 12:55
Joined
Feb 8, 2021
Messages
463
Touché.

Is this the master copy of the accdb? Or a development copy?
Yes and Yes.
I work on this copy to correct any bugs and then convert to accde for distribution.
I am the only person with any coding ability and the external drive, with everything on it, goes with me only.
That said, it would seem that the only culprits can be me and myself but I am not generally in the habit of breaking things that are working as desired.
I have spent the last week correcting a number of modules that were working fine and suddenly stopped working.
The only explanation I can come up with is that I have crossed over some code from a backup.
I have just completed a rather large task that entailed changing table names to agree with the relevant form names. A lot of work at the time but should ease the maintenance in the future.
The accde file is 35MB and the split DB is 47MB so plenty of text for typo's
 

GPGeorge

George Hepworth
Local time
Yesterday, 19:55
Joined
Nov 25, 2004
Messages
2,090
Thanks. I'll have a look at it..
I'm going to post another oddity this afternoon, concerning a split table acting like a query???
When you do, please provide enough details to explain what you mean by "a split table"and "acting like a query".
 

John Sh

Member
Local time
Today, 12:55
Joined
Feb 8, 2021
Messages
463
When you do, please provide enough details to explain what you mean by "a split table"and "acting like a query".
I've just posted it under "What The??"
I think the images will tell the story better than words.
 

Users who are viewing this thread

Top Bottom