I found the solution. Sort of a gotcha: In Form2 (non-working) I had set the form filter to True (Yes), so that the form opened (without code) to filter to Yes. Once I removed that the form worked fine. So there is a wierd interaction between the compiled form filter and the switchIndex()...
No values are being assigned. The field already has the values (showing "Yes" or "No" in the format of the logical field). As an interesting side-note, I could not interactively create the index (Logical,String,String) and had to use a script to CreateIndex from an array...
Here is the code on the Pushbutton. The field object is called "Current".
var
ui uiObject
endVar
ui.attach(Current)
if ui.switchIndex("CurrentStudent") then
else errorShow()
endIf
The error occurs directly on the switchIndex command.
I am having the same problem, but with a twist. I have two copies of the same form, with some minor changes in code on some objects. There is a pushbutton to ui.switchIndex() which is the same on both. On Form1 the code works like a charm and the subsequent ui.setGenFilter(dyn) works. But on...
Cool idea! I already had a tabbed form, so this was easy to do (how dumb am I that it wasn't obvious!). The added benefit here is that you still have excellent code control over other actions on the tableframe. Thanks.
I have received a request to enable tableview from a form, but I would like to allow only viewing and a return to the formview. I have told the user to use interactive filtering, but they insist on being able to view similar to an Access table. Is there a way to keep Pdox from spawning a new...
There could be a difference in the field type (e.g. Number vs. Short or Long Integer). We can't see your query, so save the query and post the resulting text file (Query.qbe) so that it can be better analyzed.
Access does some things well, but is quite inscrutable, and you have to write much longer code than in Paradox. Paradox makes a very robust front-end, and has the added ability to work with both SQL tables and local (PC type)tables. I would also say that once you try to move to the "next...
How can you set the filter for when the form opens? In Paradox OPAL there is a method open(), but I can't find this in Access (97). Also, if you place fields individually in the detail record, it doesn't appear that there are any update type methods available (I get only mouse related events)...
Actually, CurrentUser returns Admin, which I believe is the Access default login. The network user name is returned by the Environ("UserName") code. Now, how do I put this at the record level (as opposed to the field level) when I've placed a bunch of fields on a data entry field? I...
Why not create a query that inserts the month for each copier in the master table? Thus you have a child table with Copier# + MonthEnd as the primary key.
Is there a built-in function that returns the network log-in name? I am using Access 97 and want to put the username in the table whenever a record is changed.
Is there a way to get a drop-down list of the valid entries for a field? I'd like the drop-down arrow to appear when the user lands on the field, and then the user can select the value...or start typing and get an autofill of the nearest value in the valid list.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.