complie error:next without for
Thu, 11 Dec 2008 10:04:23 -0800
The following code gives me the next without for error. What is wrong?
Dim c As Control
If Not Me.NewRecord Then
For Each c In Me.Controls
If c.Tag = "Vehicle" Or c.Tag = "Outsourced" Then
If IsNull(c) Then
c.Visible = False
...
|
requery
Thu, 11 Dec 2008 09:05:01 -0800
I have subforms that add records. My problem is when I close the subform the
new record does not show until I move to another client and come back to the
original client. I know I have to do a requery of some kind, but I am at a
loss as to where to start. Thanks for any help. ...
|
Not in list not working
Thu, 11 Dec 2008 08:37:54 -0800 (PST)
I have a combo box with values chosen from a table field
(fldDepartmentsAffected). If the value selected does not already
exist, I want to allow the entry (even though limit to list set to
yes) but before doing that I want to "alert" the user so that he can
think twice before adding a new entry. I am using the ...
|
Add new record if nothing found with filter
Thu, 11 Dec 2008 08:31:01 -0800
Hi all,
Is there any way I can have a subform open up to a new record if nothing is
found by the search criteria that is filtering the main form?
Here is the search code
Also, I realize that I have the BeforeInsert event cancelled, but that is
because the address component of the search form is a concatenat ...
|
Closing Form After Set Amount of Time
Thu, 11 Dec 2008 07:52:04 -0800
I created a form as a welcome splash. I want it to display on startup. I know
how to do that. I need to know how to automatically close the form after a
set amount of time (say, 2 seconds from the current time). I don't know if
you do this through macros, coding, or the expression builder, so any help
would ...
|
Listbox SQL
Thu, 11 Dec 2008 07:29:01 -0800
Here's my code to fill a list box when a combo box is updated:
Private Sub cboCustomerName_AfterUpdate()
Dim sql As String
sql = "SELECT tblCustomer.CustomerName, tblClientBuildings.JobAddress1,
tblClientBuildings.JobAddress2 FROM tblCustomer INNER JOIN tblClientBuildings
ON tblCustomer.CustomerName = ...
|
clearing and closing a form
Thu, 11 Dec 2008 07:03:19 -0800
I have a form that contains a linked subform. It is being used as a data
entry screen. If someone begins typing into the form (either the form or the
subform) it inserts a record if they simply stop inputing the information and
close the form. I need a way to close the form and to not add any record that
may ...
|
|
|
The "good" way to use .Recordset
Thu, 11 Dec 2008 03:50:55 -0800 (PST)
I have done sore database editing using
Dim rs As DAO.Recordset
...
Set rs = DBEngine(0)(0).OpenRecordset(strSelect)
...
but I have also used some different methods, ie, some different
resources. I got used to this one just because I had some more
unsolved difficulties with the other alternative ways I ...
|
Running an Update query before closing a form
Thu, 11 Dec 2008 00:58:01 -0800
Hello everyone,
I have form ( record sourece table1)that has a control (ctr1) whose value I
need to update to a field in a different table ( table2). I have a command
button that I have to click everytime before closing the form to run an
update query so that the current value of ctr1 is copied to the field ...
|
Trap paste event in text box
Wed, 10 Dec 2008 23:00:02 -0800
I need to strip selected html tags from text copied from MS Word into a text
box with rich text format. I have written a VBA procedure which works when I
call it by clicking on a button after paste but I would like it to run
automatically at the time of the paste event. I have looked at all the
available ev ...
|