From jwcolby at gmail.com Thu Nov 1 08:55:44 2018 From: jwcolby at gmail.com (John Colby) Date: Thu, 1 Nov 2018 09:55:44 -0400 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube Message-ID: https://youtu.be/wd_lhqi2NcA From tinanfields at torchlake.com Thu Nov 1 10:13:52 2018 From: tinanfields at torchlake.com (Tina N Fields) Date: Thu, 1 Nov 2018 11:13:52 -0400 Subject: [AccessD] Set value in a report textbox In-Reply-To: <93b10dae-87f5-2da0-4225-4a28e60b257b@torchlake.com> References: <93b10dae-87f5-2da0-4225-4a28e60b257b@torchlake.com> Message-ID: Hi again, with thanks to both Rocky and Stuart, Well, this one is fixed. My mistake was, as usual, not thinking forward for my client. I had asked at the outset about the name to appear on the top of this report. No, no, because we're trying to be thoughtful and confidential about people and their needs, we want only the family name to appear up there - we have the assigned family number so we can always go look up the details. The query I built for the overall report I also used as the source for the subreports - lots of info crammed into just that one query. That was my error. Fixed the problems by making separate queries, so just the "a" person is in the report query, and all the persons are in the subreport queries. The report now has the full name of the "a" person of the household at the top. Thanks again to you both for helping me to wake up my brain. T Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com On 10/30/2018 5:04 PM, Tina N Fields wrote: > Hii, > > I have a report for my local Salvation Army, that is to be a signature > sheet for the family picking up the Christmas stuff. > > When we developed it, they wanted only the household name and the > assigned family number to be displayed at the top of the report. Turns > out, though, they'd really also like the first name of the parent of > the household. > > The tblHouseholds doesn't have any? person names in it, of course. So, > I want to put a textbox alongside the Household name box to be > populated with the first name of person A in the household. The > tblPeople has the foreign key matching the household ID. (Using John > Colby's naming convention, HH_ID from tblHouseholds is foreign key > PE_IDHH.) > > How do I do this? I have the PE_Fname in the query, and I have the > person's rank in the family (they insisted on this), so each > individual's record has a PE_Fam-spot field.? How do I display the > PE_Fname of the person with the PE_Fam-spot of "A" where PE_IDHH > equals HH_ID? > > It feels as though this should be simple, but I'm just not getting it. > > Thanks for any help you can give me. > > T > From gustav at cactus.dk Fri Nov 2 06:15:53 2018 From: gustav at cactus.dk (Gustav Brock) Date: Fri, 2 Nov 2018 11:15:53 +0000 Subject: [AccessD] OT: Friday humour Message-ID: Hi all Maybe not that humorous, but - handmade as it is - a very impressive animation piece: https://www.youtube.com/watch?v=vcBn04IyELc Enjoy, but please note, that audio is mandatory. /gustav From stuart at lexacorp.com.pg Fri Nov 2 06:42:48 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Fri, 02 Nov 2018 21:42:48 +1000 Subject: [AccessD] OT: Friday humour In-Reply-To: References: Message-ID: <5BDC3838.2125.64648303@stuart.lexacorp.com.pg> Brilliant! Did you also see the next one, Mountain King? https://www.youtube.com/watch?v=RIz3klPET3o I downloaded them both to play again :). On 2 Nov 2018 at 11:15, Gustav Brock wrote: > Hi all > > Maybe not that humorous, but - handmade as it is - a very impressive > animation piece: > > https://www.youtube.com/watch?v=vcBn04IyELc > > Enjoy, but please note, that audio is mandatory. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From gustav at cactus.dk Fri Nov 2 06:51:55 2018 From: gustav at cactus.dk (Gustav Brock) Date: Fri, 2 Nov 2018 11:51:55 +0000 Subject: [AccessD] OT: Friday humour Message-ID: Hi Stuart No, I missed that. Will do when I get home and can play at some decent volume. Thanks! /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Stuart McLachlan Sendt: 2. november 2018 12:43 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] OT: Friday humour Brilliant! Did you also see the next one, Mountain King? https://www.youtube.com/watch?v=RIz3klPET3o I downloaded them both to play again :). On 2 Nov 2018 at 11:15, Gustav Brock wrote: > Hi all > > Maybe not that humorous, but - handmade as it is - a very impressive > animation piece: > > https://www.youtube.com/watch?v=vcBn04IyELc > > Enjoy, but please note, that audio is mandatory. > > /gustav From ssharkins at gmail.com Fri Nov 2 07:51:18 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Fri, 2 Nov 2018 08:51:18 -0400 Subject: [AccessD] OT: Friday humour In-Reply-To: <5BDC3838.2125.64648303@stuart.lexacorp.com.pg> References: <5BDC3838.2125.64648303@stuart.lexacorp.com.pg> Message-ID: <00ba01d472aa$c0cc7aa0$42656fe0$@gmail.com> I did too and then stuck around for Dance of the Sugar Plum Fairies. What I found interesting is that more than a couple of times, the figure emphasis some nuance that I'd never "heard" before -- so very cool in deed. Susan H Brilliant! Did you also see the next one, Mountain King? https://www.youtube.com/watch?v=RIz3klPET3o I downloaded them both to play again :). On 2 Nov 2018 at 11:15, Gustav Brock wrote: > Hi all > > Maybe not that humorous, but - handmade as it is - a very impressive > animation piece: > > https://www.youtube.com/watch?v=vcBn04IyELc > > Enjoy, but please note, that audio is mandatory. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From ssharkins at gmail.com Fri Nov 2 07:51:18 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Fri, 2 Nov 2018 08:51:18 -0400 Subject: [AccessD] OT: Friday humour In-Reply-To: References: Message-ID: <00bb01d472aa$c2026290$460727b0$@gmail.com> I wonder how much of that is generated by some really neat algorithms. Susan H Hi all Maybe not that humorous, but - handmade as it is - a very impressive animation piece: https://www.youtube.com/watch?v=vcBn04IyELc Enjoy, but please note, that audio is mandatory. /gustav -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From paul at wordwright.org Fri Nov 2 09:23:58 2018 From: paul at wordwright.org (paul) Date: Fri, 2 Nov 2018 16:23:58 +0200 Subject: [AccessD] OT: Friday humour In-Reply-To: References: Message-ID: Very good, and wouldn't have wanted not to have the sound. Excellent, and how interesting to see Friday Humour back with us. Many thanks paul On Fri, 2 Nov 2018 at 13:16, Gustav Brock wrote: > Hi all > > Maybe not that humorous, but - handmade as it is - a very impressive > animation piece: > > https://www.youtube.com/watch?v=vcBn04IyELc > > Enjoy, but please note, that audio is mandatory. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- My regular bloggin's - facebook.com/Sailingtopurgatory and sinbadh.blogspot.com plus sailingtopurgatory.com | Google Local Guide From jbartow at winhaven.net Fri Nov 2 14:48:56 2018 From: jbartow at winhaven.net (John Bartow) Date: Fri, 2 Nov 2018 19:48:56 +0000 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: Message-ID: Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From tinanfields at torchlake.com Fri Nov 2 16:09:21 2018 From: tinanfields at torchlake.com (Tina N Fields) Date: Fri, 2 Nov 2018 17:09:21 -0400 Subject: [AccessD] OT: Friday humour In-Reply-To: References: Message-ID: <5b79aa9f-ce9b-8bf8-2447-71a9a39f5cd5@torchlake.com> Gustav, That's actually terrific! Thank you for posting the link. T Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com On 11/2/2018 7:15 AM, Gustav Brock wrote: > Hi all > > Maybe not that humorous, but - handmade as it is - a very impressive animation piece: > > https://www.youtube.com/watch?v=vcBn04IyELc > > Enjoy, but please note, that audio is mandatory. > > /gustav From accessd at shaw.ca Fri Nov 2 16:23:50 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 15:23:50 -0600 (MDT) Subject: [AccessD] OT: Friday humour In-Reply-To: References: Message-ID: <1928232548.186858244.1541193830165.JavaMail.zimbra@shaw.ca> Love it... Jim ----- Original Message ----- From: "Gustav Brock" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 4:15:53 AM Subject: [AccessD] OT: Friday humour Hi all Maybe not that humorous, but - handmade as it is - a very impressive animation piece: https://www.youtube.com/watch?v=vcBn04IyELc Enjoy, but please note, that audio is mandatory. /gustav -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Fri Nov 2 16:19:12 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 15:19:12 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: Message-ID: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jbartow at winhaven.net Fri Nov 2 16:49:25 2018 From: jbartow at winhaven.net (John Bartow) Date: Fri, 2 Nov 2018 21:49:25 +0000 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> Message-ID: I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Fri Nov 2 17:13:04 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 16:13:04 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> Message-ID: <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> Apparently...but that still doesn't make it right. Maybe we should employ the European model and sue a bunch of companies a few billion until the comply to our wishes. After all we are their bosses. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 2:49:25 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jbartow at winhaven.net Fri Nov 2 18:24:48 2018 From: jbartow at winhaven.net (John Bartow) Date: Fri, 2 Nov 2018 23:24:48 +0000 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> Message-ID: Go for it! :-) He says while hiding under his tin foil hat... -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 5:13 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Apparently...but that still doesn't make it right. Maybe we should employ the European model and sue a bunch of companies a few billion until the comply to our wishes. After all we are their bosses. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 2:49:25 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From ssharkins at gmail.com Fri Nov 2 18:32:33 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Fri, 2 Nov 2018 19:32:33 -0400 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> Message-ID: <00e801d47304$566ffbf0$034ff3d0$@gmail.com> They usually move to a country that's more complaint. Susan h. Go for it! :-) He says while hiding under his tin foil hat... -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 5:13 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Apparently...but that still doesn't make it right. Maybe we should employ the European model and sue a bunch of companies a few billion until the comply to our wishes. After all we are their bosses. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 2:49:25 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From bensonforums at gmail.com Fri Nov 2 18:43:26 2018 From: bensonforums at gmail.com (Bill Benson) Date: Fri, 2 Nov 2018 19:43:26 -0400 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> Message-ID: They (Google not govrrnment) have the right because we click accept to the Ts and Cs. If you have a problem with it then do what Scotty did or else otherwise boycott Android device mfgs. Don't know what else to tell ya. It's optional, they can'take you buy the phones or use them. If they couldn't monetize, they phones with the features they have nowadays would probably cost a whole lot more. On Fri, Nov 2, 2018, 5:34 PM Jim Lawrence Well, it should not be up to us to dump our cellphones, but it is up to us > to dump our governments. How dare any government or any business to think > they have this right. > > Jim > > ----- Original Message ----- > From: "John R Bartow" > To: "Access Developers discussion and problem solving" < > accessd at databaseadvisors.com> > Sent: Friday, November 2, 2018 12:48:56 PM > Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube > > Thanks, good post - I wish they'd have done it with an iPhone too! > Check this out: > https://youtu.be/iX3n2nb3VuU?t=850 > > > -----Original Message----- > From: AccessD On Behalf Of John > Colby > Sent: Thursday, November 01, 2018 8:56 AM > To: Access Developers discussion and problem solving < > accessd at databaseadvisors.com> > Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube > > https://youtu.be/wd_lhqi2NcA > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From accessd at shaw.ca Fri Nov 2 19:23:29 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 18:23:29 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> Message-ID: <1842013681.187808327.1541204609772.JavaMail.zimbra@shaw.ca> I'd love to... :-) Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 4:24:48 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Go for it! :-) He says while hiding under his tin foil hat... -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 5:13 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Apparently...but that still doesn't make it right. Maybe we should employ the European model and sue a bunch of companies a few billion until the comply to our wishes. After all we are their bosses. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 2:49:25 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Fri Nov 2 19:27:17 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 18:27:17 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: <00e801d47304$566ffbf0$034ff3d0$@gmail.com> References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1345556594.187147764.1541196784470.JavaMail.zimbra@shaw.ca> <00e801d47304$566ffbf0$034ff3d0$@gmail.com> Message-ID: <1384237923.187821086.1541204837700.JavaMail.zimbra@shaw.ca> The US for example? Jim ----- Original Message ----- From: "Susan Harkins" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 4:32:33 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube They usually move to a country that's more complaint. Susan h. Go for it! :-) He says while hiding under his tin foil hat... -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 5:13 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Apparently...but that still doesn't make it right. Maybe we should employ the European model and sue a bunch of companies a few billion until the comply to our wishes. After all we are their bosses. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 2:49:25 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube I guess they dare! -----Original Message----- From: AccessD On Behalf Of Jim Lawrence Sent: Friday, November 02, 2018 4:19 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Well, it should not be up to us to dump our cellphones, but it is up to us to dump our governments. How dare any government or any business to think they have this right. Jim ----- Original Message ----- From: "John R Bartow" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 12:48:56 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Thanks, good post - I wish they'd have done it with an iPhone too! Check this out: https://youtu.be/iX3n2nb3VuU?t=850 -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Thursday, November 01, 2018 8:56 AM To: Access Developers discussion and problem solving Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube https://youtu.be/wd_lhqi2NcA -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Fri Nov 2 19:32:59 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 18:32:59 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> Message-ID: <1269775788.187835370.1541205179144.JavaMail.zimbra@shaw.ca> We clicked "yes" for our government too. Clicking "yes" does not give anyone a "carte blanche" licence to do as they please. Jim ----- Original Message ----- From: "Bill Benson" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 4:43:26 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube They (Google not govrrnment) have the right because we click accept to the Ts and Cs. If you have a problem with it then do what Scotty did or else otherwise boycott Android device mfgs. Don't know what else to tell ya. It's optional, they can'take you buy the phones or use them. If they couldn't monetize, they phones with the features they have nowadays would probably cost a whole lot more. On Fri, Nov 2, 2018, 5:34 PM Jim Lawrence Well, it should not be up to us to dump our cellphones, but it is up to us > to dump our governments. How dare any government or any business to think > they have this right. > > Jim > > ----- Original Message ----- > From: "John R Bartow" > To: "Access Developers discussion and problem solving" < > accessd at databaseadvisors.com> > Sent: Friday, November 2, 2018 12:48:56 PM > Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube > > Thanks, good post - I wish they'd have done it with an iPhone too! > Check this out: > https://youtu.be/iX3n2nb3VuU?t=850 > > > -----Original Message----- > From: AccessD On Behalf Of John > Colby > Sent: Thursday, November 01, 2018 8:56 AM > To: Access Developers discussion and problem solving < > accessd at databaseadvisors.com> > Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube > > https://youtu.be/wd_lhqi2NcA > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From bensonforums at gmail.com Fri Nov 2 20:06:12 2018 From: bensonforums at gmail.com (Bill Benson) Date: Fri, 2 Nov 2018 21:06:12 -0400 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: <1269775788.187835370.1541205179144.JavaMail.zimbra@shaw.ca> References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1269775788.187835370.1541205179144.JavaMail.zimbra@shaw.ca> Message-ID: Nope. Not to do as they please. Only what you click yes to allow. Fine print is the bastion of Insurance companies, governments and malpractice lawyers. UNCONSCIONABLE contracts can be voided. But only voided, not made one sided. You can probably fight them in court to get your data back but only if you can prove you were swindled. If you keep using their devices, with every moment that passes you are providing evidence you've knowingly acquiesced to the terms and conditions. I don't like it either but I don't worry about it much. > > From accessd at shaw.ca Fri Nov 2 20:17:07 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Fri, 2 Nov 2018 19:17:07 -0600 (MDT) Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1269775788.187835370.1541205179144.JavaMail.zimbra@shaw.ca> Message-ID: <254251127.188060403.1541207827424.JavaMail.zimbra@shaw.ca> I was thinking bigger, the Sherman Antitrust Act comes to mind. Slice, dice and sell off. Jim ----- Original Message ----- From: "Bill Benson" To: "Access Developers discussion and problem solving" Sent: Friday, November 2, 2018 6:06:12 PM Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Nope. Not to do as they please. Only what you click yes to allow. Fine print is the bastion of Insurance companies, governments and malpractice lawyers. UNCONSCIONABLE contracts can be voided. But only voided, not made one sided. You can probably fight them in court to get your data back but only if you can prove you were swindled. If you keep using their devices, with every moment that passes you are providing evidence you've knowingly acquiesced to the terms and conditions. I don't like it either but I don't worry about it much. > > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From tinanfields at torchlake.com Sat Nov 3 12:29:52 2018 From: tinanfields at torchlake.com (Tina N Fields) Date: Sat, 3 Nov 2018 13:29:52 -0400 Subject: [AccessD] Another challenge I need help with Message-ID: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> Hi All, Here's what I'm trying to do: A combobox shows the list of individuals in the database The user selects a particular individual from the combovox The user clicks a button to delete that individual's record from the tblPeople A message box pops up to ask "Are you sure you want to permanently delete this record?" The user responds either with a 'Yes" or a "Cancel." If the user clicks "Yes," that individual record is deleted from the tblPeople. I have the form with the combobox in place. It is populated with a query selecting the individual's ID, the individual's name, the family name (not always the same as the indifidual's last name), and the assigned family code. The bound column is the PE_ID, which is not displayed. (The family name and code are just so the user can be sure which John Smith is being selected, in case of more than one in the database.) I need help figuring out the rest of this. Any ideas? Thanks, T -- Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com From stuart at lexacorp.com.pg Sat Nov 3 15:00:45 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Sun, 04 Nov 2018 06:00:45 +1000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> Message-ID: <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> The way I do this is something like: Assuming the bound column is cboPepole is PE_ID, then Sub CmdDelete_OnClick: If msgbox,"Are you sure you want to delete this record",acYeseNo,"About to delete Record" = vbYes Then CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & cboPeople Msgbox ""Record Deleted" Else Msgbox "Deletion cancelled" End If End Sub On 3 Nov 2018 at 13:29, Tina N Fields wrote: > Hi All, > > Here's what I'm trying to do: > > A combobox shows the list of individuals in the database > The user selects a particular individual from the combovox > The user clicks a button to delete that individual's record from the > tblPeople A message box pops up to ask "Are you sure you want to > permanently delete this record?" The user responds either with a 'Yes" > or a "Cancel." If the user clicks "Yes," that individual record is > deleted from the tblPeople. > > I have the form with the combobox in place. It is populated with a > query selecting the individual's ID, the individual's name, the family > name (not always the same as the indifidual's last name), and the > assigned family code. The bound column is the PE_ID, which is not > displayed. (The family name and code are just so the user can be sure > which John Smith is being selected, in case of more than one in the > database.) > > I need help figuring out the rest of this. Any ideas? > > Thanks, > T > > -- > Tina Norris Fields > 231-322-2787 > tinanfields-at-torchlake-dot-com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From jbartow at winhaven.net Sat Nov 3 15:09:31 2018 From: jbartow at winhaven.net (John Bartow) Date: Sat, 3 Nov 2018 20:09:31 +0000 Subject: [AccessD] Watch "Why I ditched my smartphone" on YouTube In-Reply-To: References: <1341449172.186840014.1541193552117.JavaMail.zimbra@shaw.ca> <1269775788.187835370.1541205179144.JavaMail.zimbra@shaw.ca> Message-ID: I see what you're saying - unfortunately even if you accept what the T&Cs are when you buy an unlocked phone (outright purchase paying a high price) and then the company forces you to upgrade and accept new T&Cs or they deprecate your services or stop them altogether (MS's Windows Phone system for example). So I agree with Jim, the companies are, in essence, "forcing" you to do these things. In lieu of government oversight, I see no recourse other than to stop using them. Or lie a lot when filling out info and screw up there data warehouses. Lend your phone to cops/hookers/truckers some night and see what kind of ads you get the next day, lol. -----Original Message----- From: AccessD On Behalf Of Bill Benson Sent: Friday, November 02, 2018 8:06 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Watch "Why I ditched my smartphone" on YouTube Nope. Not to do as they please. Only what you click yes to allow. Fine print is the bastion of Insurance companies, governments and malpractice lawyers. UNCONSCIONABLE contracts can be voided. But only voided, not made one sided. You can probably fight them in court to get your data back but only if you can prove you were swindled. If you keep using their devices, with every moment that passes you are providing evidence you've knowingly acquiesced to the terms and conditions. I don't like it either but I don't worry about it much. > > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From RockySmolin at bchacc.com Sun Nov 4 03:03:55 2018 From: RockySmolin at bchacc.com (RockySmolin at bchacc.com) Date: Sun, 04 Nov 2018 02:03:55 -0700 Subject: [AccessD] Another challenge I need help with Message-ID: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> Don?t forget the requery after delete. But would DoCommand.RunCommand acCmdDeleteRecord work just as well? r -------- Original Message -------- Subject: Re: [AccessD] Another challenge I need help with From: "Stuart McLachlan" Date: Sat, November 03, 2018 1:00 pm To: Access Developers discussion and problem solving The way I do this is something like: Assuming the bound column is cboPepole is PE_ID, then Sub CmdDelete_OnClick: If msgbox,"Are you sure you want to delete this record",acYeseNo,"About to delete Record" = vbYes Then CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & cboPeople Msgbox ""Record Deleted" Else Msgbox "Deletion cancelled" End If End Sub On 3 Nov 2018 at 13:29, Tina N Fields wrote: > Hi All, > > Here's what I'm trying to do: > > A combobox shows the list of individuals in the database > The user selects a particular individual from the combovox > The user clicks a button to delete that individual's record from the > tblPeople A message box pops up to ask "Are you sure you want to > permanently delete this record?" The user responds either with a 'Yes" > or a "Cancel." If the user clicks "Yes," that individual record is > deleted from the tblPeople. > > I have the form with the combobox in place. It is populated with a > query selecting the individual's ID, the individual's name, the family > name (not always the same as the indifidual's last name), and the > assigned family code. The bound column is the PE_ID, which is not > displayed. (The family name and code are just so the user can be sure > which John Smith is being selected, in case of more than one in the > database.) > > I need help figuring out the rest of this. Any ideas? > > Thanks, > T > > -- > Tina Norris Fields > 231-322-2787 > tinanfields-at-torchlake-dot-com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Sun Nov 4 04:39:49 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Sun, 04 Nov 2018 20:39:49 +1000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> References: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> Message-ID: <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> I assumed that it was an unbound form or at the least that combobox was not bound to a recordset field if it is a bound form. You're correct that you should requery either the combobox or the form if it is bound to tblPeople. On 4 Nov 2018 at 2:03, RockySmolin at bchacc.com wrote: > Don?t forget the requery after delete. But would > DoCommand.RunCommand acCmdDeleteRecord work just as well? > > r > -------- Original Message -------- > Subject: Re: [AccessD] Another challenge I need help with > From: "Stuart McLachlan" > Date: Sat, November 03, 2018 1:00 pm > To: Access Developers discussion and problem solving > > > The way I do this is something like: > > Assuming the bound column is cboPepole is PE_ID, then > > Sub CmdDelete_OnClick: > > If msgbox,"Are you sure you want to delete this > record",acYeseNo,"About to delete Record" = vbYes Then > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > cboPeople Msgbox ""Record Deleted" > > Else > > Msgbox "Deletion cancelled" > > End If > > End Sub > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > Hi All, > > > > Here's what I'm trying to do: > > > > A combobox shows the list of individuals in the database > > The user selects a particular individual from the combovox > > The user clicks a button to delete that individual's record from the > > tblPeople A message box pops up to ask "Are you sure you want to > > permanently delete this record?" The user responds either with a > > 'Yes" or a "Cancel." If the user clicks "Yes," that individual > > record is deleted from the tblPeople. > > > > I have the form with the combobox in place. It is populated with a > > query selecting the individual's ID, the individual's name, the > > family name (not always the same as the indifidual's last name), and > > the assigned family code. The bound column is the PE_ID, which is > > not displayed. (The family name and code are just so the user can be > > sure which John Smith is being selected, in case of more than one in > > the database.) > > > > I need help figuring out the rest of this. Any ideas? > > > > Thanks, > > T > > > > -- > > Tina Norris Fields > > 231-322-2787 > > tinanfields-at-torchlake-dot-com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com From JoeO at appoli.com Sun Nov 4 09:12:17 2018 From: JoeO at appoli.com (Joe O'Connell) Date: Sun, 4 Nov 2018 15:12:17 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> Message-ID: Maybe it is just my users, but they sometimes need to be protected from themselves from automatically hitting the enter key whenever a msgbox is displayed instead of reading the message. Instead of just acYesNo, I add an option to default to No and to display a question mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion Joe O'Connell -----Original Message----- From: AccessD On Behalf Of Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Another challenge I need help with The way I do this is something like: Assuming the bound column is cboPepole is PE_ID, then Sub CmdDelete_OnClick: If msgbox,"Are you sure you want to delete this record",acYeseNo,"About to delete Record" = vbYes Then CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & cboPeople Msgbox ""Record Deleted" Else Msgbox "Deletion cancelled" End If End Sub On 3 Nov 2018 at 13:29, Tina N Fields wrote: > Hi All, > > Here's what I'm trying to do: > > A combobox shows the list of individuals in the database The user > selects a particular individual from the combovox The user clicks a > button to delete that individual's record from the tblPeople A message > box pops up to ask "Are you sure you want to permanently delete this > record?" The user responds either with a 'Yes" > or a "Cancel." If the user clicks "Yes," that individual record is > deleted from the tblPeople. > > I have the form with the combobox in place. It is populated with a > query selecting the individual's ID, the individual's name, the family > name (not always the same as the indifidual's last name), and the > assigned family code. The bound column is the PE_ID, which is not > displayed. (The family name and code are just so the user can be sure > which John Smith is being selected, in case of more than one in the > database.) > > I need help figuring out the rest of this. Any ideas? > > Thanks, > T > > -- > Tina Norris Fields > 231-322-2787 > tinanfields-at-torchlake-dot-com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From tinanfields at torchlake.com Sun Nov 4 10:10:14 2018 From: tinanfields at torchlake.com (Tina N Fields) Date: Sun, 4 Nov 2018 11:10:14 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> Message-ID: <09a65af6-354f-f410-1a90-b48f93d37cf9@torchlake.com> Joe, I think you're right about that. Thank you. T Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com On 11/4/2018 10:12 AM, Joe O'Connell wrote: > Maybe it is just my users, but they sometimes need to be protected from themselves from automatically hitting the enter key whenever a msgbox is displayed instead of reading the message. Instead of just acYesNo, I add an option to default to No and to display a question mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > > Joe O'Connell > > -----Original Message----- > From: AccessD On Behalf Of Stuart McLachlan > Sent: Saturday, November 3, 2018 4:01 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > The way I do this is something like: > > Assuming the bound column is cboPepole is PE_ID, then > > Sub CmdDelete_OnClick: > > If msgbox,"Are you sure you want to delete this record",acYeseNo,"About to delete Record" = vbYes Then > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & cboPeople > Msgbox ""Record Deleted" > > Else > > Msgbox "Deletion cancelled" > > End If > > End Sub > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > >> Hi All, >> >> Here's what I'm trying to do: >> >> A combobox shows the list of individuals in the database The user >> selects a particular individual from the combovox The user clicks a >> button to delete that individual's record from the tblPeople A message >> box pops up to ask "Are you sure you want to permanently delete this >> record?" The user responds either with a 'Yes" >> or a "Cancel." If the user clicks "Yes," that individual record is >> deleted from the tblPeople. >> >> I have the form with the combobox in place. It is populated with a >> query selecting the individual's ID, the individual's name, the family >> name (not always the same as the indifidual's last name), and the >> assigned family code. The bound column is the PE_ID, which is not >> displayed. (The family name and code are just so the user can be sure >> which John Smith is being selected, in case of more than one in the >> database.) >> >> I need help figuring out the rest of this. Any ideas? >> >> Thanks, >> T >> >> -- >> Tina Norris Fields >> 231-322-2787 >> tinanfields-at-torchlake-dot-com >> >> -- >> AccessD mailing list >> AccessD at databaseadvisors.com >> http://databaseadvisors.com/mailman/listinfo/accessd >> Website: http://www.databaseadvisors.com >> > From tinanfields at torchlake.com Sun Nov 4 10:12:17 2018 From: tinanfields at torchlake.com (Tina N Fields) Date: Sun, 4 Nov 2018 11:12:17 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> References: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> Message-ID: Thanks again, to both of you. Yes, it is unbound. Yes, requery is essential. Progress, T Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com On 11/4/2018 5:39 AM, Stuart McLachlan wrote: > I assumed that it was an unbound form or at the least that combobox was not bound to a > recordset field if it is a bound form. > > You're correct that you should requery either the combobox or the form if it is bound to > tblPeople. > > On 4 Nov 2018 at 2:03, RockySmolin at bchacc.com wrote: > >> Don?t forget the requery after delete. But would >> DoCommand.RunCommand acCmdDeleteRecord work just as well? >> >> r >> -------- Original Message -------- >> Subject: Re: [AccessD] Another challenge I need help with >> From: "Stuart McLachlan" >> Date: Sat, November 03, 2018 1:00 pm >> To: Access Developers discussion and problem solving >> >> >> The way I do this is something like: >> >> Assuming the bound column is cboPepole is PE_ID, then >> >> Sub CmdDelete_OnClick: >> >> If msgbox,"Are you sure you want to delete this >> record",acYeseNo,"About to delete Record" = vbYes Then >> >> CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & >> cboPeople Msgbox ""Record Deleted" >> >> Else >> >> Msgbox "Deletion cancelled" >> >> End If >> >> End Sub >> >> >> On 3 Nov 2018 at 13:29, Tina N Fields wrote: >> >>> Hi All, >>> >>> Here's what I'm trying to do: >>> >>> A combobox shows the list of individuals in the database >>> The user selects a particular individual from the combovox >>> The user clicks a button to delete that individual's record from the >>> tblPeople A message box pops up to ask "Are you sure you want to >>> permanently delete this record?" The user responds either with a >>> 'Yes" or a "Cancel." If the user clicks "Yes," that individual >>> record is deleted from the tblPeople. >>> >>> I have the form with the combobox in place. It is populated with a >>> query selecting the individual's ID, the individual's name, the >>> family name (not always the same as the indifidual's last name), and >>> the assigned family code. The bound column is the PE_ID, which is >>> not displayed. (The family name and code are just so the user can be >>> sure which John Smith is being selected, in case of more than one in >>> the database.) >>> >>> I need help figuring out the rest of this. Any ideas? >>> >>> Thanks, >>> T >>> >>> -- >>> Tina Norris Fields >>> 231-322-2787 >>> tinanfields-at-torchlake-dot-com >>> >>> -- >>> AccessD mailing list >>> AccessD at databaseadvisors.com >>> http://databaseadvisors.com/mailman/listinfo/accessd >>> Website: http://www.databaseadvisors.com >>> >> >> -- >> AccessD mailing list >> AccessD at databaseadvisors.com >> http://databaseadvisors.com/mailman/listinfo/accessd >> Website: http://www.databaseadvisors.com >> >> -- >> AccessD mailing list >> AccessD at databaseadvisors.com >> http://databaseadvisors.com/mailman/listinfo/accessd >> Website: http://www.databaseadvisors.com > > From jamesbutton at blueyonder.co.uk Sun Nov 4 11:21:26 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Sun, 4 Nov 2018 17:21:26 -0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> Message-ID: Use an input box in a similar manner to the I'm not a robot panels So they have to input a different character for each message presentation. The message to include details of the char to input if they are going to select OK, and the alternate for alternative selections . And - leave your phone off Maybe better to also go on a weeks holiday - or a sickie ? JimB -----Original Message----- From: AccessD On Behalf Of Tina N Fields Sent: Sunday, November 4, 2018 4:12 PM To: accessd at databaseadvisors.com Subject: Re: [AccessD] Another challenge I need help with Thanks again, to both of you. Yes, it is unbound. Yes, requery is essential. Progress, T Tina Norris Fields 231-322-2787 tinanfields-at-torchlake-dot-com On 11/4/2018 5:39 AM, Stuart McLachlan wrote: > I assumed that it was an unbound form or at the least that combobox was not bound to a > recordset field if it is a bound form. > > You're correct that you should requery either the combobox or the form if it is bound to > tblPeople. > > On 4 Nov 2018 at 2:03, RockySmolin at bchacc.com wrote: > >> Don?t forget the requery after delete. But would >> DoCommand.RunCommand acCmdDeleteRecord work just as well? >> >> r >> -------- Original Message -------- >> Subject: Re: [AccessD] Another challenge I need help with >> From: "Stuart McLachlan" >> Date: Sat, November 03, 2018 1:00 pm >> To: Access Developers discussion and problem solving >> >> >> The way I do this is something like: >> >> Assuming the bound column is cboPepole is PE_ID, then >> >> Sub CmdDelete_OnClick: >> >> If msgbox,"Are you sure you want to delete this >> record",acYeseNo,"About to delete Record" = vbYes Then >> >> CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & >> cboPeople Msgbox ""Record Deleted" >> >> Else >> >> Msgbox "Deletion cancelled" >> >> End If >> >> End Sub >> >> >> On 3 Nov 2018 at 13:29, Tina N Fields wrote: >> >>> Hi All, >>> >>> Here's what I'm trying to do: >>> >>> A combobox shows the list of individuals in the database >>> The user selects a particular individual from the combovox >>> The user clicks a button to delete that individual's record from the >>> tblPeople A message box pops up to ask "Are you sure you want to >>> permanently delete this record?" The user responds either with a >>> 'Yes" or a "Cancel." If the user clicks "Yes," that individual >>> record is deleted from the tblPeople. >>> >>> I have the form with the combobox in place. It is populated with a >>> query selecting the individual's ID, the individual's name, the >>> family name (not always the same as the indifidual's last name), and >>> the assigned family code. The bound column is the PE_ID, which is >>> not displayed. (The family name and code are just so the user can be >>> sure which John Smith is being selected, in case of more than one in >>> the database.) >>> >>> I need help figuring out the rest of this. Any ideas? >>> >>> Thanks, >>> T >>> >>> -- >>> Tina Norris Fields >>> 231-322-2787 >>> tinanfields-at-torchlake-dot-com >>> >>> -- >>> AccessD mailing list >>> AccessD at databaseadvisors.com >>> http://databaseadvisors.com/mailman/listinfo/accessd >>> Website: http://www.databaseadvisors.com >>> >> >> -- >> AccessD mailing list >> AccessD at databaseadvisors.com >> http://databaseadvisors.com/mailman/listinfo/accessd >> Website: http://www.databaseadvisors.com >> >> -- >> AccessD mailing list >> AccessD at databaseadvisors.com >> http://databaseadvisors.com/mailman/listinfo/accessd >> Website: http://www.databaseadvisors.com > > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From thewaddles at sbcglobal.net Sun Nov 4 12:29:20 2018 From: thewaddles at sbcglobal.net (thewaddles at sbcglobal.net) Date: Sun, 4 Nov 2018 10:29:20 -0800 Subject: [AccessD] Outlook Mail Item relationship between ConversationID and ConversationIndex Message-ID: Hello, I apologize if this is more of an Outlook question than Access, but here goes. I am trying to import Mail Items into two tables. The first table needs to have a primary key based on the Conversation. The second table needs to be related to the first so that One Conversation has Many MailItems. I have found the SearchKey to use as the primary key in the second table but need to find a unique identifier for the first table. Is there a way to relate a conversation and all related emails? The fields I have available are ConversationID ConversationIndex ConversationTopic SearchKey Subject EntryID ReceivedByName RecipientsAddressEntry Sender SenderEmailAddress SenderName SentTo CreationTime ReceivedTime SentOn RecipientsCount Body AttachmentFile AttachmentPath Thank you, Kevin From ssharkins at gmail.com Sun Nov 4 12:34:20 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Sun, 4 Nov 2018 13:34:20 -0500 Subject: [AccessD] Outlook Mail Item relationship between ConversationID and ConversationIndex In-Reply-To: References: Message-ID: <001301d4746d$00a508e0$01ef1aa0$@gmail.com> Interesting -- this might help -- I wouldn't have know it, but it makes sense that ConversationID would be local: Susan H. Hello, I apologize if this is more of an Outlook question than Access, but here goes. I am trying to import Mail Items into two tables. The first table needs to have a primary key based on the Conversation. The second table needs to be related to the first so that One Conversation has Many MailItems. I have found the SearchKey to use as the primary key in the second table but need to find a unique identifier for the first table. Is there a way to relate a conversation and all related emails? The fields I have available are ConversationID ConversationIndex ConversationTopic SearchKey Subject EntryID ReceivedByName RecipientsAddressEntry Sender SenderEmailAddress SenderName SentTo CreationTime ReceivedTime SentOn RecipientsCount Body AttachmentFile AttachmentPath Thank you, Kevin -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Sun Nov 4 13:53:43 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Mon, 05 Nov 2018 05:53:43 +1000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com>, <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg>, Message-ID: <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> Yes, I often do that. I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". In one application I actually had a third one: "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > Maybe it is just my users, but they sometimes need to be protected > from themselves from automatically hitting the enter key whenever a > msgbox is displayed instead of reading the message. Instead of just > acYesNo, I add an option to default to No and to display a question > mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > > Joe O'Connell > > -----Original Message----- > From: AccessD On Behalf Of > Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: Access > Developers discussion and problem solving > Subject: Re: [AccessD] Another > challenge I need help with > > The way I do this is something like: > > Assuming the bound column is cboPepole is PE_ID, then > > Sub CmdDelete_OnClick: > > If msgbox,"Are you sure you want to delete this > record",acYeseNo,"About to delete Record" = vbYes Then > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > cboPeople Msgbox ""Record Deleted" > > Else > > Msgbox "Deletion cancelled" > > End If > > End Sub > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > Hi All, > > > > Here's what I'm trying to do: > > > > A combobox shows the list of individuals in the database The user > > selects a particular individual from the combovox The user clicks a > > button to delete that individual's record from the tblPeople A > > message box pops up to ask "Are you sure you want to permanently > > delete this record?" The user responds either with a 'Yes" or a > > "Cancel." If the user clicks "Yes," that individual record is > > deleted from the tblPeople. > > > > I have the form with the combobox in place. It is populated with a > > query selecting the individual's ID, the individual's name, the > > family name (not always the same as the indifidual's last name), and > > the assigned family code. The bound column is the PE_ID, which is > > not displayed. (The family name and code are just so the user can be > > sure which John Smith is being selected, in case of more than one in > > the database.) > > > > I need help figuring out the rest of this. Any ideas? > > > > Thanks, > > T > > > > -- > > Tina Norris Fields > > 231-322-2787 > > tinanfields-at-torchlake-dot-com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From accessd at shaw.ca Sun Nov 4 14:29:26 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Sun, 4 Nov 2018 13:29:26 -0700 (MST) Subject: [AccessD] Outlook Mail Item relationship between ConversationID and ConversationIndex In-Reply-To: <001301d4746d$00a508e0$01ef1aa0$@gmail.com> References: <001301d4746d$00a508e0$01ef1aa0$@gmail.com> Message-ID: <684570952.198608310.1541363366049.JavaMail.zimbra@shaw.ca> I have always thought the Microsoft's Outlook is a sort of "after thought" product...there just to fill out the product line and provide access to their flag ship Exchange. IMHO, this is why Outlook is always such a bear to automate and filled with security holes...it needs more love. Jim ----- Original Message ----- From: "Susan Harkins" To: "Access Developers discussion and problem solving" Sent: Sunday, November 4, 2018 10:34:20 AM Subject: Re: [AccessD] Outlook Mail Item relationship between ConversationID and ConversationIndex Interesting -- this might help -- I wouldn't have know it, but it makes sense that ConversationID would be local: Susan H. Hello, I apologize if this is more of an Outlook question than Access, but here goes. I am trying to import Mail Items into two tables. The first table needs to have a primary key based on the Conversation. The second table needs to be related to the first so that One Conversation has Many MailItems. I have found the SearchKey to use as the primary key in the second table but need to find a unique identifier for the first table. Is there a way to relate a conversation and all related emails? The fields I have available are ConversationID ConversationIndex ConversationTopic SearchKey Subject EntryID ReceivedByName RecipientsAddressEntry Sender SenderEmailAddress SenderName SentTo CreationTime ReceivedTime SentOn RecipientsCount Body AttachmentFile AttachmentPath Thank you, Kevin -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jbartow at winhaven.net Mon Nov 5 14:02:51 2018 From: jbartow at winhaven.net (John Bartow) Date: Mon, 5 Nov 2018 20:02:51 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com>, <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg>, <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> Message-ID: I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. -----Original Message----- From: AccessD On Behalf Of Stuart McLachlan Sent: Sunday, November 04, 2018 1:54 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Another challenge I need help with Yes, I often do that. I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". In one application I actually had a third one: "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > Maybe it is just my users, but they sometimes need to be protected > from themselves from automatically hitting the enter key whenever a > msgbox is displayed instead of reading the message. Instead of just > acYesNo, I add an option to default to No and to display a question > mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > > Joe O'Connell > > -----Original Message----- > From: AccessD On Behalf Of > Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: Access > Developers discussion and problem solving > Subject: Re: [AccessD] Another > challenge I need help with > > The way I do this is something like: > > Assuming the bound column is cboPepole is PE_ID, then > > Sub CmdDelete_OnClick: > > If msgbox,"Are you sure you want to delete this > record",acYeseNo,"About to delete Record" = vbYes Then > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > cboPeople Msgbox ""Record Deleted" > > Else > > Msgbox "Deletion cancelled" > > End If > > End Sub > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > Hi All, > > > > Here's what I'm trying to do: > > > > A combobox shows the list of individuals in the database The user > > selects a particular individual from the combovox The user clicks a > > button to delete that individual's record from the tblPeople A > > message box pops up to ask "Are you sure you want to permanently > > delete this record?" The user responds either with a 'Yes" or a > > "Cancel." If the user clicks "Yes," that individual record is > > deleted from the tblPeople. > > > > I have the form with the combobox in place. It is populated with a > > query selecting the individual's ID, the individual's name, the > > family name (not always the same as the indifidual's last name), and > > the assigned family code. The bound column is the PE_ID, which is > > not displayed. (The family name and code are just so the user can be > > sure which John Smith is being selected, in case of more than one in > > the database.) > > > > I need help figuring out the rest of this. Any ideas? > > > > Thanks, > > T > > > > -- > > Tina Norris Fields > > 231-322-2787 > > tinanfields-at-torchlake-dot-com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From ssharkins at gmail.com Mon Nov 5 14:46:57 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Mon, 5 Nov 2018 15:46:57 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com>, <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg>, <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> Message-ID: <00e201d47548$b2c224f0$18466ed0$@gmail.com> It's my choice. Deleting data just seems so ... wicked. ? Susan H. I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. From bensonforums at gmail.com Mon Nov 5 17:35:43 2018 From: bensonforums at gmail.com (Bill Benson) Date: Mon, 5 Nov 2018 18:35:43 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> Message-ID: OMG. Deleting users is too much fun to be interfered with like this! >> Use an input box in a similar manner to the I'm not a robot panels >> So they have to input a different character for each message presentation. > > From fuller.artful at gmail.com Tue Nov 6 09:59:51 2018 From: fuller.artful at gmail.com (Arthur Fuller) Date: Tue, 6 Nov 2018 15:59:51 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <20181104020355.86c3debdd1c3983866efe200e2feb95f.afdb4f7902.wbe@email25.godaddy.com> <5BDECC75.15600.9F3F1E0@stuart.lexacorp.com.pg> Message-ID: Now and then I wish there was a keystroke combination that would enable me to delete nations, but also realize that's Version 2.0. In the interim, I'll settle for deleting individuals, and perhaps small groups. In the former category, I'm thinking of certain leaders of certain nations, including Brazil and a couple of others. In the latter category, I'm thinking of a couple of street gangs that have achieved enormous power in L.A., NYC, and even Toronto. Bloods and Crips will do for starters, but we have to add a few more to that list. Google "street gangs in" to know whom I'm talking about. On Mon, Nov 5, 2018 at 11:36 PM Bill Benson wrote: > OMG. > > Deleting users is too much fun to be interfered with like this! > > >> Use an input box in a similar manner to the I'm not a robot panels > >> So they have to input a different character for each message > presentation. > > > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- Arthur From jwcolby at gmail.com Tue Nov 6 10:36:17 2018 From: jwcolby at gmail.com (John Colby) Date: Tue, 6 Nov 2018 11:36:17 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> Message-ID: <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> I designed and used a framework for my forms.? All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records.? Managers were tasked with deleting inactive records if they so desired.? Very few ever did. It was a bit more work of course with reports always filtering out inactive records.? But to be able to "un-delete" records was priceless. On 11/5/2018 3:02 PM, John Bartow wrote: > I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of Stuart McLachlan > Sent: Sunday, November 04, 2018 1:54 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > >> Maybe it is just my users, but they sometimes need to be protected >> from themselves from automatically hitting the enter key whenever a >> msgbox is displayed instead of reading the message. Instead of just >> acYesNo, I add an option to default to No and to display a question >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >> >> Joe O'Connell >> -- John W. Colby From jamesbutton at blueyonder.co.uk Tue Nov 6 10:48:56 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Tue, 6 Nov 2018 16:48:56 -0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: Re undeleting priceless - Definitely ! I'd add having the id of the person specifying the entry deletion and time that they did it is also an essential. And so much easier to note that on the data records as they get set to inactivate. JimB -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Tuesday, November 6, 2018 4:36 PM To: Access Developers discussion and problem solving ; John Bartow Subject: Re: [AccessD] Another challenge I need help with I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. On 11/5/2018 3:02 PM, John Bartow wrote: > I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of Stuart McLachlan > Sent: Sunday, November 04, 2018 1:54 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > >> Maybe it is just my users, but they sometimes need to be protected >> from themselves from automatically hitting the enter key whenever a >> msgbox is displayed instead of reading the message. Instead of just >> acYesNo, I add an option to default to No and to display a question >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >> >> Joe O'Connell >> -- John W. Colby -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jwcolby at gmail.com Tue Nov 6 11:00:19 2018 From: jwcolby at gmail.com (John Colby) Date: Tue, 6 Nov 2018 12:00:19 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: I never did that.? Not sure why.? There could be a longint field for the PEID, DateTime for the delete time.? Over the 180 tables the database ended up being that could turn into a bit of extra storage.? But if useful it would certainly be doable. On 11/6/2018 11:48 AM, James Button via AccessD wrote: > Re undeleting priceless - > > Definitely ! > > I'd add having the id of the person specifying the entry deletion and time that they did it is also an essential. > And so much easier to note that on the data records as they get set to inactivate. > > JimB > > > -----Original Message----- > From: AccessD On Behalf Of John Colby > Sent: Tuesday, November 6, 2018 4:36 PM > To: Access Developers discussion and problem solving ; John Bartow > Subject: Re: [AccessD] Another challenge I need help with > > I designed and used a framework for my forms. All deletes in all tables > (forms) marked records inactive, and re-queried the forms to only show > active records. Managers were tasked with deleting inactive records if > they so desired. Very few ever did. > > It was a bit more work of course with reports always filtering out > inactive records. But to be able to "un-delete" records was priceless. > > > On 11/5/2018 3:02 PM, John Bartow wrote: >> I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. >> >> -----Original Message----- >> From: AccessD On Behalf Of Stuart McLachlan >> Sent: Sunday, November 04, 2018 1:54 PM >> To: Access Developers discussion and problem solving >> Subject: Re: [AccessD] Another challenge I need help with >> >> Yes, I often do that. >> >> I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". >> >> In one application I actually had a third one: >> "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) >> >> >> On 4 Nov 2018 at 15:12, Joe O'Connell wrote: >> >>> Maybe it is just my users, but they sometimes need to be protected >>> from themselves from automatically hitting the enter key whenever a >>> msgbox is displayed instead of reading the message. Instead of just >>> acYesNo, I add an option to default to No and to display a question >>> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >>> >>> Joe O'Connell >>> -- John W. Colby From jbartow at winhaven.net Tue Nov 6 11:53:38 2018 From: jbartow at winhaven.net (John Bartow) Date: Tue, 6 Nov 2018 17:53:38 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: I added date/time stamp and loginID as meta data to every record. It was part of my built-in security. That security allowed the entering "group" (basically govt. department/division) to edit the data and other group to view it. If someone tried to edit the data they weren't allowed to it would present the person/group of who they could request the change be made by. Seemed like a lot of work to change an address but the staff were adamant that it had to be this way. Ah, bureaucracy... -----Original Message----- From: AccessD On Behalf Of James Button via AccessD Sent: Tuesday, November 06, 2018 10:49 AM To: 'Access Developers discussion and problem solving' Cc: James Button Subject: Re: [AccessD] Another challenge I need help with Re undeleting priceless - Definitely ! I'd add having the id of the person specifying the entry deletion and time that they did it is also an essential. And so much easier to note that on the data records as they get set to inactivate. JimB -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Tuesday, November 6, 2018 4:36 PM To: Access Developers discussion and problem solving ; John Bartow Subject: Re: [AccessD] Another challenge I need help with I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. On 11/5/2018 3:02 PM, John Bartow wrote: > I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of Stuart McLachlan > Sent: Sunday, November 04, 2018 1:54 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > >> Maybe it is just my users, but they sometimes need to be protected >> from themselves from automatically hitting the enter key whenever a >> msgbox is displayed instead of reading the message. Instead of just >> acYesNo, I add an option to default to No and to display a question >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >> >> Joe O'Connell >> -- John W. Colby -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jamesbutton at blueyonder.co.uk Tue Nov 6 12:15:10 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Tue, 6 Nov 2018 18:15:10 -0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: Well, Somebody's gotta find the paperwork and annotate that as well as generate the new papers before documenting the need to alter the electronic version. That need will need to be agreed at the periodic management oversight meetings Yay - Prince 2 for a long while! Yup - I've worked for (been employed at) government departments ! And remember - Efficiency is not always as unappreciated as effectiveness! Unless it's in directing blame somewhere away from you (and if possible easily, your immediate associates) JimB -----Original Message----- From: AccessD On Behalf Of John Bartow Sent: Tuesday, November 6, 2018 5:54 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Another challenge I need help with I added date/time stamp and loginID as meta data to every record. It was part of my built-in security. That security allowed the entering "group" (basically govt. department/division) to edit the data and other group to view it. If someone tried to edit the data they weren't allowed to it would present the person/group of who they could request the change be made by. Seemed like a lot of work to change an address but the staff were adamant that it had to be this way. Ah, bureaucracy... -----Original Message----- From: AccessD On Behalf Of James Button via AccessD Sent: Tuesday, November 06, 2018 10:49 AM To: 'Access Developers discussion and problem solving' Cc: James Button Subject: Re: [AccessD] Another challenge I need help with Re undeleting priceless - Definitely ! I'd add having the id of the person specifying the entry deletion and time that they did it is also an essential. And so much easier to note that on the data records as they get set to inactivate. JimB -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Tuesday, November 6, 2018 4:36 PM To: Access Developers discussion and problem solving ; John Bartow Subject: Re: [AccessD] Another challenge I need help with I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. On 11/5/2018 3:02 PM, John Bartow wrote: > I have at least one application where the delete marks the account as inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of Stuart McLachlan > Sent: Sunday, November 04, 2018 1:54 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > >> Maybe it is just my users, but they sometimes need to be protected >> from themselves from automatically hitting the enter key whenever a >> msgbox is displayed instead of reading the message. Instead of just >> acYesNo, I add an option to default to No and to display a question >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >> >> Joe O'Connell >> -- John W. Colby -- From jbartow at winhaven.net Tue Nov 6 13:43:48 2018 From: jbartow at winhaven.net (John Bartow) Date: Tue, 6 Nov 2018 19:43:48 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: Lol, yea, I worked for various levels of government: sanitary district, municipal, county, state and federal (both civilian and military). There's always some process that makes you shake your head in bewilderment. -----Original Message----- From: AccessD On Behalf Of James Button via AccessD Sent: Tuesday, November 06, 2018 12:15 PM To: 'Access Developers discussion and problem solving' Cc: James Button Subject: Re: [AccessD] Another challenge I need help with Well, Somebody's gotta find the paperwork and annotate that as well as generate the new papers before documenting the need to alter the electronic version. That need will need to be agreed at the periodic management oversight meetings Yay - Prince 2 for a long while! Yup - I've worked for (been employed at) government departments ! And remember - Efficiency is not always as unappreciated as effectiveness! Unless it's in directing blame somewhere away from you (and if possible easily, your immediate associates) JimB -----Original Message----- From: AccessD On Behalf Of John Bartow Sent: Tuesday, November 6, 2018 5:54 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Another challenge I need help with I added date/time stamp and loginID as meta data to every record. It was part of my built-in security. That security allowed the entering "group" (basically govt. department/division) to edit the data and other group to view it. If someone tried to edit the data they weren't allowed to it would present the person/group of who they could request the change be made by. Seemed like a lot of work to change an address but the staff were adamant that it had to be this way. Ah, bureaucracy... -----Original Message----- From: AccessD On Behalf Of James Button via AccessD Sent: Tuesday, November 06, 2018 10:49 AM To: 'Access Developers discussion and problem solving' Cc: James Button Subject: Re: [AccessD] Another challenge I need help with Re undeleting priceless - Definitely ! I'd add having the id of the person specifying the entry deletion and time that they did it is also an essential. And so much easier to note that on the data records as they get set to inactivate. JimB -----Original Message----- From: AccessD On Behalf Of John Colby Sent: Tuesday, November 6, 2018 4:36 PM To: Access Developers discussion and problem solving ; John Bartow Subject: Re: [AccessD] Another challenge I need help with I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. On 11/5/2018 3:02 PM, John Bartow wrote: > I have at least one application where the delete marks the account as > inactive rather than actually deleting the record. All displays then filter for active. There's an administrator level function to review inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of > Stuart McLachlan > Sent: Sunday, November 04, 2018 1:54 PM > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Another challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure > that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" > :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > >> Maybe it is just my users, but they sometimes need to be protected >> from themselves from automatically hitting the enter key whenever a >> msgbox is displayed instead of reading the message. Instead of just >> acYesNo, I add an option to default to No and to display a question >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion >> >> Joe O'Connell >> -- John W. Colby -- -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Tue Nov 6 14:59:54 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Wed, 07 Nov 2018 06:59:54 +1000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com>, <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg>, Message-ID: <5BE200CA.17184.16785F06@stuart.lexacorp.com.pg> Agree 100% I very raarely llow deletions.. It makes historical reporting impossible. Like you I favour an activeinactive of IsDeleted flag over actual deletions. On 5 Nov 2018 at 20:02, John Bartow wrote: > I have at least one application where the delete marks the account as > inactive rather than actually deleting the record. All displays then > filter for active. There's an administrator level function to review > inactive accounts with the ability to actually delete the record. > > -----Original Message----- > From: AccessD On Behalf Of > Stuart McLachlan Sent: Sunday, November 04, 2018 1:54 PM To: Access > Developers discussion and problem solving > Subject: Re: [AccessD] Another > challenge I need help with > > Yes, I often do that. > > I also sometimes use a second message that prompts "Are you real sure > that you want to delete this record". > > In one application I actually had a third one: > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" > :) > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > > > Maybe it is just my users, but they sometimes need to be protected > > from themselves from automatically hitting the enter key whenever a > > msgbox is displayed instead of reading the message. Instead of just > > acYesNo, I add an option to default to No and to display a question > > mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > > > > Joe O'Connell > > > > -----Original Message----- > > From: AccessD On Behalf Of > > Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: Access > > Developers discussion and problem solving > > Subject: Re: [AccessD] Another > > challenge I need help with > > > > The way I do this is something like: > > > > Assuming the bound column is cboPepole is PE_ID, then > > > > Sub CmdDelete_OnClick: > > > > If msgbox,"Are you sure you want to delete this > > record",acYeseNo,"About to delete Record" = vbYes Then > > > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > > cboPeople Msgbox ""Record Deleted" > > > > Else > > > > Msgbox "Deletion cancelled" > > > > End If > > > > End Sub > > > > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > > > Hi All, > > > > > > Here's what I'm trying to do: > > > > > > A combobox shows the list of individuals in the database The user > > > selects a particular individual from the combovox The user clicks > > > a button to delete that individual's record from the tblPeople A > > > message box pops up to ask "Are you sure you want to permanently > > > delete this record?" The user responds either with a 'Yes" or a > > > "Cancel." If the user clicks "Yes," that individual record is > > > deleted from the tblPeople. > > > > > > I have the form with the combobox in place. It is populated with a > > > query selecting the individual's ID, the individual's name, the > > > family name (not always the same as the indifidual's last name), > > > and the assigned family code. The bound column is the PE_ID, which > > > is not displayed. (The family name and code are just so the user > > > can be sure which John Smith is being selected, in case of more > > > than one in the database.) > > > > > > I need help figuring out the rest of this. Any ideas? > > > > > > Thanks, > > > T > > > > > > -- > > > Tina Norris Fields > > > 231-322-2787 > > > tinanfields-at-torchlake-dot-com > > > > > > -- > > > AccessD mailing list > > > AccessD at databaseadvisors.com > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > Website: http://www.databaseadvisors.com > > > > > > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From ssharkins at gmail.com Tue Nov 6 16:34:45 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Tue, 6 Nov 2018 17:34:45 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: <038001d47620$ee7da630$cb78f290$@gmail.com> Agreed. They'll tell you they won't need them, but then, they will. Susan H. I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. From fuller.artful at gmail.com Tue Nov 6 18:06:35 2018 From: fuller.artful at gmail.com (Arthur Fuller) Date: Wed, 7 Nov 2018 00:06:35 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <5BE200CA.17184.16785F06@stuart.lexacorp.com.pg> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <5BE200CA.17184.16785F06@stuart.lexacorp.com.pg> Message-ID: Stuart, With all due respect to your brilliance, in this case I think that you are incorrect.I think that a simple Deleted Flag is way wrong> As I tried to demonstrate in my previous email, the database needs to construct the situation as it existed on July 14, 2008, and any other date you might choose.Who were your physicians at that date, and who re your lovers, and your children? All of these are Time-Sensitive, and a simple solution such as your proposed Deleted suggestion just won't cut it. I want to know who your physicians were in 2017 and 2016 and everything backwards. I want to know how many of them have been over-prescribing fentanyl. I don't consider this an issue of privacy, but of criminal investigation. On Tue, Nov 6, 2018 at 9:00 PM Stuart McLachlan wrote: > Agree 100% I very raarely llow deletions.. It makes historical reporting > impossible. Like you > I favour an activeinactive of IsDeleted flag over actual deletions. > > > On 5 Nov 2018 at 20:02, John Bartow wrote: > > > I have at least one application where the delete marks the account as > > inactive rather than actually deleting the record. All displays then > > filter for active. There's an administrator level function to review > > inactive accounts with the ability to actually delete the record. > > > > -----Original Message----- > > From: AccessD On Behalf Of > > Stuart McLachlan Sent: Sunday, November 04, 2018 1:54 PM To: Access > > Developers discussion and problem solving > > Subject: Re: [AccessD] Another > > challenge I need help with > > > > Yes, I often do that. > > > > I also sometimes use a second message that prompts "Are you real sure > > that you want to delete this record". > > > > In one application I actually had a third one: > > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" > > :) > > > > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > > > > > Maybe it is just my users, but they sometimes need to be protected > > > from themselves from automatically hitting the enter key whenever a > > > msgbox is displayed instead of reading the message. Instead of just > > > acYesNo, I add an option to default to No and to display a question > > > mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > > > > > > Joe O'Connell > > > > > > -----Original Message----- > > > From: AccessD On Behalf Of > > > Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: Access > > > Developers discussion and problem solving > > > Subject: Re: [AccessD] Another > > > challenge I need help with > > > > > > The way I do this is something like: > > > > > > Assuming the bound column is cboPepole is PE_ID, then > > > > > > Sub CmdDelete_OnClick: > > > > > > If msgbox,"Are you sure you want to delete this > > > record",acYeseNo,"About to delete Record" = vbYes Then > > > > > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > > > cboPeople Msgbox ""Record Deleted" > > > > > > Else > > > > > > Msgbox "Deletion cancelled" > > > > > > End If > > > > > > End Sub > > > > > > > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > > > > > Hi All, > > > > > > > > Here's what I'm trying to do: > > > > > > > > A combobox shows the list of individuals in the database The user > > > > selects a particular individual from the combovox The user clicks > > > > a button to delete that individual's record from the tblPeople A > > > > message box pops up to ask "Are you sure you want to permanently > > > > delete this record?" The user responds either with a 'Yes" or a > > > > "Cancel." If the user clicks "Yes," that individual record is > > > > deleted from the tblPeople. > > > > > > > > I have the form with the combobox in place. It is populated with a > > > > query selecting the individual's ID, the individual's name, the > > > > family name (not always the same as the indifidual's last name), > > > > and the assigned family code. The bound column is the PE_ID, which > > > > is not displayed. (The family name and code are just so the user > > > > can be sure which John Smith is being selected, in case of more > > > > than one in the database.) > > > > > > > > I need help figuring out the rest of this. Any ideas? > > > > > > > > Thanks, > > > > T > > > > > > > > -- > > > > Tina Norris Fields > > > > 231-322-2787 > > > > tinanfields-at-torchlake-dot-com > > > > > > > > -- > > > > AccessD mailing list > > > > AccessD at databaseadvisors.com > > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > > Website: http://www.databaseadvisors.com > > > > > > > > > > > > > -- > > > AccessD mailing list > > > AccessD at databaseadvisors.com > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > Website: http://www.databaseadvisors.com > > > > > > -- > > > AccessD mailing list > > > AccessD at databaseadvisors.com > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > Website: http://www.databaseadvisors.com > > > > > > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- Arthur From darryl at whittleconsulting.com.au Wed Nov 7 17:05:55 2018 From: darryl at whittleconsulting.com.au (Darryl Collins) Date: Wed, 7 Nov 2018 23:05:55 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: <038001d47620$ee7da630$cb78f290$@gmail.com> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> <038001d47620$ee7da630$cb78f290$@gmail.com> Message-ID: THIS!! I recommend you use both a 'delete' flag PLUS and time and date the record was flagged as inactive / deleted. That way you can know determine when to apply that record to any historical queries (or not). Cheers Darryl. -----Original Message----- From: AccessD On Behalf Of Susan Harkins Sent: Wednesday, 7 November 2018 9:35 AM To: 'Access Developers discussion and problem solving' Subject: Re: [AccessD] Another challenge I need help with Agreed. They'll tell you they won't need them, but then, they will. Susan H. I designed and used a framework for my forms. All deletes in all tables (forms) marked records inactive, and re-queried the forms to only show active records. Managers were tasked with deleting inactive records if they so desired. Very few ever did. It was a bit more work of course with reports always filtering out inactive records. But to be able to "un-delete" records was priceless. -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From darryl at whittleconsulting.com.au Wed Nov 7 17:07:19 2018 From: darryl at whittleconsulting.com.au (Darryl Collins) Date: Wed, 7 Nov 2018 23:07:19 +0000 Subject: [AccessD] Another challenge I need help with In-Reply-To: References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <5BE200CA.17184.16785F06@stuart.lexacorp.com.pg> Message-ID: Hah! I should have read this before replying to Susan's comment. Arthur is correct. A simple 'delete' flag is not that useful. You need to know when the record was flagged as 'deleted' as well. Cheers Darryl -----Original Message----- From: AccessD On Behalf Of Arthur Fuller Sent: Wednesday, 7 November 2018 11:07 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Another challenge I need help with Stuart, With all due respect to your brilliance, in this case I think that you are incorrect.I think that a simple Deleted Flag is way wrong> As I tried to demonstrate in my previous email, the database needs to construct the situation as it existed on July 14, 2008, and any other date you might choose.Who were your physicians at that date, and who re your lovers, and your children? All of these are Time-Sensitive, and a simple solution such as your proposed Deleted suggestion just won't cut it. I want to know who your physicians were in 2017 and 2016 and everything backwards. I want to know how many of them have been over-prescribing fentanyl. I don't consider this an issue of privacy, but of criminal investigation. On Tue, Nov 6, 2018 at 9:00 PM Stuart McLachlan wrote: > Agree 100% I very raarely llow deletions.. It makes historical reporting > impossible. Like you > I favour an activeinactive of IsDeleted flag over actual deletions. > > > On 5 Nov 2018 at 20:02, John Bartow wrote: > > > I have at least one application where the delete marks the account > > as inactive rather than actually deleting the record. All displays > > then filter for active. There's an administrator level function to > > review inactive accounts with the ability to actually delete the record. > > > > -----Original Message----- > > From: AccessD On Behalf Of > > Stuart McLachlan Sent: Sunday, November 04, 2018 1:54 PM To: Access > > Developers discussion and problem solving > > Subject: Re: [AccessD] Another > > challenge I need help with > > > > Yes, I often do that. > > > > I also sometimes use a second message that prompts "Are you real > > sure that you want to delete this record". > > > > In one application I actually had a third one: > > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" > > :) > > > > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > > > > > Maybe it is just my users, but they sometimes need to be protected > > > from themselves from automatically hitting the enter key whenever > > > a msgbox is displayed instead of reading the message. Instead of > > > just acYesNo, I add an option to default to No and to display a > > > question mark so the buttons become > > > vbYesNo+vbDefaultButton2+vbQuestion > > > > > > Joe O'Connell > > > > > > -----Original Message----- > > > From: AccessD On Behalf Of > > > Stuart McLachlan Sent: Saturday, November 3, 2018 4:01 PM To: > > > Access Developers discussion and problem solving > > > Subject: Re: [AccessD] Another > > > challenge I need help with > > > > > > The way I do this is something like: > > > > > > Assuming the bound column is cboPepole is PE_ID, then > > > > > > Sub CmdDelete_OnClick: > > > > > > If msgbox,"Are you sure you want to delete this > > > record",acYeseNo,"About to delete Record" = vbYes Then > > > > > > CurrentDb.Execute "Delete * from tblPeople where PE_ID = " & > > > cboPeople Msgbox ""Record Deleted" > > > > > > Else > > > > > > Msgbox "Deletion cancelled" > > > > > > End If > > > > > > End Sub > > > > > > > > > On 3 Nov 2018 at 13:29, Tina N Fields wrote: > > > > > > > Hi All, > > > > > > > > Here's what I'm trying to do: > > > > > > > > A combobox shows the list of individuals in the database The > > > > user selects a particular individual from the combovox The user > > > > clicks a button to delete that individual's record from the > > > > tblPeople A message box pops up to ask "Are you sure you want to > > > > permanently delete this record?" The user responds either with a > > > > 'Yes" or a "Cancel." If the user clicks "Yes," that individual > > > > record is deleted from the tblPeople. > > > > > > > > I have the form with the combobox in place. It is populated with > > > > a query selecting the individual's ID, the individual's name, > > > > the family name (not always the same as the indifidual's last > > > > name), and the assigned family code. The bound column is the > > > > PE_ID, which is not displayed. (The family name and code are > > > > just so the user can be sure which John Smith is being selected, > > > > in case of more than one in the database.) > > > > > > > > I need help figuring out the rest of this. Any ideas? > > > > > > > > Thanks, > > > > T > > > > > > > > -- > > > > Tina Norris Fields > > > > 231-322-2787 > > > > tinanfields-at-torchlake-dot-com > > > > > > > > -- > > > > AccessD mailing list > > > > AccessD at databaseadvisors.com > > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > > Website: http://www.databaseadvisors.com > > > > > > > > > > > > > -- > > > AccessD mailing list > > > AccessD at databaseadvisors.com > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > Website: http://www.databaseadvisors.com > > > > > > -- > > > AccessD mailing list > > > AccessD at databaseadvisors.com > > > http://databaseadvisors.com/mailman/listinfo/accessd > > > Website: http://www.databaseadvisors.com > > > > > > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- Arthur -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From bensonforums at gmail.com Thu Nov 8 00:36:15 2018 From: bensonforums at gmail.com (Bill Benson) Date: Thu, 8 Nov 2018 01:36:15 -0500 Subject: [AccessD] Another challenge I need help with In-Reply-To: <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> References: <60a39b32-f4b1-dedc-0f66-69137d337456@torchlake.com> <5BDDFE6D.12310.6CF24B2@stuart.lexacorp.com.pg> <5BDF4E47.6586.BEF0DF3@stuart.lexacorp.com.pg> <3da4bad5-851c-b221-2ba0-9bc1e0e5d435@Gmail.com> Message-ID: I think that method caused a problem somewhere down the line. I think there was a situation where they were not using a validly unique identifier. And when they added enough info to "put back" something that had been "deleted" in the fashion you described, OOPS it was not unique after all and could not be added. I forget how they resolved it but since their PK methodology was already flawed, I would not be surprised if they went ahead and made the deleted flag part of the PK as well LOL. On Tue, Nov 6, 2018 at 11:37 AM John Colby wrote: > I designed and used a framework for my forms. All deletes in all tables > (forms) marked records inactive, and re-queried the forms to only show > active records. Managers were tasked with deleting inactive records if > they so desired. Very few ever did. > > It was a bit more work of course with reports always filtering out > inactive records. But to be able to "un-delete" records was priceless. > > > On 11/5/2018 3:02 PM, John Bartow wrote: > > I have at least one application where the delete marks the account as > inactive rather than actually deleting the record. All displays then filter > for active. There's an administrator level function to review inactive > accounts with the ability to actually delete the record. > > > > -----Original Message----- > > From: AccessD On Behalf Of > Stuart McLachlan > > Sent: Sunday, November 04, 2018 1:54 PM > > To: Access Developers discussion and problem solving < > accessd at databaseadvisors.com> > > Subject: Re: [AccessD] Another challenge I need help with > > > > Yes, I often do that. > > > > I also sometimes use a second message that prompts "Are you real sure > that you want to delete this record". > > > > In one application I actually had a third one: > > "LAST CHANCE - ARE you REALLY SURE you want to delete this record!" :) > > > > > > On 4 Nov 2018 at 15:12, Joe O'Connell wrote: > > > >> Maybe it is just my users, but they sometimes need to be protected > >> from themselves from automatically hitting the enter key whenever a > >> msgbox is displayed instead of reading the message. Instead of just > >> acYesNo, I add an option to default to No and to display a question > >> mark so the buttons become vbYesNo+vbDefaultButton2+vbQuestion > >> > >> Joe O'Connell > >> > > -- > John W. Colby > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From darren at activebilling.com.au Tue Nov 20 18:19:30 2018 From: darren at activebilling.com.au (Darren - Active Billing) Date: Wed, 21 Nov 2018 11:19:30 +1100 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised Message-ID: <35FD5543-246C-4FC5-A859-D266B16788C3@activebilling.com.au> Hi Team, Just writing a simple touch pad/num pad for entering numbers into a field (For a Touch screen POS app ? No mouse/keyboard interactions) Found some code on the ?nets and it?s working nicely for the most part except for Backspace/Delete. 12 Buttons on the screen ? All assigned 0 through to 9 and one for ?Enter? and one for ?Backspace/Delete?. Simple enough. Here?s the code Option Compare Database Option Explicit Private Sub TypeAlphaNum(intKeyCode As Integer) ??? Screen.PreviousControl.SetFocus ??? Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) End Sub Private Sub cmd0_Click() ??? TypeAlphaNum vbKey0 End Sub Private Sub cmd1_Click() ??? TypeAlphaNum vbKey1 End Sub Private Sub cmd2_Click() ??? TypeAlphaNum vbKey2 End Sub And so on for all keys/buttons.But it fails in the on click of the Key assigned for vbBackSpace I have also tried vbKeyDelete too ? this one just adds dots to the ?display? The line below just errors out ? Compile Error Variable Not Defined Private Sub cmdBackSpace_Click() ??? TypeAlphaNum vbKeyBackspace End Sub Have also tried Private Sub cmdBackSpace_Click() ??? Dim vbKeyBackspace ?as integer TypeAlphaNum 8 ??and various other combinations of numbers End Sub And this just adds dots at the end of the display Private Sub cmdBackSpace_Click() ??? TypeAlphaNum vbKeyDelete End Sub Any suggestions? Many thanks in advance. Darren From darren at activebilling.com.au Tue Nov 20 20:03:19 2018 From: darren at activebilling.com.au (Darren - Active Billing) Date: Wed, 21 Nov 2018 13:03:19 +1100 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised Message-ID: <4CF1B53E-17CB-44FF-ADFF-C3B0A274CF71@activebilling.com.au> And...ignore me I used Len() minus 1 to resolve it Actual code if anyone is interested: Private Sub cmdBackSpace_Click() On Error Resume Next Dim strText As String strText = Left(txtDisplay, Len(txtDisplay) - 1) txtDisplay = strText End Sub Many thanks. Darren ?On 21/11/18, 11:19 am, "AccessD on behalf of Darren - Active Billing" wrote: Hi Team, Just writing a simple touch pad/num pad for entering numbers into a field (For a Touch screen POS app ? No mouse/keyboard interactions) Found some code on the ?nets and it?s working nicely for the most part except for Backspace/Delete. 12 Buttons on the screen ? All assigned 0 through to 9 and one for ?Enter? and one for ?Backspace/Delete?. Simple enough. Here?s the code Option Compare Database Option Explicit Private Sub TypeAlphaNum(intKeyCode As Integer) Screen.PreviousControl.SetFocus Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) End Sub Private Sub cmd0_Click() TypeAlphaNum vbKey0 End Sub Private Sub cmd1_Click() TypeAlphaNum vbKey1 End Sub Private Sub cmd2_Click() TypeAlphaNum vbKey2 End Sub And so on for all keys/buttons.But it fails in the on click of the Key assigned for vbBackSpace I have also tried vbKeyDelete too ? this one just adds dots to the ?display? The line below just errors out ? Compile Error Variable Not Defined Private Sub cmdBackSpace_Click() TypeAlphaNum vbKeyBackspace End Sub Have also tried Private Sub cmdBackSpace_Click() Dim vbKeyBackspace as integer TypeAlphaNum 8 ?and various other combinations of numbers End Sub And this just adds dots at the end of the display Private Sub cmdBackSpace_Click() TypeAlphaNum vbKeyDelete End Sub Any suggestions? Many thanks in advance. Darren -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From fuller.artful at gmail.com Wed Nov 21 10:17:27 2018 From: fuller.artful at gmail.com (Arthur Fuller) Date: Wed, 21 Nov 2018 16:17:27 +0000 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised In-Reply-To: <4CF1B53E-17CB-44FF-ADFF-C3B0A274CF71@activebilling.com.au> References: <4CF1B53E-17CB-44FF-ADFF-C3B0A274CF71@activebilling.com.au> Message-ID: Clever workaround! But the question (put to MS, not you) is, why is that key not supported? It makes me wonder what other keys on the numpad are not supported, such as "/", "*", "-" and "+", also also the decimal point. Somewhere I had a list of all the vb constants, but cannot locate it at the moment. A quick Google located it: vb constants list , in case anyone's interested. Arthur On Wed, Nov 21, 2018 at 2:04 AM Darren - Active Billing < darren at activebilling.com.au> wrote: > And...ignore me > > I used Len() minus 1 to resolve it > > Actual code if anyone is interested: > > Private Sub cmdBackSpace_Click() > On Error Resume Next > Dim strText As String > strText = Left(txtDisplay, Len(txtDisplay) - 1) > txtDisplay = strText > End Sub > > Many thanks. > > Darren > > > ?On 21/11/18, 11:19 am, "AccessD on behalf of Darren - Active Billing" < > accessd-bounces at databaseadvisors.com on behalf of > darren at activebilling.com.au> wrote: > > Hi Team, > > > > Just writing a simple touch pad/num pad for entering numbers into a > field (For a Touch screen POS app ? No mouse/keyboard interactions) > > > > Found some code on the ?nets and it?s working nicely for the most part > except for Backspace/Delete. > > > > 12 Buttons on the screen ? All assigned 0 through to 9 and one for > ?Enter? and one for ?Backspace/Delete?. Simple enough. > > > > Here?s the code > > > > Option Compare Database > > Option Explicit > > > > Private Sub TypeAlphaNum(intKeyCode As Integer) > > Screen.PreviousControl.SetFocus > > Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) > > End Sub > > > > Private Sub cmd0_Click() > > TypeAlphaNum vbKey0 > > End Sub > > Private Sub cmd1_Click() > > TypeAlphaNum vbKey1 > > End Sub > > Private Sub cmd2_Click() > > TypeAlphaNum vbKey2 > > End Sub > > > > And so on for all keys/buttons.But it fails in the on click of the Key > assigned for vbBackSpace > > > > I have also tried vbKeyDelete too ? this one just adds dots to the > ?display? > > > > > > The line below just errors out ? Compile Error Variable Not Defined > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyBackspace > > End Sub > > > > Have also tried > > > > Private Sub cmdBackSpace_Click() > > Dim vbKeyBackspace as integer > > TypeAlphaNum 8 ?and various other combinations of numbers > > End Sub > > > > > > And this just adds dots at the end of the display > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyDelete > > End Sub > > > > Any suggestions? > > > > Many thanks in advance. > > > > Darren > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- Arthur From paul.hartland at googlemail.com Wed Nov 21 10:27:56 2018 From: paul.hartland at googlemail.com (Paul Hartland) Date: Wed, 21 Nov 2018 16:27:56 +0000 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised In-Reply-To: <35FD5543-246C-4FC5-A859-D266B16788C3@activebilling.com.au> References: <35FD5543-246C-4FC5-A859-D266B16788C3@activebilling.com.au> Message-ID: Darren, Have you tried vbKeyBack for the delete key? Paul On Wed, 21 Nov 2018, 00:20 Darren - Active Billing < darren at activebilling.com.au wrote: > Hi Team, > > > > Just writing a simple touch pad/num pad for entering numbers into a field > (For a Touch screen POS app ? No mouse/keyboard interactions) > > > > Found some code on the ?nets and it?s working nicely for the most part > except for Backspace/Delete. > > > > 12 Buttons on the screen ? All assigned 0 through to 9 and one for ?Enter? > and one for ?Backspace/Delete?. Simple enough. > > > > Here?s the code > > > > Option Compare Database > > Option Explicit > > > > Private Sub TypeAlphaNum(intKeyCode As Integer) > > Screen.PreviousControl.SetFocus > > Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) > > End Sub > > > > Private Sub cmd0_Click() > > TypeAlphaNum vbKey0 > > End Sub > > Private Sub cmd1_Click() > > TypeAlphaNum vbKey1 > > End Sub > > Private Sub cmd2_Click() > > TypeAlphaNum vbKey2 > > End Sub > > > > And so on for all keys/buttons.But it fails in the on click of the Key > assigned for vbBackSpace > > > > I have also tried vbKeyDelete too ? this one just adds dots to the > ?display? > > > > > > The line below just errors out ? Compile Error Variable Not Defined > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyBackspace > > End Sub > > > > Have also tried > > > > Private Sub cmdBackSpace_Click() > > Dim vbKeyBackspace as integer > > TypeAlphaNum 8 ?and various other combinations of numbers > > End Sub > > > > > > And this just adds dots at the end of the display > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyDelete > > End Sub > > > > Any suggestions? > > > > Many thanks in advance. > > > > Darren > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From wrwehler at gmail.com Wed Nov 21 10:47:26 2018 From: wrwehler at gmail.com (Ryan W) Date: Wed, 21 Nov 2018 10:47:26 -0600 Subject: [AccessD] Losing 3ms on date insert? Message-ID: Has anyone seen an issue where: INSERT INTO FOO SELECT * FROM BAR Where FOO and BAR both contain a date column, but when inserted in from MS Access to SQL the date loses 3ms? The first two rows, proper date.. following rows -3ms ? https://i.imgur.com/IYsKCbS.png (Screencap) From BWalsh at healthinsight.org Wed Nov 21 10:47:53 2018 From: BWalsh at healthinsight.org (Bob Walsh) Date: Wed, 21 Nov 2018 16:47:53 +0000 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised In-Reply-To: References: <4CF1B53E-17CB-44FF-ADFF-C3B0A274CF71@activebilling.com.au> Message-ID: Look here too https://docs.microsoft.com/en-us/office/vba/language/reference/user-interface-help/miscellaneous-constants From: AccessD On Behalf Of Arthur Fuller Sent: Wednesday, November 21, 2018 8:17 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised [Attn: This is an external email.] Clever workaround! But the question (put to MS, not you) is, why is that key not supported? It makes me wonder what other keys on the numpad are not supported, such as "/", "*", "-" and "+", also also the decimal point. Somewhere I had a list of all the vb constants, but cannot locate it at the moment. A quick Google located it: vb constants list >, in case anyone's interested. Arthur On Wed, Nov 21, 2018 at 2:04 AM Darren - Active Billing < darren at activebilling.com.au> wrote: > And...ignore me > > I used Len() minus 1 to resolve it > > Actual code if anyone is interested: > > Private Sub cmdBackSpace_Click() > On Error Resume Next > Dim strText As String > strText = Left(txtDisplay, Len(txtDisplay) - 1) > txtDisplay = strText > End Sub > > Many thanks. > > Darren > > > ?On 21/11/18, 11:19 am, "AccessD on behalf of Darren - Active Billing" < > accessd-bounces at databaseadvisors.com on behalf of > darren at activebilling.com.au> wrote: > > Hi Team, > > > > Just writing a simple touch pad/num pad for entering numbers into a > field (For a Touch screen POS app ? No mouse/keyboard interactions) > > > > Found some code on the ?nets and it?s working nicely for the most part > except for Backspace/Delete. > > > > 12 Buttons on the screen ? All assigned 0 through to 9 and one for > ?Enter? and one for ?Backspace/Delete?. Simple enough. > > > > Here?s the code > > > > Option Compare Database > > Option Explicit > > > > Private Sub TypeAlphaNum(intKeyCode As Integer) > > Screen.PreviousControl.SetFocus > > Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) > > End Sub > > > > Private Sub cmd0_Click() > > TypeAlphaNum vbKey0 > > End Sub > > Private Sub cmd1_Click() > > TypeAlphaNum vbKey1 > > End Sub > > Private Sub cmd2_Click() > > TypeAlphaNum vbKey2 > > End Sub > > > > And so on for all keys/buttons.But it fails in the on click of the Key > assigned for vbBackSpace > > > > I have also tried vbKeyDelete too ? this one just adds dots to the > ?display? > > > > > > The line below just errors out ? Compile Error Variable Not Defined > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyBackspace > > End Sub > > > > Have also tried > > > > Private Sub cmdBackSpace_Click() > > Dim vbKeyBackspace as integer > > TypeAlphaNum 8 ?and various other combinations of numbers > > End Sub > > > > > > And this just adds dots at the end of the display > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyDelete > > End Sub > > > > Any suggestions? > > > > Many thanks in advance. > > > > Darren > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- Arthur -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com ________________________________ HealthInsight is a private, nonprofit, community-based organization dedicated to improving health and health care, with offices in four western states: Nevada, New Mexico, Oregon and Utah. HealthInsight also has operations in Seattle, Wash., and Glendale, Calif., supporting End-Stage Renal Disease Networks in the Western United States. The information and any materials included in this transmission may contain confidential information from HealthInsight. The information is intended for use by the person named on this transmittal. If you are not the intended recipient, be aware that any disclosure, copying, distribution, or use of the contents of this transmission is prohibited. If you have received this message in error, please inform the sender and delete all copies. From df.waters at outlook.com Wed Nov 21 10:53:46 2018 From: df.waters at outlook.com (Daniel Waters) Date: Wed, 21 Nov 2018 16:53:46 +0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Is the Access file and the SQL Server on the same PC? Or on a PC where SQL Server is on a Server? -----Original Message----- From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Ryan W Sent: November 21, 2018 10:47 To: Access Developers discussion and problem solving Subject: [AccessD] Losing 3ms on date insert? Has anyone seen an issue where: INSERT INTO FOO SELECT * FROM BAR Where FOO and BAR both contain a date column, but when inserted in from MS Access to SQL the date loses 3ms? The first two rows, proper date.. following rows -3ms ? https://i.imgur.com/IYsKCbS.png (Screencap) -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From wrwehler at gmail.com Wed Nov 21 11:33:27 2018 From: wrwehler at gmail.com (Ryan W) Date: Wed, 21 Nov 2018 11:33:27 -0600 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: No SQL Server is on a VM... but these are 'set' dates, not using GETDATE() or DATE() or a function where a tiny time discrepancy like that might show up. So the source table has 11/20/2018 16:00 as the date, but the destination table, after the first two rows gets rolled back by 3ms for some reason. On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters wrote: > Is the Access file and the SQL Server on the same PC? Or on a PC where > SQL Server is on a Server? > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > Ryan W > Sent: November 21, 2018 10:47 > To: Access Developers discussion and problem solving > Subject: [AccessD] Losing 3ms on date insert? > > Has anyone seen an issue where: > > INSERT INTO FOO SELECT * FROM BAR > > Where FOO and BAR both contain a date column, but when inserted in from MS > Access to SQL the date loses 3ms? > > > The first two rows, proper date.. following rows -3ms ? > > https://i.imgur.com/IYsKCbS.png (Screencap) > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From df.waters at outlook.com Wed Nov 21 11:39:19 2018 From: df.waters at outlook.com (Daniel Waters) Date: Wed, 21 Nov 2018 17:39:19 +0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: That is a puzzle - I have no answer. :-( Dan -----Original Message----- From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Ryan W Sent: November 21, 2018 11:33 To: Access Developers discussion and problem solving Subject: Re: [AccessD] Losing 3ms on date insert? No SQL Server is on a VM... but these are 'set' dates, not using GETDATE() or DATE() or a function where a tiny time discrepancy like that might show up. So the source table has 11/20/2018 16:00 as the date, but the destination table, after the first two rows gets rolled back by 3ms for some reason. On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters wrote: > Is the Access file and the SQL Server on the same PC? Or on a PC where > SQL Server is on a Server? > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > Ryan W > Sent: November 21, 2018 10:47 > To: Access Developers discussion and problem solving > Subject: [AccessD] Losing 3ms on date insert? > > Has anyone seen an issue where: > > INSERT INTO FOO SELECT * FROM BAR > > Where FOO and BAR both contain a date column, but when inserted in from MS > Access to SQL the date loses 3ms? > > > The first two rows, proper date.. following rows -3ms ? > > https://i.imgur.com/IYsKCbS.png (Screencap) > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From gustav at cactus.dk Wed Nov 21 12:14:57 2018 From: gustav at cactus.dk (Gustav Brock) Date: Wed, 21 Nov 2018 18:14:57 +0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Hi Ryan That is due to the limited resolution of data type DateTime of SQL Server. Use DateTime2 if you want a precise recording. I've even created a function to exactly simulate that low resolution given input having a millisecond part (which VBA and Access is able to handle if you are not aware). It's all in the in-line comments: ' Returns Date1 rounded to the nearest millisecond approximately by 4/5. ' The dividing point for up/down rounding may vary between 0.3 and 0.7ms ' due to the limited resolution of data type Double. ' ' If RoundSqlServer is True, milliseconds are rounded by 3.333ms to match ' the rounding of the Datetime data type of SQL Server - to 0, 3 or 7 as the ' least significant digit: ' ' Msec SqlServer ' 0 0 ' 1 0 ' 2 3 ' 3 3 ' 4 3 ' 5 7 ' 6 7 ' 7 7 ' 8 7 ' 9 10 ' 10 10 ' 11 10 ' 12 13 ' 13 13 ' 14 13 ' 15 17 ' 16 17 ' 17 17 ' 18 17 ' 19 20 ' ... ' 990 990 ' 991 990 ' 992 993 ' 993 993 ' 994 993 ' 995 997 ' 996 997 ' 997 997 ' 998 997 ' 999 1000 ' ' If RoundSqlServer is True and if RoundSecondUp is True, 999ms will be ' rounded up to 1000ms - the next second - which may not be what you wish. ' If RoundSecondUp is False, 999ms will be rounded down to 997ms: ' ' 994 993 ' 995 997 ' 996 997 ' 997 997 ' 998 997 ' 999 997 ' ' If RoundSqlServer is False, RoundSecondUp is ignored. ' ' 2016-09-14. Gustav Brock, Cactus Data ApS, CPH. ' Public Function DateRoundMillisecond( _ ByVal Date1 As Date, _ Optional RoundSqlServer As Boolean, _ Optional RoundSecondUp As Boolean) _ As Date Dim Milliseconds As Integer Dim MsecValue As Date Dim Result As Date ' Retrieve the millisecond part of Date1. Milliseconds = Millisecond(Date1) If RoundSqlServer = True Then ' Perform special rounding to match data type datetime of SQL Server. Milliseconds = (Milliseconds \ 10) * 10 + Choose(Milliseconds Mod 10 + 1, 0, 0, 3, 3, 3, 7, 7, 7, 7, 10) If RoundSecondUp = False Then If Milliseconds = 1000 Then Milliseconds = 997 End If End If End If ' Round Date1 down to the second. Call RoundOffMilliseconds(Date1) ' Get milliseconds as date value. MsecValue = MsecSerial(Milliseconds) ' Add milliseconds to rounded date. Result = DateFromTimespan(DateToTimespan(Date1) + DateToTimespan(MsecValue)) DateRoundMillisecond = Result End Function As you can see, a couple of helper functions are used - their names should indicate their doings. If you are interested, I can post these as well. /gustav From wrwehler at gmail.com Wed Nov 21 12:17:42 2018 From: wrwehler at gmail.com (Ryan W) Date: Wed, 21 Nov 2018 12:17:42 -0600 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Huh, that's odd. I don't see why we're losing 3ms on a static date and time, though. The date is 11/20/2018 16:00.. the first two entries are a-ok, but subsequent ones get bonked down 3ms. I'm expecting 'precise' to the second, not millisecond in this case. On Wed, Nov 21, 2018 at 12:16 PM Gustav Brock wrote: > Hi Ryan > > That is due to the limited resolution of data type DateTime of SQL Server. > Use DateTime2 if you want a precise recording. > > I've even created a function to exactly simulate that low resolution given > input having a millisecond part (which VBA and Access is able to handle if > you are not aware). It's all in the in-line comments: > > > ' Returns Date1 rounded to the nearest millisecond approximately by 4/5. > ' The dividing point for up/down rounding may vary between 0.3 and 0.7ms > ' due to the limited resolution of data type Double. > ' > ' If RoundSqlServer is True, milliseconds are rounded by 3.333ms to match > ' the rounding of the Datetime data type of SQL Server - to 0, 3 or 7 as > the > ' least significant digit: > ' > ' Msec SqlServer > ' 0 0 > ' 1 0 > ' 2 3 > ' 3 3 > ' 4 3 > ' 5 7 > ' 6 7 > ' 7 7 > ' 8 7 > ' 9 10 > ' 10 10 > ' 11 10 > ' 12 13 > ' 13 13 > ' 14 13 > ' 15 17 > ' 16 17 > ' 17 17 > ' 18 17 > ' 19 20 > ' ... > ' 990 990 > ' 991 990 > ' 992 993 > ' 993 993 > ' 994 993 > ' 995 997 > ' 996 997 > ' 997 997 > ' 998 997 > ' 999 1000 > ' > ' If RoundSqlServer is True and if RoundSecondUp is True, 999ms will be > ' rounded up to 1000ms - the next second - which may not be what you wish. > ' If RoundSecondUp is False, 999ms will be rounded down to 997ms: > ' > ' 994 993 > ' 995 997 > ' 996 997 > ' 997 997 > ' 998 997 > ' 999 997 > ' > ' If RoundSqlServer is False, RoundSecondUp is ignored. > ' > ' 2016-09-14. Gustav Brock, Cactus Data ApS, CPH. > ' > Public Function DateRoundMillisecond( _ > ByVal Date1 As Date, _ > Optional RoundSqlServer As Boolean, _ > Optional RoundSecondUp As Boolean) _ > As Date > > Dim Milliseconds As Integer > Dim MsecValue As Date > Dim Result As Date > > ' Retrieve the millisecond part of Date1. > Milliseconds = Millisecond(Date1) > If RoundSqlServer = True Then > ' Perform special rounding to match data type datetime of SQL > Server. > Milliseconds = (Milliseconds \ 10) * 10 + Choose(Milliseconds Mod > 10 + 1, 0, 0, 3, 3, 3, 7, 7, 7, 7, 10) > If RoundSecondUp = False Then > If Milliseconds = 1000 Then > Milliseconds = 997 > End If > End If > End If > > ' Round Date1 down to the second. > Call RoundOffMilliseconds(Date1) > ' Get milliseconds as date value. > MsecValue = MsecSerial(Milliseconds) > ' Add milliseconds to rounded date. > Result = DateFromTimespan(DateToTimespan(Date1) + > DateToTimespan(MsecValue)) > > DateRoundMillisecond = Result > > End Function > > > As you can see, a couple of helper functions are used - their names should > indicate their doings. If you are interested, I can post these as well. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From gustav at cactus.dk Wed Nov 21 12:25:24 2018 From: gustav at cactus.dk (Gustav Brock) Date: Wed, 21 Nov 2018 18:25:24 +0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: , Message-ID: Hi Ryan Maybe that static date isn't that static. How do run/call this code, and how was the date stored? /gustav ________________________________________ Fra: AccessD p? vegne af Ryan W Sendt: 21. november 2018 19:17 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? Huh, that's odd. I don't see why we're losing 3ms on a static date and time, though. The date is 11/20/2018 16:00.. the first two entries are a-ok, but subsequent ones get bonked down 3ms. I'm expecting 'precise' to the second, not millisecond in this case. On Wed, Nov 21, 2018 at 12:16 PM Gustav Brock wrote: > Hi Ryan > > That is due to the limited resolution of data type DateTime of SQL Server. > Use DateTime2 if you want a precise recording. > > I've even created a function to exactly simulate that low resolution given > input having a millisecond part (which VBA and Access is able to handle if > you are not aware). It's all in the in-line comments: > > > ' Returns Date1 rounded to the nearest millisecond approximately by 4/5. > ' The dividing point for up/down rounding may vary between 0.3 and 0.7ms > ' due to the limited resolution of data type Double. > ' > ' If RoundSqlServer is True, milliseconds are rounded by 3.333ms to match > ' the rounding of the Datetime data type of SQL Server - to 0, 3 or 7 as > the > ' least significant digit: > ' > ' Msec SqlServer > ' 0 0 > ' 1 0 > ' 2 3 > ' 3 3 > ' 4 3 > ' 5 7 > ' 6 7 > ' 7 7 > ' 8 7 > ' 9 10 > ' 10 10 > ' 11 10 > ' 12 13 > ' 13 13 > ' 14 13 > ' 15 17 > ' 16 17 > ' 17 17 > ' 18 17 > ' 19 20 > ' ... > ' 990 990 > ' 991 990 > ' 992 993 > ' 993 993 > ' 994 993 > ' 995 997 > ' 996 997 > ' 997 997 > ' 998 997 > ' 999 1000 > ' > ' If RoundSqlServer is True and if RoundSecondUp is True, 999ms will be > ' rounded up to 1000ms - the next second - which may not be what you wish. > ' If RoundSecondUp is False, 999ms will be rounded down to 997ms: > ' > ' 994 993 > ' 995 997 > ' 996 997 > ' 997 997 > ' 998 997 > ' 999 997 > ' > ' If RoundSqlServer is False, RoundSecondUp is ignored. > ' > ' 2016-09-14. Gustav Brock, Cactus Data ApS, CPH. > ' > Public Function DateRoundMillisecond( _ > ByVal Date1 As Date, _ > Optional RoundSqlServer As Boolean, _ > Optional RoundSecondUp As Boolean) _ > As Date > > Dim Milliseconds As Integer > Dim MsecValue As Date > Dim Result As Date > > ' Retrieve the millisecond part of Date1. > Milliseconds = Millisecond(Date1) > If RoundSqlServer = True Then > ' Perform special rounding to match data type datetime of SQL > Server. > Milliseconds = (Milliseconds \ 10) * 10 + Choose(Milliseconds Mod > 10 + 1, 0, 0, 3, 3, 3, 7, 7, 7, 7, 10) > If RoundSecondUp = False Then > If Milliseconds = 1000 Then > Milliseconds = 997 > End If > End If > End If > > ' Round Date1 down to the second. > Call RoundOffMilliseconds(Date1) > ' Get milliseconds as date value. > MsecValue = MsecSerial(Milliseconds) > ' Add milliseconds to rounded date. > Result = DateFromTimespan(DateToTimespan(Date1) + > DateToTimespan(MsecValue)) > > DateRoundMillisecond = Result > > End Function > > > As you can see, a couple of helper functions are used - their names should > indicate their doings. If you are interested, I can post these as well. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- From jamesbutton at blueyonder.co.uk Wed Nov 21 12:26:11 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Wed, 21 Nov 2018 18:26:11 -0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: For that small amount I'd be looking at the internal formats used on the source & destination systems as well as the way the value is held in the transferring media Probably one of them is not holding enough decimal places (or allowing a big enough n in 2-n) in the storage of the value, so is rounding And, as it is only milliseconds, maybe round to the nearest second would deal with the visibility of the glitch. The date and time being held, by Excel as in 43424.6666666667 And rounding it up to the 7th place as in adding 0.00000003 to get 43424.66666667 May be the reason for the extra 3 milliseconds being indicated While 43424.66666668 shows 4 milliseconds. And ... that is the perennial problem with the inexperienced use of computers Well, that and that the books and teachers rarely mention such things - so the first you know is when it bites you and only the fortunate get to notice it in their work before it becomes a public humiliation That - and the other major pain - people who do NOT check that cash values are not only shown as being in bankable portions of the currency - but are actually the same value as is being shown e.g. $1 split into thirds is 1/3 + 1/3 +1/3 and for the computer the total of 1/3 + 1/3 +1/3 does NOT = 1.00 So - validation should be dealing with whole cents when the checking has 0.99 not = 1.00 or the split of the value needs to have the last portion being the base value less the sum of the other portions, or management have to specify some other process to deal with the many little bits. And the coder should consider if(abs(a-b)<0.000limit) rather than if a=b or if a-b=0. JimB -----Original Message----- From: AccessD On Behalf Of Daniel Waters Sent: Wednesday, November 21, 2018 5:39 PM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Losing 3ms on date insert? That is a puzzle - I have no answer. :-( Dan -----Original Message----- From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Ryan W Sent: November 21, 2018 11:33 To: Access Developers discussion and problem solving Subject: Re: [AccessD] Losing 3ms on date insert? No SQL Server is on a VM... but these are 'set' dates, not using GETDATE() or DATE() or a function where a tiny time discrepancy like that might show up. So the source table has 11/20/2018 16:00 as the date, but the destination table, after the first two rows gets rolled back by 3ms for some reason. On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters wrote: > Is the Access file and the SQL Server on the same PC? Or on a PC where > SQL Server is on a Server? > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > Ryan W > Sent: November 21, 2018 10:47 > To: Access Developers discussion and problem solving > Subject: [AccessD] Losing 3ms on date insert? > > Has anyone seen an issue where: > > INSERT INTO FOO SELECT * FROM BAR > > Where FOO and BAR both contain a date column, but when inserted in from MS > Access to SQL the date loses 3ms? > > > The first two rows, proper date.. following rows -3ms ? > > https://i.imgur.com/IYsKCbS.png (Screencap) > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From wrwehler at gmail.com Wed Nov 21 12:27:18 2018 From: wrwehler at gmail.com (Ryan W) Date: Wed, 21 Nov 2018 12:27:18 -0600 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Date is stored in a local table on the MS Access side Then an insert into remoteTbl select * from localTbl is performed to move it server side where some more processing happens a bit later. On Wed, Nov 21, 2018 at 12:26 PM Gustav Brock wrote: > Hi Ryan > > Maybe that static date isn't that static. > > How do run/call this code, and how was the date stored? > > /gustav > ________________________________________ > Fra: AccessD p? vegne af Ryan W < > wrwehler at gmail.com> > Sendt: 21. november 2018 19:17 > Til: Access Developers discussion and problem solving > Emne: Re: [AccessD] Losing 3ms on date insert? > > Huh, that's odd. I don't see why we're losing 3ms on a static date and > time, though. The date is 11/20/2018 16:00.. the first two entries are > a-ok, but subsequent ones get bonked down 3ms. I'm expecting 'precise' to > the second, not millisecond in this case. > > > On Wed, Nov 21, 2018 at 12:16 PM Gustav Brock wrote: > > > Hi Ryan > > > > That is due to the limited resolution of data type DateTime of SQL > Server. > > Use DateTime2 if you want a precise recording. > > > > I've even created a function to exactly simulate that low resolution > given > > input having a millisecond part (which VBA and Access is able to > handle if > > you are not aware). It's all in the in-line comments: > > > > > > ' Returns Date1 rounded to the nearest millisecond approximately by > 4/5. > > ' The dividing point for up/down rounding may vary between 0.3 and > 0.7ms > > ' due to the limited resolution of data type Double. > > ' > > ' If RoundSqlServer is True, milliseconds are rounded by 3.333ms to > match > > ' the rounding of the Datetime data type of SQL Server - to 0, 3 or 7 > as > > the > > ' least significant digit: > > ' > > ' Msec SqlServer > > ' 0 0 > > ' 1 0 > > ' 2 3 > > ' 3 3 > > ' 4 3 > > ' 5 7 > > ' 6 7 > > ' 7 7 > > ' 8 7 > > ' 9 10 > > ' 10 10 > > ' 11 10 > > ' 12 13 > > ' 13 13 > > ' 14 13 > > ' 15 17 > > ' 16 17 > > ' 17 17 > > ' 18 17 > > ' 19 20 > > ' ... > > ' 990 990 > > ' 991 990 > > ' 992 993 > > ' 993 993 > > ' 994 993 > > ' 995 997 > > ' 996 997 > > ' 997 997 > > ' 998 997 > > ' 999 1000 > > ' > > ' If RoundSqlServer is True and if RoundSecondUp is True, 999ms will > be > > ' rounded up to 1000ms - the next second - which may not be what you > wish. > > ' If RoundSecondUp is False, 999ms will be rounded down to 997ms: > > ' > > ' 994 993 > > ' 995 997 > > ' 996 997 > > ' 997 997 > > ' 998 997 > > ' 999 997 > > ' > > ' If RoundSqlServer is False, RoundSecondUp is ignored. > > ' > > ' 2016-09-14. Gustav Brock, Cactus Data ApS, CPH. > > ' > > Public Function DateRoundMillisecond( _ > > ByVal Date1 As Date, _ > > Optional RoundSqlServer As Boolean, _ > > Optional RoundSecondUp As Boolean) _ > > As Date > > > > Dim Milliseconds As Integer > > Dim MsecValue As Date > > Dim Result As Date > > > > ' Retrieve the millisecond part of Date1. > > Milliseconds = Millisecond(Date1) > > If RoundSqlServer = True Then > > ' Perform special rounding to match data type datetime of SQL > > Server. > > Milliseconds = (Milliseconds \ 10) * 10 + Choose(Milliseconds > Mod > > 10 + 1, 0, 0, 3, 3, 3, 7, 7, 7, 7, 10) > > If RoundSecondUp = False Then > > If Milliseconds = 1000 Then > > Milliseconds = 997 > > End If > > End If > > End If > > > > ' Round Date1 down to the second. > > Call RoundOffMilliseconds(Date1) > > ' Get milliseconds as date value. > > MsecValue = MsecSerial(Milliseconds) > > ' Add milliseconds to rounded date. > > Result = DateFromTimespan(DateToTimespan(Date1) + > > DateToTimespan(MsecValue)) > > > > DateRoundMillisecond = Result > > > > End Function > > > > > > As you can see, a couple of helper functions are used - their names > should > > indicate their doings. If you are interested, I can post these as > well. > > > > /gustav > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > -- > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From wrwehler at gmail.com Wed Nov 21 12:29:26 2018 From: wrwehler at gmail.com (Ryan W) Date: Wed, 21 Nov 2018 12:29:26 -0600 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Date/Time in MS Access DateTime in SQL Server It IS coming from excel, formatted as mm/dd/yyyy hh:mm (custom format) The dates are accurate in MS Access, but somehow we lose 3ms when pushing the data to SQL Server (2008). Oddly this problem seems to have only cropped up semi recently. On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < accessd at databaseadvisors.com> wrote: > For that small amount I'd be looking at the internal formats used on the > source > & destination systems as well as the way the value is held in the > transferring > media > Probably one of them is not holding enough decimal places (or allowing a > big > enough n in 2-n) in the storage of the value, so is rounding > And, as it is only milliseconds, maybe round to the nearest second would > deal > with the visibility of the glitch. > > The date and time being held, by Excel as in 43424.6666666667 > And rounding it up to the 7th place as in adding 0.00000003 to get > 43424.66666667 > May be the reason for the extra 3 milliseconds being indicated > While 43424.66666668 shows 4 milliseconds. > > And ... that is the perennial problem with the inexperienced use of > computers > Well, that and that the books and teachers rarely mention such things - so > the > first you know is when it bites you > and only the fortunate get to notice it in their work before it becomes a > public > humiliation > > That - and the other major pain - people who do NOT check that cash values > are > not only shown as being in bankable portions of the currency - but are > actually > the same value as is being shown > e.g. $1 split into thirds is 1/3 + 1/3 +1/3 and for the computer the total > of > 1/3 + 1/3 +1/3 does NOT = 1.00 > So - validation should be dealing with whole cents when the checking has > 0.99 > not = 1.00 > or the split of the value needs to have the last portion being the base > value > less the sum of the other portions, > or management have to specify some other process to deal with the many > little > bits. > And the coder should consider if(abs(a-b)<0.000limit) rather than if a=b > or if > a-b=0. > > JimB > > > > > -----Original Message----- > From: AccessD On Behalf Of Daniel > Waters > Sent: Wednesday, November 21, 2018 5:39 PM > To: Access Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on date insert? > > That is a puzzle - I have no answer. :-( > > Dan > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > Ryan W > Sent: November 21, 2018 11:33 > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Losing 3ms on date insert? > > No SQL Server is on a VM... but these are 'set' dates, not using GETDATE() > or DATE() or a function where a tiny time discrepancy like that might show > up. > > So the source table has 11/20/2018 16:00 as the date, but the destination > table, after the first two rows gets rolled back by 3ms for some reason. > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > wrote: > > > Is the Access file and the SQL Server on the same PC? Or on a PC where > > SQL Server is on a Server? > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > > Ryan W > > Sent: November 21, 2018 10:47 > > To: Access Developers discussion and problem solving > > Subject: [AccessD] Losing 3ms on date insert? > > > > Has anyone seen an issue where: > > > > INSERT INTO FOO SELECT * FROM BAR > > > > Where FOO and BAR both contain a date column, but when inserted in from > MS > > Access to SQL the date loses 3ms? > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > https://i.imgur.com/IYsKCbS.png (Screencap) > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From gustav at cactus.dk Wed Nov 21 12:44:06 2018 From: gustav at cactus.dk (Gustav Brock) Date: Wed, 21 Nov 2018 18:44:06 +0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: , Message-ID: Hi Rayn Maybe you should check those values retrieved from Excel. The format has no importance, it is the value that counts, and Access will not natively reveal a millisecond difference. You can check if milliseconds are present with this code: Public Const MillisecondsPerSecond As Long = 10 ^ 3 Public Const MicrosecondsPerSecond As Long = 10 ^ 6 Public Const NanosecondsPerSecond As Long = 10 ^ 9 Public Const MinutesPerDay As Long = HoursPerDay * MinutesPerHour Public Const SecondsPerHour As Long = MinutesPerHour * SecondsPerMinute Public Const SecondsPerDay As Long = HoursPerDay * SecondsPerHour Public Const MillisecondsPerMinute As Long = SecondsPerMinute * MillisecondsPerSecond Public Const MillisecondsPerDay As Long = SecondsPerDay * MillisecondsPerSecond ' Returns the millisecond part from Date1. ' ' 2016-09-15. Gustav Brock, Cactus Data ApS, CPH. ' Public Function Millisecond( _ ByVal Date1 As Date) _ As Integer Dim Milliseconds As Integer ' Remove date part from date/time value and extract count of milliseconds. ' Note the use of CDec() to prevent bit errors for very large date values. Milliseconds = Abs(Date1 - CDec(Fix(Date1))) * MillisecondsPerDay Mod MillisecondsPerSecond Millisecond = Milliseconds End Function If that is the case, round the values before storing them using my function posted before. /gustav From darren at activebilling.com.au Wed Nov 21 22:17:27 2018 From: darren at activebilling.com.au (Darren - Active Billing) Date: Thu, 22 Nov 2018 15:17:27 +1100 Subject: [AccessD] A2010: vbBackspace or vbKeyDelete not recognised In-Reply-To: References: <35FD5543-246C-4FC5-A859-D266B16788C3@activebilling.com.au> Message-ID: Hi Paul, Thanks for the suggestion - Sadly...no joy. I added vbKeyBack to the sub, then clicked it 3 times, and ended up with 3 x odd characters. Sample image here: https://s3.ap-southeast-2.amazonaws.com/assets.activebilling.com.au/Demo/NumPad.png? Many thanks again for the suggestion - I have reverted to the Len() minus 1 option. Darren ------------ ?On 22/11/18, 3:27 am, "AccessD on behalf of Paul Hartland via AccessD" wrote: Darren, Have you tried vbKeyBack for the delete key? Paul On Wed, 21 Nov 2018, 00:20 Darren - Active Billing < darren at activebilling.com.au wrote: > Hi Team, > > > > Just writing a simple touch pad/num pad for entering numbers into a field > (For a Touch screen POS app ? No mouse/keyboard interactions) > > > > Found some code on the ?nets and it?s working nicely for the most part > except for Backspace/Delete. > > > > 12 Buttons on the screen ? All assigned 0 through to 9 and one for ?Enter? > and one for ?Backspace/Delete?. Simple enough. > > > > Here?s the code > > > > Option Compare Database > > Option Explicit > > > > Private Sub TypeAlphaNum(intKeyCode As Integer) > > Screen.PreviousControl.SetFocus > > Me.txtDisplay.Value = Me.txtDisplay.Value & Chr(intKeyCode) > > End Sub > > > > Private Sub cmd0_Click() > > TypeAlphaNum vbKey0 > > End Sub > > Private Sub cmd1_Click() > > TypeAlphaNum vbKey1 > > End Sub > > Private Sub cmd2_Click() > > TypeAlphaNum vbKey2 > > End Sub > > > > And so on for all keys/buttons.But it fails in the on click of the Key > assigned for vbBackSpace > > > > I have also tried vbKeyDelete too ? this one just adds dots to the > ?display? > > > > > > The line below just errors out ? Compile Error Variable Not Defined > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyBackspace > > End Sub > > > > Have also tried > > > > Private Sub cmdBackSpace_Click() > > Dim vbKeyBackspace as integer > > TypeAlphaNum 8 ?and various other combinations of numbers > > End Sub > > > > > > And this just adds dots at the end of the display > > > > Private Sub cmdBackSpace_Click() > > TypeAlphaNum vbKeyDelete > > End Sub > > > > Any suggestions? > > > > Many thanks in advance. > > > > Darren > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From bensonforums at gmail.com Fri Nov 23 21:11:59 2018 From: bensonforums at gmail.com (Bill Benson) Date: Fri, 23 Nov 2018 22:11:59 -0500 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Maybe irrelevant but are you using the .value property of an Excel range or Value2? I think the latter has more precision, but unfortunately .Value is all you can copy into an array, as it is the default property? Just a hunch, not tested. On Wed, Nov 21, 2018, 1:45 PM Gustav Brock Hi Rayn > > Maybe you should check those values retrieved from Excel. The format has > no importance, it is the value that counts, and Access will not natively > reveal a millisecond difference. > > You can check if milliseconds are present with this code: > > > Public Const MillisecondsPerSecond As Long = 10 ^ 3 > Public Const MicrosecondsPerSecond As Long = 10 ^ 6 > Public Const NanosecondsPerSecond As Long = 10 ^ 9 > Public Const MinutesPerDay As Long = HoursPerDay * > MinutesPerHour > Public Const SecondsPerHour As Long = MinutesPerHour * > SecondsPerMinute > Public Const SecondsPerDay As Long = HoursPerDay * > SecondsPerHour > Public Const MillisecondsPerMinute As Long = SecondsPerMinute * > MillisecondsPerSecond > Public Const MillisecondsPerDay As Long = SecondsPerDay * > MillisecondsPerSecond > > > ' Returns the millisecond part from Date1. > ' > ' 2016-09-15. Gustav Brock, Cactus Data ApS, CPH. > ' > Public Function Millisecond( _ > ByVal Date1 As Date) _ > As Integer > > Dim Milliseconds As Integer > > ' Remove date part from date/time value and extract count of > milliseconds. > ' Note the use of CDec() to prevent bit errors for very large date > values. > Milliseconds = Abs(Date1 - CDec(Fix(Date1))) * MillisecondsPerDay Mod > MillisecondsPerSecond > > Millisecond = Milliseconds > > End Function > > > If that is the case, round the values before storing them using my > function posted before. > > /gustav > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From wrwehler at gmail.com Mon Nov 26 09:00:40 2018 From: wrwehler at gmail.com (Ryan W) Date: Mon, 26 Nov 2018 09:00:40 -0600 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Ok looking at this again the dates being stored in excel are start off as: 43424.6666666667 but then gravitate to: 43424.6666666088 I'm not sure I understand why though, they're all being input as 11/20/2018 16:00 and then copied down the row. On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < accessd at databaseadvisors.com> wrote: > For that small amount I'd be looking at the internal formats used on the > source > & destination systems as well as the way the value is held in the > transferring > media > Probably one of them is not holding enough decimal places (or allowing a > big > enough n in 2-n) in the storage of the value, so is rounding > And, as it is only milliseconds, maybe round to the nearest second would > deal > with the visibility of the glitch. > > The date and time being held, by Excel as in 43424.6666666667 > And rounding it up to the 7th place as in adding 0.00000003 to get > 43424.66666667 > May be the reason for the extra 3 milliseconds being indicated > While 43424.66666668 shows 4 milliseconds. > > And ... that is the perennial problem with the inexperienced use of > computers > Well, that and that the books and teachers rarely mention such things - so > the > first you know is when it bites you > and only the fortunate get to notice it in their work before it becomes a > public > humiliation > > That - and the other major pain - people who do NOT check that cash values > are > not only shown as being in bankable portions of the currency - but are > actually > the same value as is being shown > e.g. $1 split into thirds is 1/3 + 1/3 +1/3 and for the computer the total > of > 1/3 + 1/3 +1/3 does NOT = 1.00 > So - validation should be dealing with whole cents when the checking has > 0.99 > not = 1.00 > or the split of the value needs to have the last portion being the base > value > less the sum of the other portions, > or management have to specify some other process to deal with the many > little > bits. > And the coder should consider if(abs(a-b)<0.000limit) rather than if a=b > or if > a-b=0. > > JimB > > > > > -----Original Message----- > From: AccessD On Behalf Of Daniel > Waters > Sent: Wednesday, November 21, 2018 5:39 PM > To: Access Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on date insert? > > That is a puzzle - I have no answer. :-( > > Dan > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > Ryan W > Sent: November 21, 2018 11:33 > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Losing 3ms on date insert? > > No SQL Server is on a VM... but these are 'set' dates, not using GETDATE() > or DATE() or a function where a tiny time discrepancy like that might show > up. > > So the source table has 11/20/2018 16:00 as the date, but the destination > table, after the first two rows gets rolled back by 3ms for some reason. > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > wrote: > > > Is the Access file and the SQL Server on the same PC? Or on a PC where > > SQL Server is on a Server? > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of > > Ryan W > > Sent: November 21, 2018 10:47 > > To: Access Developers discussion and problem solving > > Subject: [AccessD] Losing 3ms on date insert? > > > > Has anyone seen an issue where: > > > > INSERT INTO FOO SELECT * FROM BAR > > > > Where FOO and BAR both contain a date column, but when inserted in from > MS > > Access to SQL the date loses 3ms? > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > https://i.imgur.com/IYsKCbS.png (Screencap) > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From gustav at cactus.dk Mon Nov 26 09:21:58 2018 From: gustav at cactus.dk (Gustav Brock) Date: Mon, 26 Nov 2018 15:21:58 +0000 Subject: [AccessD] Losing 3ms on date insert? Message-ID: Hi Ryan The original value is exactly 2018-11-20 16:00:00.000. The gravitation is exactly 5ms. It will, when stored in SQL Server using DateTime be rounded to: 43424.6666666319 which is - as you have noted - 3ms off. However, the 5ms cannot even be caused by some rounding, so there must be something in between, we don't know of. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Ryan W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? Ok looking at this again the dates being stored in excel are start off as: 43424.6666666667 but then gravitate to: 43424.6666666088 I'm not sure I understand why though, they're all being input as 11/20/2018 16:00 and then copied down the row. On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < accessd at databaseadvisors.com> wrote: > For that small amount I'd be looking at the internal formats used on > the source & destination systems as well as the way the value is held > in the transferring media Probably one of them is not holding enough > decimal places (or allowing a big enough n in 2-n) in the storage of > the value, so is rounding And, as it is only milliseconds, maybe round > to the nearest second would deal with the visibility of the glitch. > > The date and time being held, by Excel as in 43424.6666666667 And > rounding it up to the 7th place as in adding 0.00000003 to get 43424.66666667 > May be the reason for the extra 3 milliseconds being indicated While > 43424.66666668 shows 4 milliseconds. > > And ... that is the perennial problem with the inexperienced use of > computers Well, that and that the books and teachers rarely mention > such things - so the first you know is when it bites you and only the > fortunate get to notice it in their work before it becomes a public > humiliation > > That - and the other major pain - people who do NOT check that cash > values are not only shown as being in bankable portions of the > currency - but are actually the same value as is being shown e.g. $1 > split into thirds is 1/3 + 1/3 +1/3 and for the computer the total of > 1/3 + 1/3 +1/3 does NOT = 1.00 > So - validation should be dealing with whole cents when the checking has 0.99 not = 1.00 > or the split of the value needs to have the last portion being the > base value less the sum of the other portions, or management have to > specify some other process to deal with the many little bits. > And the coder should consider if(abs(a-b)<0.000limit) rather than if > a=b or if a-b=0. > > JimB > > > > > -----Original Message----- > From: AccessD On Behalf Of > Daniel Waters > Sent: Wednesday, November 21, 2018 5:39 PM > To: Access Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on date insert? > > That is a puzzle - I have no answer. :-( > > Dan > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf > Of Ryan W > Sent: November 21, 2018 11:33 > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Losing 3ms on date insert? > > No SQL Server is on a VM... but these are 'set' dates, not using > GETDATE() or DATE() or a function where a tiny time discrepancy like > that might show up. > > So the source table has 11/20/2018 16:00 as the date, but the > destination table, after the first two rows gets rolled back by 3ms for some reason. > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > wrote: > > > Is the Access file and the SQL Server on the same PC? Or on a PC > > where SQL Server is on a Server? > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > Behalf Of Ryan W > > Sent: November 21, 2018 10:47 > > To: Access Developers discussion and problem solving > > Subject: [AccessD] Losing 3ms on date insert? > > > > Has anyone seen an issue where: > > > > INSERT INTO FOO SELECT * FROM BAR > > > > Where FOO and BAR both contain a date column, but when inserted in from MS > > Access to SQL the date loses 3ms? > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > https://i.imgur.com/IYsKCbS.png (Screencap) From accessd at shaw.ca Mon Nov 26 16:15:56 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Mon, 26 Nov 2018 15:15:56 -0700 (MST) Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> I wonder, if the number could be stored as just a value without a decimal point. Many years ago when working with the AcPac accounting package, I found they never stored decimal numbers because of the round off errors. They would store a number as a whole number and then store a mantissa value. So a number would store like 12345698123 and a mantissa value of 9 and when the value was displayed it showed 12.345698123. Is that a possible solution? Also, in my much younger years I used Fortran and it would have number values of a hundred of more decimal places. I do not remember any round off errors. Here is a link to an online Fortran editor: https://www.jdoodle.com/execute-fortran-online There is a full open source version of Fortran (http://gcc.gnu.org/fortran/) and its compiler...download it, run it and use it. ;-) ...And then of course, and I am really dating myself, there is log tables and log functions. They were basically used to eliminate the need for decimal numbers, multiplying and dividing. No round off or number storage errors. Jim ----- Original Message ----- From: "Gustav Brock" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 7:21:58 AM Subject: Re: [AccessD] Losing 3ms on date insert? Hi Ryan The original value is exactly 2018-11-20 16:00:00.000. The gravitation is exactly 5ms. It will, when stored in SQL Server using DateTime be rounded to: 43424.6666666319 which is - as you have noted - 3ms off. However, the 5ms cannot even be caused by some rounding, so there must be something in between, we don't know of. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Ryan W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? Ok looking at this again the dates being stored in excel are start off as: 43424.6666666667 but then gravitate to: 43424.6666666088 I'm not sure I understand why though, they're all being input as 11/20/2018 16:00 and then copied down the row. On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < accessd at databaseadvisors.com> wrote: > For that small amount I'd be looking at the internal formats used on > the source & destination systems as well as the way the value is held > in the transferring media Probably one of them is not holding enough > decimal places (or allowing a big enough n in 2-n) in the storage of > the value, so is rounding And, as it is only milliseconds, maybe round > to the nearest second would deal with the visibility of the glitch. > > The date and time being held, by Excel as in 43424.6666666667 And > rounding it up to the 7th place as in adding 0.00000003 to get 43424.66666667 > May be the reason for the extra 3 milliseconds being indicated While > 43424.66666668 shows 4 milliseconds. > > And ... that is the perennial problem with the inexperienced use of > computers Well, that and that the books and teachers rarely mention > such things - so the first you know is when it bites you and only the > fortunate get to notice it in their work before it becomes a public > humiliation > > That - and the other major pain - people who do NOT check that cash > values are not only shown as being in bankable portions of the > currency - but are actually the same value as is being shown e.g. $1 > split into thirds is 1/3 + 1/3 +1/3 and for the computer the total of > 1/3 + 1/3 +1/3 does NOT = 1.00 > So - validation should be dealing with whole cents when the checking has 0.99 not = 1.00 > or the split of the value needs to have the last portion being the > base value less the sum of the other portions, or management have to > specify some other process to deal with the many little bits. > And the coder should consider if(abs(a-b)<0.000limit) rather than if > a=b or if a-b=0. > > JimB > > > > > -----Original Message----- > From: AccessD On Behalf Of > Daniel Waters > Sent: Wednesday, November 21, 2018 5:39 PM > To: Access Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on date insert? > > That is a puzzle - I have no answer. :-( > > Dan > > -----Original Message----- > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On Behalf > Of Ryan W > Sent: November 21, 2018 11:33 > To: Access Developers discussion and problem solving > Subject: Re: [AccessD] Losing 3ms on date insert? > > No SQL Server is on a VM... but these are 'set' dates, not using > GETDATE() or DATE() or a function where a tiny time discrepancy like > that might show up. > > So the source table has 11/20/2018 16:00 as the date, but the > destination table, after the first two rows gets rolled back by 3ms for some reason. > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > wrote: > > > Is the Access file and the SQL Server on the same PC? Or on a PC > > where SQL Server is on a Server? > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > Behalf Of Ryan W > > Sent: November 21, 2018 10:47 > > To: Access Developers discussion and problem solving > > Subject: [AccessD] Losing 3ms on date insert? > > > > Has anyone seen an issue where: > > > > INSERT INTO FOO SELECT * FROM BAR > > > > Where FOO and BAR both contain a date column, but when inserted in from MS > > Access to SQL the date loses 3ms? > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > https://i.imgur.com/IYsKCbS.png (Screencap) -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Mon Nov 26 17:03:53 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Tue, 27 Nov 2018 09:03:53 +1000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> References: , <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> Message-ID: <5BFC7BD9.31998.137424B5@stuart.lexacorp.com.pg> ROTF! How many digits of precision in a log table? On 26 Nov 2018 at 15:15, Jim Lawrence wrote: > ...And then of course, and I am really dating myself, there is log > tables and log functions. They were basically used to eliminate the > need for decimal numbers, multiplying and dividing. No round off or > number storage errors. > > Jim > > ----- Original Message ----- > From: "Gustav Brock" > To: "Access Developers discussion and problem solving" > Sent: Monday, November 26, 2018 7:21:58 > AM Subject: Re: [AccessD] Losing 3ms on date insert? > > Hi Ryan > > The original value is exactly 2018-11-20 16:00:00.000. > The gravitation is exactly 5ms. > > It will, when stored in SQL Server using DateTime be rounded to: > > 43424.6666666319 > > which is - as you have noted - 3ms off. > > However, the 5ms cannot even be caused by some rounding, so there must > be something in between, we don't know of. > > /gustav > > -----Oprindelig meddelelse----- > Fra: AccessD P? vegne af Ryan > W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and > problem solving Emne: Re: [AccessD] > Losing 3ms on date insert? > > Ok looking at this again the dates being stored in excel are start off > as: 43424.6666666667 > > > but then gravitate to: > > 43424.6666666088 > > I'm not sure I understand why though, they're all being input as > 11/20/2018 16:00 and then copied down the row. > > > > > > On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < > accessd at databaseadvisors.com> wrote: > > > For that small amount I'd be looking at the internal formats used on > > the source & destination systems as well as the way the value is > > held in the transferring media Probably one of them is not holding > > enough decimal places (or allowing a big enough n in 2-n) in the > > storage of the value, so is rounding And, as it is only > > milliseconds, maybe round to the nearest second would deal with the > > visibility of the glitch. > > > > The date and time being held, by Excel as in 43424.6666666667 And > > rounding it up to the 7th place as in adding 0.00000003 to get > > 43424.66666667 May be the reason for the extra 3 milliseconds being > > indicated While 43424.66666668 shows 4 milliseconds. > > > > And ... that is the perennial problem with the inexperienced use of > > computers Well, that and that the books and teachers rarely mention > > such things - so the first you know is when it bites you and only > > the fortunate get to notice it in their work before it becomes a > > public humiliation > > > > That - and the other major pain - people who do NOT check that cash > > values are not only shown as being in bankable portions of the > > currency - but are actually the same value as is being shown e.g. $1 > > split into thirds is 1/3 + 1/3 +1/3 and for the computer the total > > of 1/3 + 1/3 +1/3 does NOT = 1.00 So - validation should be dealing > > with whole cents when the checking has 0.99 not = 1.00 or the split > > of the value needs to have the last portion being the base value > > less the sum of the other portions, or management have to specify > > some other process to deal with the many little bits. And the coder > > should consider if(abs(a-b)<0.000limit) rather than if a=b or if > > a-b=0. > > > > JimB > > > > > > > > > > -----Original Message----- > > From: AccessD On Behalf Of > > Daniel Waters Sent: Wednesday, November 21, 2018 5:39 PM To: Access > > Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on > > date insert? > > > > That is a puzzle - I have no answer. :-( > > > > Dan > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > Behalf Of Ryan W Sent: November 21, 2018 11:33 To: Access Developers > > discussion and problem solving Subject: Re: [AccessD] Losing 3ms on > > date insert? > > > > No SQL Server is on a VM... but these are 'set' dates, not using > > GETDATE() or DATE() or a function where a tiny time discrepancy like > > that might show up. > > > > So the source table has 11/20/2018 16:00 as the date, but the > > destination table, after the first two rows gets rolled back by 3ms > > for some reason. > > > > > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > > wrote: > > > > > Is the Access file and the SQL Server on the same PC? Or on a PC > > > where SQL Server is on a Server? > > > > > > -----Original Message----- > > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > > Behalf Of Ryan W Sent: November 21, 2018 10:47 To: Access > > > Developers discussion and problem solving Subject: [AccessD] > > > Losing 3ms on date insert? > > > > > > Has anyone seen an issue where: > > > > > > INSERT INTO FOO SELECT * FROM BAR > > > > > > Where FOO and BAR both contain a date column, but when inserted in > > > from MS Access to SQL the date loses 3ms? > > > > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > > > https://i.imgur.com/IYsKCbS.png (Screencap) > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com From accessd at shaw.ca Mon Nov 26 17:50:04 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Mon, 26 Nov 2018 16:50:04 -0700 (MST) Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <5BFC7BD9.31998.137424B5@stuart.lexacorp.com.pg> References: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> <5BFC7BD9.31998.137424B5@stuart.lexacorp.com.pg> Message-ID: <1509258180.351421054.1543276204085.JavaMail.zimbra@shaw.ca> I am not sure off the top. I do remember referring to books where values extended across the width of a page...80 characters I think. Jim ----- Original Message ----- From: "stuart" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 3:03:53 PM Subject: Re: [AccessD] Losing 3ms on date insert? ROTF! How many digits of precision in a log table? On 26 Nov 2018 at 15:15, Jim Lawrence wrote: > ...And then of course, and I am really dating myself, there is log > tables and log functions. They were basically used to eliminate the > need for decimal numbers, multiplying and dividing. No round off or > number storage errors. > > Jim > > ----- Original Message ----- > From: "Gustav Brock" > To: "Access Developers discussion and problem solving" > Sent: Monday, November 26, 2018 7:21:58 > AM Subject: Re: [AccessD] Losing 3ms on date insert? > > Hi Ryan > > The original value is exactly 2018-11-20 16:00:00.000. > The gravitation is exactly 5ms. > > It will, when stored in SQL Server using DateTime be rounded to: > > 43424.6666666319 > > which is - as you have noted - 3ms off. > > However, the 5ms cannot even be caused by some rounding, so there must > be something in between, we don't know of. > > /gustav > > -----Oprindelig meddelelse----- > Fra: AccessD P? vegne af Ryan > W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and > problem solving Emne: Re: [AccessD] > Losing 3ms on date insert? > > Ok looking at this again the dates being stored in excel are start off > as: 43424.6666666667 > > > but then gravitate to: > > 43424.6666666088 > > I'm not sure I understand why though, they're all being input as > 11/20/2018 16:00 and then copied down the row. > > > > > > On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < > accessd at databaseadvisors.com> wrote: > > > For that small amount I'd be looking at the internal formats used on > > the source & destination systems as well as the way the value is > > held in the transferring media Probably one of them is not holding > > enough decimal places (or allowing a big enough n in 2-n) in the > > storage of the value, so is rounding And, as it is only > > milliseconds, maybe round to the nearest second would deal with the > > visibility of the glitch. > > > > The date and time being held, by Excel as in 43424.6666666667 And > > rounding it up to the 7th place as in adding 0.00000003 to get > > 43424.66666667 May be the reason for the extra 3 milliseconds being > > indicated While 43424.66666668 shows 4 milliseconds. > > > > And ... that is the perennial problem with the inexperienced use of > > computers Well, that and that the books and teachers rarely mention > > such things - so the first you know is when it bites you and only > > the fortunate get to notice it in their work before it becomes a > > public humiliation > > > > That - and the other major pain - people who do NOT check that cash > > values are not only shown as being in bankable portions of the > > currency - but are actually the same value as is being shown e.g. $1 > > split into thirds is 1/3 + 1/3 +1/3 and for the computer the total > > of 1/3 + 1/3 +1/3 does NOT = 1.00 So - validation should be dealing > > with whole cents when the checking has 0.99 not = 1.00 or the split > > of the value needs to have the last portion being the base value > > less the sum of the other portions, or management have to specify > > some other process to deal with the many little bits. And the coder > > should consider if(abs(a-b)<0.000limit) rather than if a=b or if > > a-b=0. > > > > JimB > > > > > > > > > > -----Original Message----- > > From: AccessD On Behalf Of > > Daniel Waters Sent: Wednesday, November 21, 2018 5:39 PM To: Access > > Developers discussion and problem solving > > Subject: Re: [AccessD] Losing 3ms on > > date insert? > > > > That is a puzzle - I have no answer. :-( > > > > Dan > > > > -----Original Message----- > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > Behalf Of Ryan W Sent: November 21, 2018 11:33 To: Access Developers > > discussion and problem solving Subject: Re: [AccessD] Losing 3ms on > > date insert? > > > > No SQL Server is on a VM... but these are 'set' dates, not using > > GETDATE() or DATE() or a function where a tiny time discrepancy like > > that might show up. > > > > So the source table has 11/20/2018 16:00 as the date, but the > > destination table, after the first two rows gets rolled back by 3ms > > for some reason. > > > > > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > > wrote: > > > > > Is the Access file and the SQL Server on the same PC? Or on a PC > > > where SQL Server is on a Server? > > > > > > -----Original Message----- > > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > > Behalf Of Ryan W Sent: November 21, 2018 10:47 To: Access > > > Developers discussion and problem solving Subject: [AccessD] > > > Losing 3ms on date insert? > > > > > > Has anyone seen an issue where: > > > > > > INSERT INTO FOO SELECT * FROM BAR > > > > > > Where FOO and BAR both contain a date column, but when inserted in > > > from MS Access to SQL the date loses 3ms? > > > > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > > > https://i.imgur.com/IYsKCbS.png (Screencap) > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From jamesbutton at blueyonder.co.uk Mon Nov 26 18:35:06 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Tue, 27 Nov 2018 00:35:06 -0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> References: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> Message-ID: Firstly - Gravitate how? - well turn your screen on it's side to avoid that effect of gravitation (snigger) However some of the following may be also associated with the problem - AFAIK VBA times are stored with less accuracy than Excel So it could be that the value is being truncated within the transmission from app to app IN VBA a date is an 8 bit floating point value as in integer day and fractional hh:mm:ss Note NO MILLISECONDS but with VBA you get dates before December 30, 1899 using negative integers Standards (Ha! - ha ha ha ) for PC hardware is usually that numbers are stored to 15 significant digits with about 300 "0"'s between the decimal point and that (up to 16) digit string. In VBA there is CURRENCY datatype that stores a value of up to 15 digits before the decimal point and up to 4 after it . Decimal is even more fun - as in different from Excel as Decimal allows up to 28 decimal places with the decimal place anywhere within those 28 BUT you have to use the CDEC function to convert the value into a 12byte storage block that is actually held under the Variant DIIM structure! Also remember Boolean conversion from/to numeric equivalent is different in VBA and Excel. In VBA there are Integer from -32,768 up to +32,767 Long which is -2,147,483,648 up to +2,147,483,647 Double -1.79769313486231E308 up to +1.79769313486232E308 And - for those with 64 bit OS and applications There is the LongLong VBA data type for 18, well, almost 19 digit numbers from -9,223,372,036,854,775,808 and 9,223,372,036,854,775,807. Also re accuracy of hundreds of digits Way back before PC's, there were machines that did not have storage arranged in 'words' of 4 8 or 16 bytes with each byte being used to hold an 8 bit character, But the systems memory was in individual 7 bit characters with extra bits associated with each character (1 or 2 of them) used to define the end of a 'word' or an 'item' or a 'record' So addition and subtraction was done on a 'character' mode working along the digits until a word ending bit was found, so a number could be almost all of memory (H200 systems) There were also systems with 36 and systems with 48 bit words - just to really annoy those doing conversions to newer (and different manufacturer's) hardware. Even more fun when a manufacturer moved their hardware from 7 bit data storage to 9 bit (e.g. mag-tapes) so the replacement hardware would not run the drives that read the old data storage media Hey - seen a 5? floppy disk recently, let alone an 8" or 11" one ? OK - how about a 3" one? And - NOT MANY PPEOPLE KNOW THIS Within VBA - Date formats c means date (if value >=1) and then hh:mm:ss if a fractional part oooo means monthname in the local format aaaa means weekday in local format w means weekday (Sunday is day 1) ww is week of the year m is month, or if in {} or following h then minutes n is minutes - so you don't need to use m q means quarter of the year y means day of the year and text one or more @ characters means the text string at this place in the string and only as many characters as there are @'s one or more & characters means the character at this place in the string and only as many characters as there are &'s The output will be the exact number of & or @ in the string with the source characters dropped where format string includes spaces in a string of @ or & spaces in an @ string meaning a space in the output and a space in an & string means closeup the result. Prefix markers in the format string can be > means output uppercase References: , <5BFC7BD9.31998.137424B5@stuart.lexacorp.com.pg>, <1509258180.351421054.1543276204085.JavaMail.zimbra@shaw.ca> Message-ID: <5BFC9367.15304.13D026D9@stuart.lexacorp.com.pg> I fear you mis-remember. All log tables "extend across the width of the page", but that's because you need ten columns for a single digit in the original value Common log tables had 4 significant digits and were about as accurate, but much slower to use than a good slide rule. Where greater precision was needed, we also had 7 figure log tables. The problem with them was that the tables occupied hundreds of pages rather than the couple of pages for 4 digit common log tables. I haven't bother to work out the numbers involved, but I'm pretty certain that an 80 digit log table would occupy considerably more space than the Encyclopedia Britannica :) On 26 Nov 2018 at 16:50, Jim Lawrence wrote: > I am not sure off the top. I do remember referring to books where > values extended across the width of a page...80 characters I think. > > Jim > > ----- Original Message ----- > From: "stuart" > To: "Access Developers discussion and problem solving" > Sent: Monday, November 26, 2018 3:03:53 > PM Subject: Re: [AccessD] Losing 3ms on date insert? > > ROTF! > > How many digits of precision in a log table? > > > > On 26 Nov 2018 at 15:15, Jim Lawrence wrote: > > > ...And then of course, and I am really dating myself, there is log > > tables and log functions. They were basically used to eliminate the > > need for decimal numbers, multiplying and dividing. No round off or > > number storage errors. > > > > Jim > > > > ----- Original Message ----- > > From: "Gustav Brock" > > To: "Access Developers discussion and problem solving" > > Sent: Monday, November 26, 2018 > > 7:21:58 AM Subject: Re: [AccessD] Losing 3ms on date insert? > > > > Hi Ryan > > > > The original value is exactly 2018-11-20 16:00:00.000. > > The gravitation is exactly 5ms. > > > > It will, when stored in SQL Server using DateTime be rounded to: > > > > 43424.6666666319 > > > > which is - as you have noted - 3ms off. > > > > However, the 5ms cannot even be caused by some rounding, so there > > must be something in between, we don't know of. > > > > /gustav > > > > -----Oprindelig meddelelse----- > > Fra: AccessD P? vegne af > > Ryan W Sendt: 26. november 2018 16:01 Til: Access Developers > > discussion and problem solving Emne: > > Re: [AccessD] Losing 3ms on date insert? > > > > Ok looking at this again the dates being stored in excel are start > > off as: 43424.6666666667 > > > > > > but then gravitate to: > > > > 43424.6666666088 > > > > I'm not sure I understand why though, they're all being input as > > 11/20/2018 16:00 and then copied down the row. > > > > > > > > > > > > On Wed, Nov 21, 2018 at 12:27 PM James Button via AccessD < > > accessd at databaseadvisors.com> wrote: > > > > > For that small amount I'd be looking at the internal formats used > > > on the source & destination systems as well as the way the value > > > is held in the transferring media Probably one of them is not > > > holding enough decimal places (or allowing a big enough n in 2-n) > > > in the storage of the value, so is rounding And, as it is only > > > milliseconds, maybe round to the nearest second would deal with > > > the visibility of the glitch. > > > > > > The date and time being held, by Excel as in 43424.6666666667 And > > > rounding it up to the 7th place as in adding 0.00000003 to get > > > 43424.66666667 May be the reason for the extra 3 milliseconds > > > being indicated While 43424.66666668 shows 4 milliseconds. > > > > > > And ... that is the perennial problem with the inexperienced use > > > of computers Well, that and that the books and teachers rarely > > > mention such things - so the first you know is when it bites you > > > and only the fortunate get to notice it in their work before it > > > becomes a public humiliation > > > > > > That - and the other major pain - people who do NOT check that > > > cash values are not only shown as being in bankable portions of > > > the currency - but are actually the same value as is being shown > > > e.g. $1 split into thirds is 1/3 + 1/3 +1/3 and for the computer > > > the total of 1/3 + 1/3 +1/3 does NOT = 1.00 So - validation should > > > be dealing with whole cents when the checking has 0.99 not = 1.00 > > > or the split of the value needs to have the last portion being the > > > base value less the sum of the other portions, or management have > > > to specify some other process to deal with the many little bits. > > > And the coder should consider if(abs(a-b)<0.000limit) rather than > > > if a=b or if a-b=0. > > > > > > JimB > > > > > > > > > > > > > > > -----Original Message----- > > > From: AccessD On Behalf Of > > > Daniel Waters Sent: Wednesday, November 21, 2018 5:39 PM To: > > > Access Developers discussion and problem solving > > > Subject: Re: [AccessD] Losing 3ms > > > on date insert? > > > > > > That is a puzzle - I have no answer. :-( > > > > > > Dan > > > > > > -----Original Message----- > > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > > Behalf Of Ryan W Sent: November 21, 2018 11:33 To: Access > > > Developers discussion and problem solving Subject: Re: [AccessD] > > > Losing 3ms on date insert? > > > > > > No SQL Server is on a VM... but these are 'set' dates, not using > > > GETDATE() or DATE() or a function where a tiny time discrepancy > > > like that might show up. > > > > > > So the source table has 11/20/2018 16:00 as the date, but the > > > destination table, after the first two rows gets rolled back by > > > 3ms for some reason. > > > > > > > > > > > > On Wed, Nov 21, 2018 at 10:54 AM Daniel Waters > > > wrote: > > > > > > > Is the Access file and the SQL Server on the same PC? Or on a > > > > PC where SQL Server is on a Server? > > > > > > > > -----Original Message----- > > > > From: AccessD [mailto:accessd-bounces at databaseadvisors.com] On > > > > Behalf Of Ryan W Sent: November 21, 2018 10:47 To: Access > > > > Developers discussion and problem solving Subject: [AccessD] > > > > Losing 3ms on date insert? > > > > > > > > Has anyone seen an issue where: > > > > > > > > INSERT INTO FOO SELECT * FROM BAR > > > > > > > > Where FOO and BAR both contain a date column, but when inserted > > > > in from MS Access to SQL the date loses 3ms? > > > > > > > > > > > > The first two rows, proper date.. following rows -3ms ? > > > > > > > > https://i.imgur.com/IYsKCbS.png (Screencap) > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Mon Nov 26 19:35:04 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Tue, 27 Nov 2018 11:35:04 +1000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: Message-ID: <5BFC9F48.15633.13FE8DF5@stuart.lexacorp.com.pg> There ARE milliseconds available in a stored Date/Time. It's just that MS make it very difficult to display or work with them. "hh:mm:ss" is just a display format and doesn't tell us anything about the actual data storage. As you say, the storage is a Double which gives you 15-17 decimal digits of precision. Assuming that you use a maximum of 6 of those for the date part (which will handle up to around the year 2740!), that still leaves at least 9 significant digits. Since a second only required 5 significant digits (1/86400) that leaves a further 4 significant digits for partial seconds (i.e 1/1000 second precision). http://www.devx.com/dbzone/Article/39046 "In fact, Access and Jet both can store milliseconds because Double, the underlying data type of date/time, has a resolution one thousand times larger than date/time's smallest increment of one second. However, manipulating time values with millisecond precision in Access requires some crafty programming. You need the help of a couple of API calls, which you wrap in functions that mimic the standard timing functions in Access. This article explains how to apply this technique, which will enable you to create, retrieve, and measure time values down to the millisecond. " On 27 Nov 2018 at 0:35, James Button via AccessD wrote: > > IN VBA a date is an 8 bit floating point value as in integer day and > fractional hh:mm:ss > > Note NO MILLISECONDS > From accessd at shaw.ca Mon Nov 26 23:32:05 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Mon, 26 Nov 2018 22:32:05 -0700 (MST) Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: <1534649961.350807447.1543270556223.JavaMail.zimbra@shaw.ca> Message-ID: <805187537.353352430.1543296725979.JavaMail.zimbra@shaw.ca> I remember having to calculate how many variables and their size so a common block could be established with Fortran. One miscalculation on an offset or variable size would cause an over-flow and crash the whole program. But real men and women still use C, high-wire with no net. ;-) Can an external service be attached to an excel spreadsheet in which parameters can be pasted back and forth? Like: https://support.office.com/en-us/article/insert-an-object-in-your-excel-spreadsheet-e73867b2-2988-4116-8d85-f5769ea435ba http://bit.ly/2P5iUDh Jim ----- Original Message ----- From: "Access Developers discussion and problem solving" To: "Access Developers discussion and problem solving" Cc: "James Button" Sent: Monday, November 26, 2018 4:35:06 PM Subject: Re: [AccessD] Losing 3ms on date insert? Firstly - Gravitate how? - well turn your screen on it's side to avoid that effect of gravitation (snigger) However some of the following may be also associated with the problem - AFAIK VBA times are stored with less accuracy than Excel So it could be that the value is being truncated within the transmission from app to app IN VBA a date is an 8 bit floating point value as in integer day and fractional hh:mm:ss Note NO MILLISECONDS but with VBA you get dates before December 30, 1899 using negative integers Standards (Ha! - ha ha ha ) for PC hardware is usually that numbers are stored to 15 significant digits with about 300 "0"'s between the decimal point and that (up to 16) digit string. In VBA there is CURRENCY datatype that stores a value of up to 15 digits before the decimal point and up to 4 after it . Decimal is even more fun - as in different from Excel as Decimal allows up to 28 decimal places with the decimal place anywhere within those 28 BUT you have to use the CDEC function to convert the value into a 12byte storage block that is actually held under the Variant DIIM structure! Also remember Boolean conversion from/to numeric equivalent is different in VBA and Excel. In VBA there are Integer from -32,768 up to +32,767 Long which is -2,147,483,648 up to +2,147,483,647 Double -1.79769313486231E308 up to +1.79769313486232E308 And - for those with 64 bit OS and applications There is the LongLong VBA data type for 18, well, almost 19 digit numbers from -9,223,372,036,854,775,808 and 9,223,372,036,854,775,807. Also re accuracy of hundreds of digits Way back before PC's, there were machines that did not have storage arranged in 'words' of 4 8 or 16 bytes with each byte being used to hold an 8 bit character, But the systems memory was in individual 7 bit characters with extra bits associated with each character (1 or 2 of them) used to define the end of a 'word' or an 'item' or a 'record' So addition and subtraction was done on a 'character' mode working along the digits until a word ending bit was found, so a number could be almost all of memory (H200 systems) There were also systems with 36 and systems with 48 bit words - just to really annoy those doing conversions to newer (and different manufacturer's) hardware. Even more fun when a manufacturer moved their hardware from 7 bit data storage to 9 bit (e.g. mag-tapes) so the replacement hardware would not run the drives that read the old data storage media Hey - seen a 5? floppy disk recently, let alone an 8" or 11" one ? OK - how about a 3" one? And - NOT MANY PPEOPLE KNOW THIS Within VBA - Date formats c means date (if value >=1) and then hh:mm:ss if a fractional part oooo means monthname in the local format aaaa means weekday in local format w means weekday (Sunday is day 1) ww is week of the year m is month, or if in {} or following h then minutes n is minutes - so you don't need to use m q means quarter of the year y means day of the year and text one or more @ characters means the text string at this place in the string and only as many characters as there are @'s one or more & characters means the character at this place in the string and only as many characters as there are &'s The output will be the exact number of & or @ in the string with the source characters dropped where format string includes spaces in a string of @ or & spaces in an @ string meaning a space in the output and a space in an & string means closeup the result. Prefix markers in the format string can be > means output uppercase Message-ID: <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg> In answer to your question: Yes. But I don't see how your link relates to that. OLE is a different beasst to passing data to and from a spreadsheet. Here's an example of controlling a spreadsheet from another application (which could easily be a service). #COMPILER PBWIN 10 #COMPILE EXE #DIM ALL #INCLUDE ONCE "Excel.inc" '------------------------------------------------------------------------------ ' Main application entry point... ' FUNCTION PBMAIN DIM oExcelApp AS Excel_Application DIM oExcelWorkbook AS Excel_Workbook DIM oExcelWorkSheet AS Excel_WorkSheet DIM vBool AS VARIANT DIM vText1 AS VARIANT DIM vText2 AS VARIANT DIM vFile AS VARIANT DIM vFileFmt AS VARIANT DIM oVnt AS VARIANT DIM nVnt AS VARIANT DIM vX AS VARIANT DIM vY AS VARIANT DIM x AS LONG DIM y AS LONG DIM ws AS WSTRING ' Open an instance of EXCEL oExcelApp = ANYCOM $PROGID_Excel_Application ' Could EXCEL be opened? If not, terminate this app IF ISFALSE ISOBJECT(oExcelApp) OR ERR THEN MSGBOX "Excel could not be opened. Please check that Excel and VBA are installed." EXIT FUNCTION END IF ' Make MSEXCEL visible vBool = 1 OBJECT LET oExcelApp.Visible = vBool ' Create a new workbook in EXCEL OBJECT CALL oExcelApp.WorkBooks.Add TO oExcelWorkBook IF ISFALSE ISOBJECT(oExcelWorkbook) OR ERR THEN MSGBOX "Excel could not open a new workbook. Please check that VBA is installed." GOTO Terminate END IF ' Create a new worksheet in the workbook and use this ' worksheet reference to pump data into EXCEL OBJECT CALL oExcelWorkBook.WorkSheets.Add TO oExcelWorkSheet IF ISFALSE ISOBJECT(oExcelWorkSheet) OR ERR THEN MSGBOX "Excel could not open a new worksheet. Please check that VBA is installed." GOTO Terminate END IF FOR y = 1 TO 50 FOR x = 1 TO 5 vX = x vY = y ws = "Cell " & CHR$$(x + 64) & FORMAT$(y) vText1 = ws OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText1 NEXT x vX = 6 nVnt = y + y / 10 OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = nVnt vX = 7 ws = FORMAT$(RND(-1000,1000), "$#,.00") vText2 = ws OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText2 NEXT y OBJECT CALL oExcelWorksheet.PrintPreview ' Save the new XLS document to disk vFile = "Test.xls"$$ OBJECT CALL oExcelWorkBook.SaveAs(vFile) '---------------------------------------------------------------- Terminate: MSGBOX "Press the OK button to close Excel and exit the application" ' Close the current document and then close EXCEL completely OBJECT CALL oExcelApp.ActiveWindow.Close OBJECT CALL oExcelApp.Quit ' Release the interfaces. We could omit this since the ' app is about to close, but "best practice" states we ' should clean our house before moving out. SET oExcelApp = NOTHING SET oExcelWorkbook = NOTHING SET oExcelWorkSheet = NOTHING END FUNCTION On 26 Nov 2018 at 22:32, Jim Lawrence wrote: > Can an external service be attached to an excel spreadsheet in which > parameters can be pasted back and forth? > > Like: > > https://support.office.com/en-us/article/insert-an-object-in-your-exce > l-spreadsheet-e73867b2-2988-4116-8d85-f5769ea435ba > http://bit.ly/2P5iUDh > > Jim > From bensonforums at gmail.com Tue Nov 27 04:09:59 2018 From: bensonforums at gmail.com (Bill Benson) Date: Tue, 27 Nov 2018 05:09:59 -0500 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg> References: <805187537.353352430.1543296725979.JavaMail.zimbra@shaw.ca> <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg> Message-ID: Stuart, where do you use that code? On Tue, Nov 27, 2018 at 12:48 AM Stuart McLachlan wrote: > In answer to your question: Yes. > > But I don't see how your link relates to that. OLE is a different beasst > to passing data to and > from a spreadsheet. > > Here's an example of controlling a spreadsheet from another application > (which could easily > be a service). > > > #COMPILER PBWIN 10 > #COMPILE EXE > #DIM ALL > #INCLUDE ONCE "Excel.inc" > > > '------------------------------------------------------------------------------ > ' Main application entry point... > ' > FUNCTION PBMAIN > DIM oExcelApp AS Excel_Application > DIM oExcelWorkbook AS Excel_Workbook > DIM oExcelWorkSheet AS Excel_WorkSheet > > DIM vBool AS VARIANT > DIM vText1 AS VARIANT > DIM vText2 AS VARIANT > DIM vFile AS VARIANT > DIM vFileFmt AS VARIANT > DIM oVnt AS VARIANT > DIM nVnt AS VARIANT > DIM vX AS VARIANT > DIM vY AS VARIANT > DIM x AS LONG > DIM y AS LONG > DIM ws AS WSTRING > > ' Open an instance of EXCEL > oExcelApp = ANYCOM $PROGID_Excel_Application > > ' Could EXCEL be opened? If not, terminate this app > IF ISFALSE ISOBJECT(oExcelApp) OR ERR THEN > MSGBOX "Excel could not be opened. Please check that Excel and VBA are > installed." > EXIT FUNCTION > END IF > > ' Make MSEXCEL visible > vBool = 1 > OBJECT LET oExcelApp.Visible = vBool > > ' Create a new workbook in EXCEL > OBJECT CALL oExcelApp.WorkBooks.Add TO oExcelWorkBook > IF ISFALSE ISOBJECT(oExcelWorkbook) OR ERR THEN > MSGBOX "Excel could not open a new workbook. Please check that VBA is > installed." > GOTO Terminate > END IF > > ' Create a new worksheet in the workbook and use this > ' worksheet reference to pump data into EXCEL > OBJECT CALL oExcelWorkBook.WorkSheets.Add TO oExcelWorkSheet > IF ISFALSE ISOBJECT(oExcelWorkSheet) OR ERR THEN > MSGBOX "Excel could not open a new worksheet. Please check that VBA is > installed." > GOTO Terminate > END IF > > FOR y = 1 TO 50 > FOR x = 1 TO 5 > vX = x > vY = y > ws = "Cell " & CHR$$(x + 64) & FORMAT$(y) > vText1 = ws > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText1 > NEXT x > > vX = 6 > nVnt = y + y / 10 > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = nVnt > > vX = 7 > ws = FORMAT$(RND(-1000,1000), "$#,.00") > vText2 = ws > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText2 > NEXT y > > OBJECT CALL oExcelWorksheet.PrintPreview > > ' Save the new XLS document to disk > vFile = "Test.xls"$$ > OBJECT CALL oExcelWorkBook.SaveAs(vFile) > '---------------------------------------------------------------- > > Terminate: > MSGBOX "Press the OK button to close Excel and exit the application" > > ' Close the current document and then close EXCEL completely > OBJECT CALL oExcelApp.ActiveWindow.Close > OBJECT CALL oExcelApp.Quit > > ' Release the interfaces. We could omit this since the > ' app is about to close, but "best practice" states we > ' should clean our house before moving out. > SET oExcelApp = NOTHING > SET oExcelWorkbook = NOTHING > SET oExcelWorkSheet = NOTHING > > END FUNCTION > > > On 26 Nov 2018 at 22:32, Jim Lawrence wrote: > > > Can an external service be attached to an excel spreadsheet in which > > parameters can be pasted back and forth? > > > > Like: > > > > https://support.office.com/en-us/article/insert-an-object-in-your-exce > > l-spreadsheet-e73867b2-2988-4116-8d85-f5769ea435ba > > http://bit.ly/2P5iUDh > > > > Jim > > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From gustav at cactus.dk Tue Nov 27 04:17:42 2018 From: gustav at cactus.dk (Gustav Brock) Date: Tue, 27 Nov 2018 10:17:42 +0000 Subject: [AccessD] Losing 3ms on date insert? Message-ID: Hi James I think you are mixing some things up. VBA uses the same data types throughout the Office applications, thus dates and their numeric values are identical. Milliseconds can be held within the entire range of the data type. But (refer to the link provided by Stuart) when displayed natively in Access, milliseconds are rounded to the nearest second. As the resolution around numeric zero (1899-12-30 00:00:00) is much higher than at the extreme values, also microseconds and nanoseconds - even ticks - can be held, though within still tighter limits, of course: ' Interval with minimum one microsecond resolution. Public Const MaxMicrosecondDateValue As Date = #5/18/1927# Public Const MinMicrosecondDateValue As Date = #8/13/1872# ' Interval with minimum one nanosecond resolution. Public Const MaxNanosecondDateValue As Date = #1/9/1900# Public Const MinNanosecondDateValue As Date = #12/20/1899# ' Interval with minimum one tick resolution. Public Const MaxTickDateValue As Date = #2:24:00 AM# Public Const MinTickDateValue As Date = -#2:24:00 AM# That said, you can't apply calculations on subsecond values reliably using the date values only, Double as they are behind the scene, because of the resulting floating point errors. Thus, you must convert to Decimal (as demonstrated in my previously posted Millisecond function) to avoid these errors. As to your listed format strings, these don't work: oooo means monthname in the local format aaaa means weekday in local format The first, I have already got pulled from the docs, but I missed the second. That's done now: https://github.com/MicrosoftDocs/VBA-Docs/pull/496 Note, that anyone with a GitHub account can contribute to the docs, now they are hosted at GitHub. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af James Button via AccessD Sendt: 27. november 2018 01:35 Til: 'Access Developers discussion and problem solving' Cc: James Button Emne: Re: [AccessD] Losing 3ms on date insert? Firstly - Gravitate how? - well turn your screen on it's side to avoid that effect of gravitation (snigger) However some of the following may be also associated with the problem - AFAIK VBA times are stored with less accuracy than Excel So it could be that the value is being truncated within the transmission from app to app IN VBA a date is an 8 bit floating point value as in integer day and fractional hh:mm:ss Note NO MILLISECONDS but with VBA you get dates before December 30, 1899 using negative integers Standards (Ha! - ha ha ha ) for PC hardware is usually that numbers are stored to 15 significant digits with about 300 "0"'s between the decimal point and that (up to 16) digit string. In VBA there is CURRENCY datatype that stores a value of up to 15 digits before the decimal point and up to 4 after it . Decimal is even more fun - as in different from Excel as Decimal allows up to 28 decimal places with the decimal place anywhere within those 28 BUT you have to use the CDEC function to convert the value into a 12byte storage block that is actually held under the Variant DIIM structure! Also remember Boolean conversion from/to numeric equivalent is different in VBA and Excel. In VBA there are Integer from -32,768 up to +32,767 Long which is -2,147,483,648 up to +2,147,483,647 Double -1.79769313486231E308 up to +1.79769313486232E308 And - for those with 64 bit OS and applications There is the LongLong VBA data type for 18, well, almost 19 digit numbers from -9,223,372,036,854,775,808 and 9,223,372,036,854,775,807. Also re accuracy of hundreds of digits Way back before PC's, there were machines that did not have storage arranged in 'words' of 4 8 or 16 bytes with each byte being used to hold an 8 bit character, But the systems memory was in individual 7 bit characters with extra bits associated with each character (1 or 2 of them) used to define the end of a 'word' or an 'item' or a 'record' So addition and subtraction was done on a 'character' mode working along the digits until a word ending bit was found, so a number could be almost all of memory (H200 systems) There were also systems with 36 and systems with 48 bit words - just to really annoy those doing conversions to newer (and different manufacturer's) hardware. Even more fun when a manufacturer moved their hardware from 7 bit data storage to 9 bit (e.g. mag-tapes) so the replacement hardware would not run the drives that read the old data storage media Hey - seen a 5? floppy disk recently, let alone an 8" or 11" one ? OK - how about a 3" one? And - NOT MANY PPEOPLE KNOW THIS Within VBA - Date formats c means date (if value >=1) and then hh:mm:ss if a fractional part oooo means monthname in the local format aaaa means weekday in local format w means weekday (Sunday is day 1) ww is week of the year m is month, or if in {} or following h then minutes n is minutes - so you don't need to use m q means quarter of the year y means day of the year and text one or more @ characters means the text string at this place in the string and only as many characters as there are @'s one or more & characters means the character at this place in the string and only as many characters as there are &'s The output will be the exact number of & or @ in the string with the source characters dropped where format string includes spaces in a string of @ or & spaces in an @ string meaning a space in the output and a space in an & string means closeup the result. Prefix markers in the format string can be > means output uppercase Hi Jim It might be simpler - or would at least follow a standard - to convert to Unix time. The function here uses Decimal, but values aren't larger than they could be stored as Currency. ' Returns the Unix Time in seconds for a specified date. ' UtcDate can be any Date value of VBA with a resolution of one millisecond. ' ' Examples: ' 100-01-01 00:00:00.000 -> -59011459200 ' 100-01-01 00:00:00.001 -> -59011459199.999 ' 100-01-01 00:00:00.002 -> -59011459199.998 ' 1899-12-30 00:00:00.000 -> -2209161600 ' 1970-01-01 00:00:00.000 -> 0 ' 2018-08-18 03:24:47.000 -> 1534562687 ' 2018-08-18 18:24:47.000 -> 1534616687 ' 9999-12-31 23:59:59.000 -> 253402300799 ' 9999-12-31 23:59:59.998 -> 253402300799.998 ' 9999-12-31 23:59:59.999 -> 253402300799.999 ' ' 2016-02-08. Gustav Brock, Cactus Data ApS, CPH. ' Public Function UnixDate( _ ByVal UtcDate As Date) _ As Variant Dim Result As Variant Result = Int((CDec(DateToTimespan(UtcDate) + CDec(UtOffset)) * MillisecondsPerDay + 0.5)) / MillisecondsPerSecond UnixDate = Result End Function -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Jim Lawrence Sendt: 26. november 2018 23:16 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? I wonder, if the number could be stored as just a value without a decimal point. Many years ago when working with the AcPac accounting package, I found they never stored decimal numbers because of the round off errors. They would store a number as a whole number and then store a mantissa value. So a number would store like 12345698123 and a mantissa value of 9 and when the value was displayed it showed 12.345698123. Is that a possible solution? Also, in my much younger years I used Fortran and it would have number values of a hundred of more decimal places. I do not remember any round off errors. Here is a link to an online Fortran editor: https://www.jdoodle.com/execute-fortran-online There is a full open source version of Fortran (http://gcc.gnu.org/fortran/) and its compiler...download it, run it and use it. ;-) ...And then of course, and I am really dating myself, there is log tables and log functions. They were basically used to eliminate the need for decimal numbers, multiplying and dividing. No round off or number storage errors. Jim ----- Original Message ----- From: "Gustav Brock" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 7:21:58 AM Subject: Re: [AccessD] Losing 3ms on date insert? Hi Ryan The original value is exactly 2018-11-20 16:00:00.000. The gravitation is exactly 5ms. It will, when stored in SQL Server using DateTime be rounded to: 43424.6666666319 which is - as you have noted - 3ms off. However, the 5ms cannot even be caused by some rounding, so there must be something in between, we don't know of. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Ryan W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? Ok looking at this again the dates being stored in excel are start off as: 43424.6666666667 but then gravitate to: 43424.6666666088 I'm not sure I understand why though, they're all being input as 11/20/2018 16:00 and then copied down the row. From jamesbutton at blueyonder.co.uk Tue Nov 27 05:20:59 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Tue, 27 Nov 2018 11:20:59 -0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <5BFC9F48.15633.13FE8DF5@stuart.lexacorp.com.pg> References: <5BFC9F48.15633.13FE8DF5@stuart.lexacorp.com.pg> Message-ID: Stuart, Thanks for the info As per the usual GIGO - I take the correction to the stored input. I was not aware that the date/time was actually maintained to the milliseconds by the VBA processing. Somehow I had got the idea that while the storage would allow for parts of seconds, the time management within VBA had been set to effectively discount any part of a time less than a second that was entered on the basis it was not stored accurately. Mostly I have been using the numeric "Double" to hold times that had to be passed to Excel And - this, actually an Access thread. Regards, and thanks for the link - With the bit about 3.3 milliseconds accuracy in the older DBMS And .... My main developer experiences with MS DBMS's - Access etc. were way .. way .... way ..... back in the 1990'ies. JimB -----Original Message----- From: AccessD On Behalf Of Stuart McLachlan Sent: Tuesday, November 27, 2018 1:35 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Losing 3ms on date insert? There ARE milliseconds available in a stored Date/Time. It's just that MS make it very difficult to display or work with them. "hh:mm:ss" is just a display format and doesn't tell us anything about the actual data storage. As you say, the storage is a Double which gives you 15-17 decimal digits of precision. Assuming that you use a maximum of 6 of those for the date part (which will handle up to around the year 2740!), that still leaves at least 9 significant digits. Since a second only required 5 significant digits (1/86400) that leaves a further 4 significant digits for partial seconds (i.e 1/1000 second precision). http://www.devx.com/dbzone/Article/39046 "In fact, Access and Jet both can store milliseconds because Double, the underlying data type of date/time, has a resolution one thousand times larger than date/time's smallest increment of one second. However, manipulating time values with millisecond precision in Access requires some crafty programming. You need the help of a couple of API calls, which you wrap in functions that mimic the standard timing functions in Access. This article explains how to apply this technique, which will enable you to create, retrieve, and measure time values down to the millisecond. " On 27 Nov 2018 at 0:35, James Button via AccessD wrote: > > IN VBA a date is an 8 bit floating point value as in integer day and > fractional hh:mm:ss > > Note NO MILLISECONDS > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From stuart at lexacorp.com.pg Tue Nov 27 05:24:16 2018 From: stuart at lexacorp.com.pg (Stuart McLachlan) Date: Tue, 27 Nov 2018 21:24:16 +1000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: <805187537.353352430.1543296725979.JavaMail.zimbra@shaw.ca>, <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg>, Message-ID: <5BFD2960.32452.1619FD94@stuart.lexacorp.com.pg> That's just a simple example of using a PowerBASIC application to control Excel. On 27 Nov 2018 at 5:09, Bill Benson wrote: > Stuart, where do you use that code? > > On Tue, Nov 27, 2018 at 12:48 AM Stuart McLachlan > wrote: > > > In answer to your question: Yes. > > > > But I don't see how your link relates to that. OLE is a different > > beasst to passing data to and from a spreadsheet. > > > > Here's an example of controlling a spreadsheet from another > > application (which could easily be a service). > > > > > > #COMPILER PBWIN 10 > > #COMPILE EXE > > #DIM ALL > > #INCLUDE ONCE "Excel.inc" > > > > > > '------------------------------------------------------------------- > > ----------- ' Main application entry point... ' FUNCTION PBMAIN > > DIM oExcelApp AS Excel_Application > > DIM oExcelWorkbook AS Excel_Workbook > > DIM oExcelWorkSheet AS Excel_WorkSheet > > > > DIM vBool AS VARIANT > > DIM vText1 AS VARIANT > > DIM vText2 AS VARIANT > > DIM vFile AS VARIANT > > DIM vFileFmt AS VARIANT > > DIM oVnt AS VARIANT > > DIM nVnt AS VARIANT > > DIM vX AS VARIANT > > DIM vY AS VARIANT > > DIM x AS LONG > > DIM y AS LONG > > DIM ws AS WSTRING > > > > ' Open an instance of EXCEL > > oExcelApp = ANYCOM $PROGID_Excel_Application > > > > ' Could EXCEL be opened? If not, terminate this app > > IF ISFALSE ISOBJECT(oExcelApp) OR ERR THEN > > MSGBOX "Excel could not be opened. Please check that Excel and > > VBA are > > installed." > > EXIT FUNCTION > > END IF > > > > ' Make MSEXCEL visible > > vBool = 1 > > OBJECT LET oExcelApp.Visible = vBool > > > > ' Create a new workbook in EXCEL > > OBJECT CALL oExcelApp.WorkBooks.Add TO oExcelWorkBook > > IF ISFALSE ISOBJECT(oExcelWorkbook) OR ERR THEN > > MSGBOX "Excel could not open a new workbook. Please check that > > VBA is > > installed." > > GOTO Terminate > > END IF > > > > ' Create a new worksheet in the workbook and use this > > ' worksheet reference to pump data into EXCEL > > OBJECT CALL oExcelWorkBook.WorkSheets.Add TO oExcelWorkSheet > > IF ISFALSE ISOBJECT(oExcelWorkSheet) OR ERR THEN > > MSGBOX "Excel could not open a new worksheet. Please check that > > VBA is > > installed." > > GOTO Terminate > > END IF > > > > FOR y = 1 TO 50 > > FOR x = 1 TO 5 > > vX = x > > vY = y > > ws = "Cell " & CHR$$(x + 64) & FORMAT$(y) > > vText1 = ws > > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText1 > > NEXT x > > > > vX = 6 > > nVnt = y + y / 10 > > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = nVnt > > > > vX = 7 > > ws = FORMAT$(RND(-1000,1000), "$#,.00") > > vText2 = ws > > OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText2 > > NEXT y > > > > OBJECT CALL oExcelWorksheet.PrintPreview > > > > ' Save the new XLS document to disk > > vFile = "Test.xls"$$ > > OBJECT CALL oExcelWorkBook.SaveAs(vFile) > > '--------------------------------------------------------------- > > - > > > > Terminate: > > MSGBOX "Press the OK button to close Excel and exit the > > application" > > > > ' Close the current document and then close EXCEL completely > > OBJECT CALL oExcelApp.ActiveWindow.Close > > OBJECT CALL oExcelApp.Quit > > > > ' Release the interfaces. We could omit this since the > > ' app is about to close, but "best practice" states we > > ' should clean our house before moving out. > > SET oExcelApp = NOTHING > > SET oExcelWorkbook = NOTHING > > SET oExcelWorkSheet = NOTHING > > > > END FUNCTION > > > > > > On 26 Nov 2018 at 22:32, Jim Lawrence wrote: > > > > > Can an external service be attached to an excel spreadsheet in > > > which parameters can be pasted back and forth? > > > > > > Like: > > > > > > https://support.office.com/en-us/article/insert-an-object-in-your- > > > exce l-spreadsheet-e73867b2-2988-4116-8d85-f5769ea435ba > > > http://bit.ly/2P5iUDh > > > > > > Jim > > > > > > > -- > > AccessD mailing list > > AccessD at databaseadvisors.com > > http://databaseadvisors.com/mailman/listinfo/accessd > > Website: http://www.databaseadvisors.com > > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > From jamesbutton at blueyonder.co.uk Tue Nov 27 05:32:07 2018 From: jamesbutton at blueyonder.co.uk (James Button) Date: Tue, 27 Nov 2018 11:32:07 -0000 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: Gustav, Thanks for the correction - And as per my earlier "Thanks" to Stuart, Avoiding the Date & time storage/manipulation process within VBA was - way back when, AFAIK the best approach if you wanted more accuracy than seconds. Also thanks for maintaining the online docs that expand on, or at least make details of MS workings more obvious to us simple techies. JimB -----Original Message----- From: AccessD On Behalf Of Gustav Brock Sent: Tuesday, November 27, 2018 10:18 AM To: Access Developers discussion and problem solving Subject: Re: [AccessD] Losing 3ms on date insert? Hi James I think you are mixing some things up. VBA uses the same data types throughout the Office applications, thus dates and their numeric values are identical. Milliseconds can be held within the entire range of the data type. But (refer to the link provided by Stuart) when displayed natively in Access, milliseconds are rounded to the nearest second. As the resolution around numeric zero (1899-12-30 00:00:00) is much higher than at the extreme values, also microseconds and nanoseconds - even ticks - can be held, though within still tighter limits, of course: ' Interval with minimum one microsecond resolution. Public Const MaxMicrosecondDateValue As Date = #5/18/1927# Public Const MinMicrosecondDateValue As Date = #8/13/1872# ' Interval with minimum one nanosecond resolution. Public Const MaxNanosecondDateValue As Date = #1/9/1900# Public Const MinNanosecondDateValue As Date = #12/20/1899# ' Interval with minimum one tick resolution. Public Const MaxTickDateValue As Date = #2:24:00 AM# Public Const MinTickDateValue As Date = -#2:24:00 AM# That said, you can't apply calculations on subsecond values reliably using the date values only, Double as they are behind the scene, because of the resulting floating point errors. Thus, you must convert to Decimal (as demonstrated in my previously posted Millisecond function) to avoid these errors. As to your listed format strings, these don't work: oooo means monthname in the local format aaaa means weekday in local format The first, I have already got pulled from the docs, but I missed the second. That's done now: https://github.com/MicrosoftDocs/VBA-Docs/pull/496 Note, that anyone with a GitHub account can contribute to the docs, now they are hosted at GitHub. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af James Button via AccessD Sendt: 27. november 2018 01:35 Til: 'Access Developers discussion and problem solving' Cc: James Button Emne: Re: [AccessD] Losing 3ms on date insert? Firstly - Gravitate how? - well turn your screen on it's side to avoid that effect of gravitation (snigger) However some of the following may be also associated with the problem - AFAIK VBA times are stored with less accuracy than Excel So it could be that the value is being truncated within the transmission from app to app IN VBA a date is an 8 bit floating point value as in integer day and fractional hh:mm:ss Note NO MILLISECONDS but with VBA you get dates before December 30, 1899 using negative integers Standards (Ha! - ha ha ha ) for PC hardware is usually that numbers are stored to 15 significant digits with about 300 "0"'s between the decimal point and that (up to 16) digit string. In VBA there is CURRENCY datatype that stores a value of up to 15 digits before the decimal point and up to 4 after it . Decimal is even more fun - as in different from Excel as Decimal allows up to 28 decimal places with the decimal place anywhere within those 28 BUT you have to use the CDEC function to convert the value into a 12byte storage block that is actually held under the Variant DIIM structure! Also remember Boolean conversion from/to numeric equivalent is different in VBA and Excel. In VBA there are Integer from -32,768 up to +32,767 Long which is -2,147,483,648 up to +2,147,483,647 Double -1.79769313486231E308 up to +1.79769313486232E308 And - for those with 64 bit OS and applications There is the LongLong VBA data type for 18, well, almost 19 digit numbers from -9,223,372,036,854,775,808 and 9,223,372,036,854,775,807. Also re accuracy of hundreds of digits Way back before PC's, there were machines that did not have storage arranged in 'words' of 4 8 or 16 bytes with each byte being used to hold an 8 bit character, But the systems memory was in individual 7 bit characters with extra bits associated with each character (1 or 2 of them) used to define the end of a 'word' or an 'item' or a 'record' So addition and subtraction was done on a 'character' mode working along the digits until a word ending bit was found, so a number could be almost all of memory (H200 systems) There were also systems with 36 and systems with 48 bit words - just to really annoy those doing conversions to newer (and different manufacturer's) hardware. Even more fun when a manufacturer moved their hardware from 7 bit data storage to 9 bit (e.g. mag-tapes) so the replacement hardware would not run the drives that read the old data storage media Hey - seen a 5? floppy disk recently, let alone an 8" or 11" one ? OK - how about a 3" one? And - NOT MANY PPEOPLE KNOW THIS Within VBA - Date formats c means date (if value >=1) and then hh:mm:ss if a fractional part oooo means monthname in the local format aaaa means weekday in local format w means weekday (Sunday is day 1) ww is week of the year m is month, or if in {} or following h then minutes n is minutes - so you don't need to use m q means quarter of the year y means day of the year and text one or more @ characters means the text string at this place in the string and only as many characters as there are @'s one or more & characters means the character at this place in the string and only as many characters as there are &'s The output will be the exact number of & or @ in the string with the source characters dropped where format string includes spaces in a string of @ or & spaces in an @ string meaning a space in the output and a space in an & string means closeup the result. Prefix markers in the format string can be > means output uppercase References: <5BFC9F48.15633.13FE8DF5@stuart.lexacorp.com.pg> Message-ID: <1672770939.360867484.1543384310518.JavaMail.zimbra@shaw.ca> Interesting. MS Access Can Handle Millisecond Time Values--Really MS Access can retrieve and measure time with millisecond precision, but only with the help of a few well-known API calls and several user-defined functions. by Susan Sales Harkins and Gustav Brock Jim ----- Original Message ----- From: "stuart" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 5:35:04 PM Subject: Re: [AccessD] Losing 3ms on date insert? There ARE milliseconds available in a stored Date/Time. It's just that MS make it very difficult to display or work with them. "hh:mm:ss" is just a display format and doesn't tell us anything about the actual data storage. As you say, the storage is a Double which gives you 15-17 decimal digits of precision. Assuming that you use a maximum of 6 of those for the date part (which will handle up to around the year 2740!), that still leaves at least 9 significant digits. Since a second only required 5 significant digits (1/86400) that leaves a further 4 significant digits for partial seconds (i.e 1/1000 second precision). http://www.devx.com/dbzone/Article/39046 "In fact, Access and Jet both can store milliseconds because Double, the underlying data type of date/time, has a resolution one thousand times larger than date/time's smallest increment of one second. However, manipulating time values with millisecond precision in Access requires some crafty programming. You need the help of a couple of API calls, which you wrap in functions that mimic the standard timing functions in Access. This article explains how to apply this technique, which will enable you to create, retrieve, and measure time values down to the millisecond. " On 27 Nov 2018 at 0:35, James Button via AccessD wrote: > > IN VBA a date is an 8 bit floating point value as in integer day and > fractional hh:mm:ss > > Note NO MILLISECONDS > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Wed Nov 28 00:11:22 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Tue, 27 Nov 2018 23:11:22 -0700 (MST) Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: References: Message-ID: <1241627489.360958792.1543385482220.JavaMail.zimbra@shaw.ca> Thanks for the info. Jim ----- Original Message ----- From: "Gustav Brock" To: "Access Developers discussion and problem solving" Sent: Tuesday, November 27, 2018 2:30:16 AM Subject: Re: [AccessD] Losing 3ms on date insert? Hi Jim It might be simpler - or would at least follow a standard - to convert to Unix time. The function here uses Decimal, but values aren't larger than they could be stored as Currency. ' Returns the Unix Time in seconds for a specified date. ' UtcDate can be any Date value of VBA with a resolution of one millisecond. ' ' Examples: ' 100-01-01 00:00:00.000 -> -59011459200 ' 100-01-01 00:00:00.001 -> -59011459199.999 ' 100-01-01 00:00:00.002 -> -59011459199.998 ' 1899-12-30 00:00:00.000 -> -2209161600 ' 1970-01-01 00:00:00.000 -> 0 ' 2018-08-18 03:24:47.000 -> 1534562687 ' 2018-08-18 18:24:47.000 -> 1534616687 ' 9999-12-31 23:59:59.000 -> 253402300799 ' 9999-12-31 23:59:59.998 -> 253402300799.998 ' 9999-12-31 23:59:59.999 -> 253402300799.999 ' ' 2016-02-08. Gustav Brock, Cactus Data ApS, CPH. ' Public Function UnixDate( _ ByVal UtcDate As Date) _ As Variant Dim Result As Variant Result = Int((CDec(DateToTimespan(UtcDate) + CDec(UtOffset)) * MillisecondsPerDay + 0.5)) / MillisecondsPerSecond UnixDate = Result End Function -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Jim Lawrence Sendt: 26. november 2018 23:16 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? I wonder, if the number could be stored as just a value without a decimal point. Many years ago when working with the AcPac accounting package, I found they never stored decimal numbers because of the round off errors. They would store a number as a whole number and then store a mantissa value. So a number would store like 12345698123 and a mantissa value of 9 and when the value was displayed it showed 12.345698123. Is that a possible solution? Also, in my much younger years I used Fortran and it would have number values of a hundred of more decimal places. I do not remember any round off errors. Here is a link to an online Fortran editor: https://www.jdoodle.com/execute-fortran-online There is a full open source version of Fortran (http://gcc.gnu.org/fortran/) and its compiler...download it, run it and use it. ;-) ...And then of course, and I am really dating myself, there is log tables and log functions. They were basically used to eliminate the need for decimal numbers, multiplying and dividing. No round off or number storage errors. Jim ----- Original Message ----- From: "Gustav Brock" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 7:21:58 AM Subject: Re: [AccessD] Losing 3ms on date insert? Hi Ryan The original value is exactly 2018-11-20 16:00:00.000. The gravitation is exactly 5ms. It will, when stored in SQL Server using DateTime be rounded to: 43424.6666666319 which is - as you have noted - 3ms off. However, the 5ms cannot even be caused by some rounding, so there must be something in between, we don't know of. /gustav -----Oprindelig meddelelse----- Fra: AccessD P? vegne af Ryan W Sendt: 26. november 2018 16:01 Til: Access Developers discussion and problem solving Emne: Re: [AccessD] Losing 3ms on date insert? Ok looking at this again the dates being stored in excel are start off as: 43424.6666666667 but then gravitate to: 43424.6666666088 I'm not sure I understand why though, they're all being input as 11/20/2018 16:00 and then copied down the row. -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From accessd at shaw.ca Wed Nov 28 00:35:26 2018 From: accessd at shaw.ca (Jim Lawrence) Date: Tue, 27 Nov 2018 23:35:26 -0700 (MST) Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg> References: <5BFCDA6A.5630.14E58B0D@stuart.lexacorp.com.pg> Message-ID: <1595004878.361038649.1543386926661.JavaMail.zimbra@shaw.ca> The thought is that if your computer is capable of producing much larger values can not the office package be adapted to at least display them even if it can not do the calculations? That is interesting code? Jim ----- Original Message ----- From: "stuart" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 9:47:22 PM Subject: Re: [AccessD] Losing 3ms on date insert? In answer to your question: Yes. But I don't see how your link relates to that. OLE is a different beasst to passing data to and from a spreadsheet. Here's an example of controlling a spreadsheet from another application (which could easily be a service). #COMPILER PBWIN 10 #COMPILE EXE #DIM ALL #INCLUDE ONCE "Excel.inc" '------------------------------------------------------------------------------ ' Main application entry point... ' FUNCTION PBMAIN DIM oExcelApp AS Excel_Application DIM oExcelWorkbook AS Excel_Workbook DIM oExcelWorkSheet AS Excel_WorkSheet DIM vBool AS VARIANT DIM vText1 AS VARIANT DIM vText2 AS VARIANT DIM vFile AS VARIANT DIM vFileFmt AS VARIANT DIM oVnt AS VARIANT DIM nVnt AS VARIANT DIM vX AS VARIANT DIM vY AS VARIANT DIM x AS LONG DIM y AS LONG DIM ws AS WSTRING ' Open an instance of EXCEL oExcelApp = ANYCOM $PROGID_Excel_Application ' Could EXCEL be opened? If not, terminate this app IF ISFALSE ISOBJECT(oExcelApp) OR ERR THEN MSGBOX "Excel could not be opened. Please check that Excel and VBA are installed." EXIT FUNCTION END IF ' Make MSEXCEL visible vBool = 1 OBJECT LET oExcelApp.Visible = vBool ' Create a new workbook in EXCEL OBJECT CALL oExcelApp.WorkBooks.Add TO oExcelWorkBook IF ISFALSE ISOBJECT(oExcelWorkbook) OR ERR THEN MSGBOX "Excel could not open a new workbook. Please check that VBA is installed." GOTO Terminate END IF ' Create a new worksheet in the workbook and use this ' worksheet reference to pump data into EXCEL OBJECT CALL oExcelWorkBook.WorkSheets.Add TO oExcelWorkSheet IF ISFALSE ISOBJECT(oExcelWorkSheet) OR ERR THEN MSGBOX "Excel could not open a new worksheet. Please check that VBA is installed." GOTO Terminate END IF FOR y = 1 TO 50 FOR x = 1 TO 5 vX = x vY = y ws = "Cell " & CHR$$(x + 64) & FORMAT$(y) vText1 = ws OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText1 NEXT x vX = 6 nVnt = y + y / 10 OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = nVnt vX = 7 ws = FORMAT$(RND(-1000,1000), "$#,.00") vText2 = ws OBJECT LET oExcelWorkSheet.Cells.Item(vY, vX) = vText2 NEXT y OBJECT CALL oExcelWorksheet.PrintPreview ' Save the new XLS document to disk vFile = "Test.xls"$$ OBJECT CALL oExcelWorkBook.SaveAs(vFile) '---------------------------------------------------------------- Terminate: MSGBOX "Press the OK button to close Excel and exit the application" ' Close the current document and then close EXCEL completely OBJECT CALL oExcelApp.ActiveWindow.Close OBJECT CALL oExcelApp.Quit ' Release the interfaces. We could omit this since the ' app is about to close, but "best practice" states we ' should clean our house before moving out. SET oExcelApp = NOTHING SET oExcelWorkbook = NOTHING SET oExcelWorkSheet = NOTHING END FUNCTION On 26 Nov 2018 at 22:32, Jim Lawrence wrote: > Can an external service be attached to an excel spreadsheet in which > parameters can be pasted back and forth? > > Like: > > https://support.office.com/en-us/article/insert-an-object-in-your-exce > l-spreadsheet-e73867b2-2988-4116-8d85-f5769ea435ba > http://bit.ly/2P5iUDh > > Jim > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com From ssharkins at gmail.com Wed Nov 28 06:42:52 2018 From: ssharkins at gmail.com (Susan Harkins) Date: Wed, 28 Nov 2018 07:42:52 -0500 Subject: [AccessD] Losing 3ms on date insert? In-Reply-To: <1672770939.360867484.1543384310518.JavaMail.zimbra@shaw.ca> References: <5BFC9F48.15633.13FE8DF5@stuart.lexacorp.com.pg> <1672770939.360867484.1543384310518.JavaMail.zimbra@shaw.ca> Message-ID: <008401d48717$e3ad73e0$ab085ba0$@gmail.com> You can thank Gustav for that gem. I just wrote it up. ? Susan H. Interesting. MS Access Can Handle Millisecond Time Values--Really MS Access can retrieve and measure time with millisecond precision, but only with the help of a few well-known API calls and several user-defined functions. by Susan Sales Harkins and Gustav Brock Jim ----- Original Message ----- From: "stuart" To: "Access Developers discussion and problem solving" Sent: Monday, November 26, 2018 5:35:04 PM Subject: Re: [AccessD] Losing 3ms on date insert? There ARE milliseconds available in a stored Date/Time. It's just that MS make it very difficult to display or work with them. "hh:mm:ss" is just a display format and doesn't tell us anything about the actual data storage. As you say, the storage is a Double which gives you 15-17 decimal digits of precision. Assuming that you use a maximum of 6 of those for the date part (which will handle up to around the year 2740!), that still leaves at least 9 significant digits. Since a second only required 5 significant digits (1/86400) that leaves a further 4 significant digits for partial seconds (i.e 1/1000 second precision). http://www.devx.com/dbzone/Article/39046 "In fact, Access and Jet both can store milliseconds because Double, the underlying data type of date/time, has a resolution one thousand times larger than date/time's smallest increment of one second. However, manipulating time values with millisecond precision in Access requires some crafty programming. You need the help of a couple of API calls, which you wrap in functions that mimic the standard timing functions in Access. This article explains how to apply this technique, which will enable you to create, retrieve, and measure time values down to the millisecond. " On 27 Nov 2018 at 0:35, James Button via AccessD wrote: > > IN VBA a date is an 8 bit floating point value as in integer day and > fractional hh:mm:ss > > Note NO MILLISECONDS > -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com -- AccessD mailing list AccessD at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/accessd Website: http://www.databaseadvisors.com