Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Wanet Telecoms Ltd on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Navigations buttons no longer work after a filter

Status
Not open for further replies.

SpyderMan1234

IS-IT--Management
Feb 26, 2004
35
US
I have a straight-forward form. The recordsource is a SQL statement which pulls from two tables using a left join. The recordset type is Dynaset (Inconsistent Updates) so that they user can edit all information in the fields. Now, this form HAS been working perfectly fine. However, I added a new search button to filter for a specific record and once I ran this code, my navigation buttons no longer worked and I couldn't scroll between records or add a new record...clicking them just does absolutely nothing. All 3 filter options in the toolbar are greyed-out. Seeing that I could no longer navigate records, I removed the command button and the code so that the form was the same as it was before I did anything to it, but the navigation buttons will still not work and the filter options are still greyed out. I even tried to change the recordsource of the form to just a single table and not a SQL statement, but to no avail.

This is the code that I used to filter for the record:

Me.FilterOn=False
Me.Filter="File='" & Me.txtCriteria & "'"
Me.FilterOn=True

Anyone have any idea what caused this most-frustrating-for a-Friday-afternoon problem?? Or why it still won't work after changing everything back to the way it was?

Any help is great appreciated!

Thanks
 
I have found that when this type of thing happens, that about 75% of the time I need to create a new database, copy all objects from the current database into the new one, and that fixes the bazzare situation. Remember, 25% this is not the fix. At that point, I have found I did not return EVERYTHING back to where it was. I'm sorry, I have no idea what it could be if yours fits the 25% side.
 
And what about deleting your form and reimport it from your latest DB's backup (You have backups, don't you ?) ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Generally for me, this happens when I'm working on a new form so I have not make a backup of the database in the last 3 or 4 hours. So, no I normally don't have a backup of my form when this has happened to me.
 
I'll try to copy/paste the controls and all into a new form and see how that works. I do have a backup if all else fails. It seems that some setting in the form is not getting reset or something. But I've gone through every property on the form and everything is as it should be.

Thanks
 
I have never found the copy/paste to work. Whatever problem that has happened within the form seems to be copied to the new object. According to Microsoft, something within the database has become corrupt and the only fix is the create new database, then inport all objects from the old (corrupt) database.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top