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 |
#21
|
|||
|
|||
Last entry +1 help....Reset when desired.
Hi Fletcher,
I would like to echo your praise for Graham, he is brilliant, explains things well, and has incredible patience. I have been watching this thread and am impressed with what I have seen ... not only in Graham's answers, but also, you have asked worthy questions ... I wish you continued success with your project and your career Great job, Graham, I hope we have a chance to meet some day! Warm Regards, Crystal * (: have an awesome day * MVP Access Remote programming and Training strive4peace2006 at yahoo.com * Fletcher wrote: I must say that you are a genius. Thank you. Can you recommend any books for reference? I've elected for the first option that you gave me. I've set it up so that everything on the form disappears when the passes reaches 20 everything disappears except for the date and recharge button. And pop-up comes up and tells you to enter the date and time that the recharge took place. I've also set the form to update the date and time to the Now() after the recharge to ensure that the next entered pass is registered after the recharge. Just for good measure. Again, thank you so much. You may have kept me my internship. Graham Mandeno wrote: Hi Fletcher Let's just make sure that I'm understanding you correctly. Are you saying that you are adding a new pass record and the form has a default value of =Now() for the PassDate, but you want to register the recharge as happening *before* the time of the pass you are just entering? You have three options: 1. Set the recharge date/time to the same as the value in the pass date/time textbox: CurrentDb.Execute "Update FSIs set RCHGDate=" _ & Format(Me!PassDate, "\#mm/dd/yyyy hh:nn:ss\#") _ & " where FSINumber=" & Me!FSINumber 2. Reset the pass date/time to Now() *after* the recharge date/time has been updated: CurrentDb.Execute ... Me!Passdate = Now() 3. Forget about using a default value and record the pass date/time at the time that the record is saved. In Form_BeforeUpdate: If Me.NewRecord then Me!PassDate = Now() I'm glad everything else is working so well :-) -- Good Luck! Graham Mandeno [Access MVP] Auckland, New Zealand "Fletcher" wrote in message oups.com... Hey graham, All of this stuff works awesome. Thanks for everything that you explained to me. I really apreciate it. Now I only have one more question. I chose to use the recharge option that uses Now(). One thing that I've noticed is that when you go to the form and input an FSI number, it will tell you the number of passes since the last recharge. This is all good and well, but when you actually do click the recharge button, time has elapsed since you've opened the form. So when you click the recharge button and then enter in a new pass, the time on the form has not updated and believes that it is behind the last recharge time. So my question is: Is there any way to put an update form line in the code of the recharge button? Or is there a way to subtract 1 minute from the Now() in the recharge code? Or another option could be set the recharge date to the date currently on the form. I would prefer the first option, but I have no idea how to do it. I'll work on it and let you know if I figure it out before you get back to me. Thanks, Fletcher.... Graham Mandeno wrote: "Fletcher" wrote in message oups.com... I don't know if you saw my last question or not, but here is what I asked: Yes - sure did! Here it is again in case you missed it: "Graham Mandeno" wrote in message ... Hi again One other question though, how will I store a date in the RCHGDate field in *FSIs* when each FSI is recharged? This is the only place that I'm really confused right now. Ah well... that depends on what date/time you want to record. Will it always be the current date and time, or do you want to allow the user to enter a date/time, perhaps with a default of Now()? If you don't want a user override option, then you can use a simple update query: CurrentDb.Execute "Update FSIs set RCHGDate=Now() where FSINumber=" & Me.FSINumber You might want to pop up a MsgBox to request confirmation before executing the update. If you want the override option, then I suggest you make another form bound to FSIs, with locked, disabled textboxes bound to FSINumber and RCHGDate. Add another unbound textbox (txtNextRecharge) with an appropriate date/time format and a default value =Now(). Your form will look something like this: FSI Number: 2 Last Recharge: 20-Jul-2006 09:45 This Recharge: 29-Jul-2006 14:46 OK Cancel The user can change the date in the unbound field if required, and then click OK. The Click event procedure for the OK button looks like this: Private Sub cmdOK_Click() ' update the "real" field Me.RCHGDate = txtNextRecharge ' save the changed record Me.Dirty = False On Error Resume Next ' requery the txtNumberOfPasses textboxes on the main form Forms!frmPasses!txtNumberOfPasses.Requery ' close this form DoCmd.Close acForm, Me.Name End Sub The Cancel button would just close the form without updating. -- Good Luck! Graham Mandeno [Access MVP] Auckland, New Zealand |
#22
|
|||
|
|||
Last entry +1 help....Reset when desired.
Thank you, Crystal, for your very kind words. I am still blushing!
I'm not sure they are entirely deserved though - I am just doing what we all do as MVPs :-) One of the best experiences of my life was meeting a number of fellow MVPs in Seattle last year and I hope to be able to afford to make the trip again some day and that you will be there too! -- Warmest regards, Graham "strive4peace" wrote in message ... Hi Fletcher, I would like to echo your praise for Graham, he is brilliant, explains things well, and has incredible patience. I have been watching this thread and am impressed with what I have seen ... not only in Graham's answers, but also, you have asked worthy questions ... I wish you continued success with your project and your career Great job, Graham, I hope we have a chance to meet some day! Warm Regards, Crystal * (: have an awesome day * MVP Access Remote programming and Training strive4peace2006 at yahoo.com * Fletcher wrote: I must say that you are a genius. Thank you. Can you recommend any books for reference? I've elected for the first option that you gave me. I've set it up so that everything on the form disappears when the passes reaches 20 everything disappears except for the date and recharge button. And pop-up comes up and tells you to enter the date and time that the recharge took place. I've also set the form to update the date and time to the Now() after the recharge to ensure that the next entered pass is registered after the recharge. Just for good measure. Again, thank you so much. You may have kept me my internship. Graham Mandeno wrote: Hi Fletcher Let's just make sure that I'm understanding you correctly. Are you saying that you are adding a new pass record and the form has a default value of =Now() for the PassDate, but you want to register the recharge as happening *before* the time of the pass you are just entering? You have three options: 1. Set the recharge date/time to the same as the value in the pass date/time textbox: CurrentDb.Execute "Update FSIs set RCHGDate=" _ & Format(Me!PassDate, "\#mm/dd/yyyy hh:nn:ss\#") _ & " where FSINumber=" & Me!FSINumber 2. Reset the pass date/time to Now() *after* the recharge date/time has been updated: CurrentDb.Execute ... Me!Passdate = Now() 3. Forget about using a default value and record the pass date/time at the time that the record is saved. In Form_BeforeUpdate: If Me.NewRecord then Me!PassDate = Now() I'm glad everything else is working so well :-) -- Good Luck! Graham Mandeno [Access MVP] Auckland, New Zealand "Fletcher" wrote in message oups.com... Hey graham, All of this stuff works awesome. Thanks for everything that you explained to me. I really apreciate it. Now I only have one more question. I chose to use the recharge option that uses Now(). One thing that I've noticed is that when you go to the form and input an FSI number, it will tell you the number of passes since the last recharge. This is all good and well, but when you actually do click the recharge button, time has elapsed since you've opened the form. So when you click the recharge button and then enter in a new pass, the time on the form has not updated and believes that it is behind the last recharge time. So my question is: Is there any way to put an update form line in the code of the recharge button? Or is there a way to subtract 1 minute from the Now() in the recharge code? Or another option could be set the recharge date to the date currently on the form. I would prefer the first option, but I have no idea how to do it. I'll work on it and let you know if I figure it out before you get back to me. Thanks, Fletcher.... Graham Mandeno wrote: "Fletcher" wrote in message oups.com... I don't know if you saw my last question or not, but here is what I asked: Yes - sure did! Here it is again in case you missed it: "Graham Mandeno" wrote in message ... Hi again One other question though, how will I store a date in the RCHGDate field in *FSIs* when each FSI is recharged? This is the only place that I'm really confused right now. Ah well... that depends on what date/time you want to record. Will it always be the current date and time, or do you want to allow the user to enter a date/time, perhaps with a default of Now()? If you don't want a user override option, then you can use a simple update query: CurrentDb.Execute "Update FSIs set RCHGDate=Now() where FSINumber=" & Me.FSINumber You might want to pop up a MsgBox to request confirmation before executing the update. If you want the override option, then I suggest you make another form bound to FSIs, with locked, disabled textboxes bound to FSINumber and RCHGDate. Add another unbound textbox (txtNextRecharge) with an appropriate date/time format and a default value =Now(). Your form will look something like this: FSI Number: 2 Last Recharge: 20-Jul-2006 09:45 This Recharge: 29-Jul-2006 14:46 OK Cancel The user can change the date in the unbound field if required, and then click OK. The Click event procedure for the OK button looks like this: Private Sub cmdOK_Click() ' update the "real" field Me.RCHGDate = txtNextRecharge ' save the changed record Me.Dirty = False On Error Resume Next ' requery the txtNumberOfPasses textboxes on the main form Forms!frmPasses!txtNumberOfPasses.Requery ' close this form DoCmd.Close acForm, Me.Name End Sub The Cancel button would just close the form without updating. -- Good Luck! Graham Mandeno [Access MVP] Auckland, New Zealand |
#23
|
|||
|
|||
Last entry +1 help....Reset when desired.
Hi Fletcher
I'm very glad that it's all working now. Best of luck with the rest of the project and, if you need more help, you know where to come :-) As to recommendations for books, there are many of then about, but one of the very best for covering all aspects of application design is "Building Microsoft Access Applications" by my fellow MVP, John Viescas. More details he http://www.amazon.com/gp/product/0735620393 -- Good Luck! Graham Mandeno [Access MVP] Auckland, New Zealand "Fletcher" wrote in message oups.com... I must say that you are a genius. Thank you. Can you recommend any books for reference? I've elected for the first option that you gave me. I've set it up so that everything on the form disappears when the passes reaches 20 everything disappears except for the date and recharge button. And pop-up comes up and tells you to enter the date and time that the recharge took place. I've also set the form to update the date and time to the Now() after the recharge to ensure that the next entered pass is registered after the recharge. Just for good measure. Again, thank you so much. You may have kept me my internship. |
#24
|
|||
|
|||
Last entry +1 help....Reset when desired.
you are very welcome, Graham!
I hope to be able to make the trip to Seattle myself -- next year will be my first ... guess New Zealand is a little further away from Redmond than Pennsylvania I see you are also a singer -- I don't sing opera, but I do love to sing. I am also a songwriter and play piano. Warm Regards, Crystal * (: have an awesome day * MVP Access Remote programming and Training strive4peace2006 at yahoo.com * Graham Mandeno wrote: Thank you, Crystal, for your very kind words. I am still blushing! I'm not sure they are entirely deserved though - I am just doing what we all do as MVPs :-) One of the best experiences of my life was meeting a number of fellow MVPs in Seattle last year and I hope to be able to afford to make the trip again some day and that you will be there too! |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Rapid input Via datasheet | RudyR_Seattle | General Discussion | 4 | January 31st, 2005 01:33 AM |
Could I get some query theory clarification? | Dennis Snelgrove | Running & Setting Up Queries | 3 | November 27th, 2004 11:13 PM |
Converting GAL address entry to outlook contact | Ramana | Contacts | 2 | October 23rd, 2004 08:21 PM |
QDE (Quick Date Entry) | Norman Harker | Worksheet Functions | 37 | September 5th, 2004 01:24 AM |
QDE (Quick Date Entry) | Norman Harker | General Discussion | 3 | September 3rd, 2004 08:00 AM |