I need to implement some default-setting behavior in a form. For various reasons, I can't use standard field defaults or the DefaultValue property of my controls so I'll need to program the solution.
What's the best way to tell if the current record on a form is a "new" record...
I've got a modal pop-up form that bound to a table. The cancel button should close the form and ignore any changes.
Problem is, changes made to fields on the pop-up form are committed after the user unfocuses on the field being edited. If a user makes a bunch of changes to various fields in...
I've got a text box that maps back to a decimal field data type in SQL Server (in an Access Project).
I'd like to offer the user the ability to type in an integer from 0 - 100 (the percent they desire) and have that be translated into the corresponding decimal value.
I can do this with code...
In my quest to write a "global" audit trigger (one that does not contain any table-specific code), I need to determine the name of the table that fired my trigger programatically.
In my audit code, I log the table name being modified. Without a way to determine that name...
I've got a trigger written (thanks Terry) that's logging INSERT, UPDATE, and DELETE activity on my table.
I'd like to re-use this trigger code on all my tables so I thought that putting it into a stored procedure and passing table-specific data from the trigger would be the ideal way to do...
I'm trying to implement a simple auditing feature by creating a trigger that writes a LastModifiedID and LastModifiedDate to columns on each table in my database.
The LastModifiedID and LastModifiedDate columns are not directly edited by a user, they rely on the triggers to be populated.
In a...
I'm writing a trigger to write audit data to my table, it automatically inserts the LastModifiedID and LastModified date into fields on that table.
I've put a Not NULL constraint on the LastModifiedID and LastModified columns.
The problem is that a simple insert into the other columns (not the...
Ok, I know how to use the Advanced tab to add user-defined fields into my Advanced Search criteria.
But the real bummer here is that I just want an easy way to search on *all* fields in a form, including user-defined fields.
Is there any way to do this? If not, is there a way to extend the...
I'm designing a database in which I track changes made to each record. I've currently got a scheme whereby each table has a "LastModifedID" and a "LastModifiedDateTime" column. I intend to populate these with insert and update triggers.
Is there a better way to do this? I...
I've seen several places now that a trigger cannot be used to generate a non integer Primary Key. I'm good with that but would like to read up on the details behind *why*. A cursory check of Books Online doesn't turn up this limitation. Where is it documented? Is there a discussion I can...
I've fallen into the habit of assigning Surrogate (artificial) keys when doing my relational designs. I've got a client who needs a database with an "Intelligent" primary key on one of the tables. More specifically he would like the Primary Key to be a "Product Number" that...
I've got a database that needs some better organization. One of the things I'd like to do is change the query name to be more standardized and descriptive but changing the name is going to break forms, reports, queries, combox boxes, etc. that rely on those queries having their current names...
I'm building an application in Access 2000 and have used the DateTimePicker ActiveX control. My client requires delivery in Access 97 format. So far I've managed to workaround all the incompatibilities but the DateTimePicker thing has me stumped.
Can I used the DateTimePicker control that...
I've got a combo box and I'd like it open up (pop-down and show the values as it does when you click on the down arrow) automatically. Is this possible?
Thanks!
- Gary
I've got two combo boxes on a continuous form. The first combo box determines what appears in the second. This is currently done by creating a SQL query as the recordsource for the second combo box and having that query reference the value of the first combo box.
As you probably know, this...
What are the recommended techniques for setting a default field value to the last-entered value for that field? In other words, can I set the default value for a field (either the field default or the form-control default) to the field value of the previous record?
Thanks!
- Gary
I've got a combo box whose Row Source is a query. That query has 4 fields:
* CardType
* CardTypeID
* NumOfPrivates
* NumOfIndependents
The bound column is #2 (CardTypeID), it's the foreign key for this field. The only column shown to the end-user as a pop-up menu choice is the CardType (it's...
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.