Disabled Breakpoint Continues To Stop Code
Aug 15, 2014
I had to put a breakpoint into my VBA code in one of my apps to debug a problem I was having and inspect the variable values. All was well until I finished the debugging process and tried to eliminate my breakpoints. However, the next time I ran the application, the code stopped as if one of the breakpoints was still active. I closed the application and reopened it (even rebooted the computer) and the code continues to stop in the same spot in the program. The only thing I can think of to do is to create a new empty Access database and import all the objects from the old one. I'm thinking the database must be corrupt and this is all I know to try.
View Replies
ADVERTISEMENT
Nov 29, 2006
Ok - really need some help here. I have searched and searched but i think my problem is slightly different to the ones i am finding.
Basically i have a form and i want to force users to fill in one out of 4 tick boxes. If none of them are ticked when they press the close button i want the form to stay open and a message box come up.
I can get the message box part to work but the form still closes down.
The reason for this is that when the form closes it goes to another form that is linked to it by a unique ID number. This works by the following code.
Private Sub BTN_INVIS_Click()
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frm closure"
stLinkCriteria = "[issue ID]=" & Me![Issue ID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_BTN_INVIS_Click:
Exit Sub
Err_BTN_INVIS_Click:
MsgBox Err.Description
Resume Exit_BTN_INVIS_Click
End Sub
What i have tried to do is insert a piece of code into the above to generate the message box so it now looks as follows:
Private Sub BTN_INVIS_Click()
If [Transport_Delivery_issue_] = False And [Process_issue_] = False And [Design_issue_] = False And [Supplier_issue_] = False Then
MsgBox "You must complete the liability box before you can close this issue"
Cancel = True
[Design_issue_].SetFocus
End If
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "frm closure"
stLinkCriteria = "[issue ID]=" & Me![Issue ID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_BTN_INVIS_Click:
Exit Sub
Err_BTN_INVIS_Click:
MsgBox Err.Description
Resume Exit_BTN_INVIS_Click
End Sub
This code checks the boxes and generates the message box if none are ticked - that works great. However it doesnt stop the second part of the code (the move to the next form) from executing if the boxes arent ticked.
Would really appreciate it if someone could help me - i'm fairly new to coding so the whole database is a bit cobbled together (mostly with help from this forum!).
View 3 Replies
View Related
Jul 3, 2013
I have an excel file, and am trying to import it, and once when I have imported it, am checking for a condition with While Not rs.EOF, it works fine for the purpose of looping, but it does not stop when the records are over., it is additionaly printing 19 null statements, where I beleive it, should not be.
View 9 Replies
View Related
Sep 4, 2013
I have an order form that auto-populates details from the customer table into adderss and contact controls. But I don't want it to auto-populate when the underlying order table already has data in the related fields. Here is the code I use on Load form event...
======
Private Sub Form_Load()
'Use this version if the ID is a number
Dim x As Variant
Dim strControl As String
Dim lngID As Long
'If parameters exist, use them
If Len(Me.OpenArgs) > 0 Then
[Code] ....
View 2 Replies
View Related
Apr 19, 2013
I have a report with 2 subreports on it. One of the subreports does not show on the report preview unless I set a breakpoint in the report's code. Set a breakpoint in the code (for no other reason), hit the breakpoint, continue, and the report works fine from then on, until you close the database and open it again, even if you remove the breakpoint. The other subreport, which is similar, always shows fine.
I can't find out what's wrong by setting a breakpoint.
View 1 Replies
View Related
Nov 9, 2005
My table has been corrupting every week and there is only 2-3 people using it on a consistent basis. It will work fine to add new records for a couple of days then they will receive the "duplicate record" error message and it is trying to assign an autonumber that is already being used in the table.
It seems to be picking a random record to restart the autonumber with. I tested it by trying to add a record-it would assign id# 1068 (which is already used) I would get the error, get out, go back into the table and add another record and it would try to assign it #1069 and so on. When it got to a number that wasn't in the table #1071, it would allow the record then. It continues to go through this process, error-ing on id#1072. The record it starts with doesn't seem to have any bad data.
Does anyone know what would cause this to keep happening? I do have another table that ties the id #'s to this first table. When I move records from the first table into another one, or delete them completely, I haven't been removing the data from the second table. Could this cause a problem?
I would appreciate any help with this. I'm am currently working to get a SQL backend done in hopes this will solve these corruption issues.
Thanks,
Toni
View 3 Replies
View Related
Jul 26, 2005
Hello from Greece.
I have a little problem. Let's say I have a Tubular (Continues) Form with these Textboxes (assigned to fields in a Table Customers) :
SerialNo Name Date_Of_Birth Value
1 Theodore 9/12/76 5
2 Theodore 9/5/70 6
3 John 4/4/90 3
4 Maria 7/4/90 2
5 Anna 12/5/05 3
Then I apply filters (By right clicking and filter by selection). Let's say multiple filters for Name and Date_Of_Birth.
Is there any possible way, after the filtering, to have the Sum of the Value of each record (filtered Continues form) in a seperate textbox?
Thank a lot ...
View 5 Replies
View Related
Jul 29, 2013
Form info
1st Form Name: Mainform
Text to enter employee ID : empid
Sub form within Mainform: SFTimesheet (continues form)
text to enter: Timein, Break, Timeout
SFTimesheet shows and accept entries for each employee called using the text empid, on the mainform
I wanted the subform to show 7 days /lines starting from Sunday to Saturday of current week and dating the text "Timein" accordingly. When employee enteres an entry on the 7th Line, it should give them a new 7 lines for the new week to begin.
View 5 Replies
View Related
Sep 22, 2004
PROCESS AS DESIGNED: The user logs in and is given a form displaying existing records that are coded (by userid) for that user to update. From that list, the user selects a record and continues to a second form (the first form closes) which displays all the fields of the selected record which should/can be edited by the user (plus a few non-editable key fields). There is nothing tricky to how the records are selected for display. A simple query behind the first form selects data records using the userID number. The second form does a simple record select using the active record ID number on the first form. Nothing tricky -- no modules just queries, tables, forms and simple macros to string it all together.
The user can open/close these two forms as often as necessary and the record will continue to show up until a value is entered into a "completion date" field. When that field is no longer blank, the record will no longer be displayed for use.
PROBLEM: About 90% of the time, things work as expected. But 10-15% of the time, somewhere between opening the record in the second form and closing the second form, the edited record totally disappears (as if it were never opened, it isn't even system date stamped) and the input information is inserted instead into a brand new record.
Users can sometimes tell when the edit record is dropped during processing, because key fields displaying previously entered data go blank and the displayed recordID (autonumber) is changed. p>
ERROR PATTERN: NONE! It can happen as the edit record is first opening, in the middle of editing the form, or at the end when closing the form. It will happen on a specific PC 2 times in a row and the third time be fine. It has happened at multiple locations but not for all people and not consistently for the same person/same pc. The same record that failed can be re-selected and work just fine the next time.
I cannot reproduce the error myself. I have tested everything I can think of without causing the error. I can lose changes and avoid a system date stamp if I abort my Access sesssion, but that doesn't create/insert a new record with my new input. It just loses everything.
I have wondered if a momentary break in the network/communications could break the connection to the application to just enough that the form remains on the screen, but selected record is discarded. Input into the empty form would/does insert a new record.
I have asked the IT Operations group to investigate if a network/communication problem could be the culprit, but they haven't gotten far on this. I have never seen this happen before and am totally stumped but am desperate to resolve it before user confidence is damaged.
View 1 Replies
View Related
Feb 26, 2007
hello,
I have this filename.mdb file which was given to me for revision, so I opened it with MS access but once I opened it, the toolbars are disabled so I can't switch to form view, design view etc. How can I resolve this? I remember when I once did VBA Access that you can do this 'disable' thing. Only that I forgot it how now. So if anyone could please help me in this? I need to 'have those toolbars back' so I can start editing the file. Please do help me.
Thanks in advance
View 2 Replies
View Related
Dec 17, 2006
Hello,
I have created a log in form in my database and users will enter their name using a combo. Is there a way I can force them to use the mouse and select their name and not type in the data? Basically something that will disables all keys from the keyboard? Thanks.
View 3 Replies
View Related
Feb 9, 2008
The # character in a hyperlink is used to separate hyperlink parts. Here is a case when I do NOT want this character to do the separation: a network file where the # character is part of the filename: k:datasomeFile#ref02.doc.
How can I put this URL into a hyperlink field in a table and NOT have Access treat it like this:
Address: k:datasomeFile
Subaddress: ref02.doc
which then of course results in the usual "Unable to open..." error.
(I tried replacing the # with %023 but when Access seems to convert it automatically to #).
View 3 Replies
View Related
Jun 10, 2005
I'm creating an Access form and there are three sections to the form of which the user should only fill out one. So, they are controlled by a radio group and the desired action is as follows:
There is a default choice (by far, the most common) and it will be selected when the form is opened. When the user selects one of the radio options, the section controlled by that radio option will become enabled and the other two sections will become disabled/locked.
So I found that each box (textbox, combobox, etc) has the property enabled and locked. So I just set this accordingly depending on what is selected. The actual result is that the boxes will be grayed out and become disabled, but will never become enabled again.
Here's some abbreviated code:
Private Sub accountRequestType_AfterUpdate()
If Me.accountRequestType.Value = 1 Then
enableSection1
disableSection2
disableSection3
ElseIf Me.accountRequestType.Value = 2 Then
disableSection1
enableSection2
disableSection3
ElseIf Me.accountRequestType.Value = 3 Then
disableSection1
disableSection2
enableSection3
End If
End Sub
So an example of a disable function (which seems to work) is as follows:
Sub disableSection1()
Me.text123.Enabled = No
Me.text123.Locked = Yes
End Sub
And for an enable function (which doesn't seem to work):
Sub enableSection1()
Me.text123.Enabled = Yes
Me.text123.Locked = No
End Sub
So I'm a bit lost here, any ideas would be great. Are there different steps I need to take in order to enable them again? Am I being clear?
Thanks in advance for any ideas.
View 2 Replies
View Related
Dec 15, 2005
Hello,
How can you disabled a click event on a text box ? I don't want to use ENABLE = false because the background of the texte box comes gray. So, any alternative solution?
Thanks,
Le
View 6 Replies
View Related
Oct 13, 2006
Can I make a button, say "command01" deactive by clicking it.
i.e.
OnClick of command01 => command01.enabled=false
is this possible?
View 5 Replies
View Related
Jan 22, 2015
I have an mdb file that is being used in Access 2013. The menu appears in the Add Ins as it is supposed to and it works for the most part. For some reason, it remains visible but is not clickable/operable after I do the following code. This all works flawlessly in earlier version of Access so it must something peculiar to 2013 (no surprise there....). hat would cause the ribbon to stop working, what to do when it does, and best of all, how to prevent it from occurring in the first place?
This code is for an option box that either prints a report or creates a pdf and then sends the report as and attachment to a CDO generated email. Other than it (seemingly) turns off the menu..THe site won't allow me to post links so the code is an attached txt file
View 2 Replies
View Related
Apr 19, 2007
I disabled all the menues in the startup....how do I reverse this?
View 3 Replies
View Related
Jul 2, 2007
Hello,
I have a 'legacy' Access DB which I need to get into.
Unfortunately there is a problem, whenever I try to open it (using MS Access 2003) there is an error (Disc/Network error 3043) and the database closes immediately.
How can you open an MS Access db with all macros/vba etc disabled, so that the code causing the error does not execute and I can find out what is going on ?
I have not been able to find any such options in the MS Access 2003 open dialog or menus.
Thanks,
Andrew
View 5 Replies
View Related
Jun 30, 2005
Hi all,
I have a frmUserLoginScreen that opens frmMainSelectionScreen, which has 4 command buttons on it. Dependant on user level, some of the command buttons are disabled.
I have four user groups, manager, admin, IT and guest. When the guest logs on, the frmMainSelectionScreen only has one command button enabled. Once clicked, this opens frmClientDetails which has a command button that enables the user to add a record.
Basically, I want the add record command button to be disabled on the frmClientDetails if the user is a guest.
I've tried all sorts of code to reference the other forms but I'm not having any luck. Has any kind fellow got any ideas?
Thanks
View 7 Replies
View Related
Sep 27, 2004
Hey guys - I am creating a fake webpage looking database in MS Access Project. On the form I am using labels with hyperlinks that directs the current focused label to do something. I have user rights in my database, and depending on perimissions, i want to disable a lablel like you can do a textbox. I am trying to duplicate a disabled textbox with label look. My coworker had a procedure in API that allowed you to pass a control or label in it, and it will give it the disabled look. Problem is, he lost it can someone help me please. I don't want to go back into my system and change everything over to command buttons or textboxes.
Any help would be appreciated..
View 5 Replies
View Related
Mar 19, 2007
Hi,
I opened the relationship window to do the relationships among my tables; however, the check box 'Enforce Referential Integrity' is disabled. I don't understand why is that? And is there anyway to change it?
Also, where should relationships be implemented? is it the FE or BE?
Any help will be very much appreciated.
B
View 14 Replies
View Related
Sep 24, 2012
I have an Access 2003 db being used through Access 2007 in order to use user-based security.It is a spit db with the be being on a shared server.For some reason, the security login has been deactivated after working fine for over a year. The user goes right to the autoexec macro file without having to log in.
They are also getting a "Read-Only" message at the top about only being able change table in linked tables.The DB is configured to utilize the logon as a parameter in some queries.
View 6 Replies
View Related
Dec 6, 2012
I need to modify the access 2010 database. But when I open it the navigate pane of that database is disabled. How to make it enable?
View 2 Replies
View Related
Oct 10, 2014
I don't know, I have noticed that the SETVALUE argument is not openly available in the lookup tables when setting a macro. (But that aside) I have set my drives c: and d: as trusted, and also thicked the sub folder option.
View 7 Replies
View Related
May 2, 2015
I'm using a dropdown that has the months of the year in it. The user selects a month and the form is then filtered by a date if its the first of whatever month is selected. It works fine but when the filter is applied I cant select the little arrow on the column headings and select the boxes (Select All, Blank, ETC...). It doesn't work on any column, just the apply text filter works but I cant select anything.
It works fine when I clear out the filters on the form. I tried to use vba to set the menusetting property to true and that didn't work either.
View 1 Replies
View Related
Jun 20, 2014
I've got some forms that I've set to lock controls based on an added tag. I have a loop that goes through the entire form and disables (controlname.enabled = false) or locks (controlname.locked =true) all the controls with that tag.
This appears to work fine when the form is on a blank record but when an existing record is opened, the controls that have data in them are no longer locked or disabled (empty controls are still locked). Is there an explanation for this behavior? I don't want to disable the entire form because there are controls that I want the user to be able to always access. I started by just disabling them, then when I noticed the problem I tried locking them instead but it happens with both. Is there another property I can try that will really lock them if they have data in them or not?
View 1 Replies
View Related