If you must have a table with logical info, the easiest way using a make table query would by with an IIF statement.
IIF([fieldname] like "X",-1,0)
Then you could use the absolute value rather then multiple by -1.
ABS(SUM([fieldname]))
Alex's advice to count the current data would...
Here's the basic code. I've included optional coding for authorization and version checks.
You'll notice that the code utilizes the filecopy method, checks for file on the drive and then uses the copyfile method as needed. I've had several instances where filecopy malfunctions, so this is my...
One thing you might try is distributing a launch program to your users. I set up a small database containing a copydown VBA module run from AutoExec. The user installs this launcher on their computer's C drive and creates a desktop shortcut. Each time they open the shortcut, the latest...
I've had success using the default value of "*" for controls. This way you're not dependant on the user selecting a value in each field.
Teri [pc3]
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
John,
Check out the DelayTime function shown in Thread 874640. Has worked for me in similar situations.
Teri [pc3]
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
Found my issue. The folder holding the FE / BE was locked. Runs like a charm now!
Teri [pc3]
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
I'm working on a multi-user database with a launch program that copies the FE from a network drive onto the user's harddrive prior to opening. I've used this method many times successfully.
Current Issue: Database will reside on a shared network drive but we do not want the user mapped to...
Jimlee,
Actually Payback's remark about the requery was the trick. Leaving off the requery command was all it took to make the code work like a charm.
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
Thanks PH!!! Works perfect now! Deserving of a star!
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
Am receiving Run Time error 91 - Object variable or with variable not set. Also, when the subform is requeried again the code will run again. (works 1st time, error 2nd time, works 3rd time)
Any assist appreciated.
Teri
Good decisions come from Wisdom...
Wisdom comes from...
I'm copying a recordset obtained from a subform based on parameters set on the main form into Excel. The Excel workbook has both a "dump" page for the raw data and a template. Based on the number of records, the template is copied as needed. It then inserts a set number of records into each...
I'm trying to compare two fields (date1, date2) on the current record of a continuous form. If the user attempts to enter information into Date1 when Date2 is not null, an error message is produced. The code below works fine for single form, but does not distinguish between records on a...
I have a subform where I am tracking plan vs actual dates linked to the main form by a unique number. On selecting a date using a MS Date and Time Picker on the subform, the user should be able to populate the plan or actual fields onClick. Originally the subform was a popup and worked using...
Solved my issue by looping along the If statements. Slower, but works!
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
PHV,
Formula still only returns zero. Thanks for the try though.
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
I'm using the following formula in VBA to try to get the number of symbols in Range2 where Range1 is null. There are 5 possible symbols to be found in either range. The formula will only return zero. Where am I going wrong?!?
s = Application.WorksheetFunction.SumIf(Range1, "=" """",Range2)...
Thanks for all your help! Andrew, you were absolutely correct. I had to switch my range reference around. I was referring to my row first as you would in a cell reference. Oh well, I'd definately been staring at the screen too long and overlooking that one! Works like a charm now.
Teri...
For some reason I keep getting one of those annoying "Runtime 1004" errors when attempting to use the following copy/paste method. Still learning and can't seem to figure out where I've gone astray.
where r = last row of data on sheet1:
For m = 1 To k
If...
Skip & Geoff,
Sorry I wasn't clearer. I'm attempting to block users from entering information into a given range (D5,I19) on the sheet so as to not change formulas.
Between the two of you, I've got it working now. Thanks!!
Teri
Good decisions come from Wisdom...
Wisdom comes from...
Skip,
Didn't think about the activate cells command causing a second occurance. New at this. Will try again with your suggested changes.
Teri
Good decisions come from Wisdom...
Wisdom comes from experience...
Experience comes from bad decisions
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.