If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. |
|
|
Thread Tools | Display Modes |
#31
|
|||
|
|||
Formula ?
Steve,
You've been a great help. Thanks for your time and patience!! Tom Pickett, EMT-Paramedic ABLE Medical Transport 740-574-5555 "Steve Schapel" wrote: Tom, Tom wrote: Right now, I have a shortcut on my desktop to the form. When I open that up, that's when "000" appears everytime. You are right about the command button, it does change the number in the control. You can handle this by putting similar code into the On Load event property of the form itself. Something like this... Private Sub Form_Load() Me.RunNumber = Nz(DMax("[RunNumber]","ABLE_Table1","[RunDate]=Date()"),0)+1 Me.Dirty = False End Sub I also noticed that when I click on the command button, that the flashing cursor does not go to the 1st tab stop, on the next record. When I first open the database it does, but not after I record a record. When you move from record to record on a form, the focus stays on the same control on the next/new record as it was on the previous. If you want the behaviour to be different, you have to control it. The way to do this would be to add a line to the Command85 code, like this... Private Sub Command85_Click() DoCmd.GoToRecord , , acNewRec Me.NameOfFirstControl.SetFocus Me.RunNumber = Nz(DMax("[RunNumber]","ABLE_Table1","[RunDate]=Date()"),0)+1 Me.Dirty = False End Sub (of course, you substitute the actual name of your control for the 'NameOfFirstControl' in the code) A switchboard/ menu sounds like a great idea. I'm assuming, as a newbee, that this is like a "program" front end, "Welcome to ABLE Medical Dispatch" "select where you want to go" type of thing. With buttons for "Dispatching" "Reports" etc. Yes, that's exactly what I mean. A desktop shortcut to an Access form is not a suitable final solution, you need to provide a user interface to your application, and navigation facilities. It sounds like I need some books, and I have a list. Great idea. Do you have "Building Microsoft Access Applications" by John Viescas on your list? I just wanted to get started as we are going to begin operations in January. Well, I won't hold you up any longer... you've got a busy couple of months ahead of you. :-) -- Steve Schapel, Microsoft Access MVP |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
IF formula? | meris | Worksheet Functions | 1 | September 6th, 2005 07:14 AM |
adding row to forumla | carrera | General Discussion | 9 | August 23rd, 2005 10:24 PM |
Formula checking multiple worksheets | sonic-the-mouse | Worksheet Functions | 11 | June 6th, 2005 06:37 PM |
Formula to Count and Return Most common Value in a Dynamic Named Range | Tinä | General Discussion | 1 | October 23rd, 2004 08:51 PM |
generating formula with a formula | Lisa Linard | Worksheet Functions | 2 | November 27th, 2003 12:03 PM |