|
View:
New views
20 Messages
—
Rating Filter:
Alert me
|
| < Prev | 1 - 2 | Next > |
|
|
Forcing leading zeros1) How do you force a field to be exactly two digits, ie. 01, 02, 03 ...
48? 2) How do you force Get( CurrentDate ) to have leading zeros in the month/day? Thanks, Trish _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosOn Nov 19, 2008, at 11:28 AM, VanBuskirk, Patricia wrote: > 1) How do you force a field to be exactly two digits, ie. 01, 02, > 03 ... > 48? Make it a text field, Right ( number & "0" ; 2 ) > 2) How do you force Get( CurrentDate ) to have leading zeros in the > month/day? For display? Use the Format|Date menu. -- Don't sweat the petty stuff. And don't pet the sweaty stuff. Lorne Walton, Maple Ridge, BC, Canada _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosAlmost. Try Right ( "0" & number ; 2 )
------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: Lorne & Joan Walton <walton@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 11:31:34 -0800 > To: <fmpexperts@...> > Subject: Re: Forcing leading zeros > > Make it a text field, Right ( number & "0" ; 2 ) _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zeros1) I may be looking at it wrong, but it seems that should be Right ( "0" & number ; 2 )??
2) It would be for an export file ... the people we are sending the file to need it to be, for example, "OTCWOCREATE_10192008_01.dat" with the current date in the middle (2-digit mo, 2-digit day, 4-digit year) Thanks Lorne! -----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Lorne & Joan Walton Sent: Wednesday, November 19, 2008 2:32 PM To: fmpexperts@... Subject: Re: Forcing leading zeros On Nov 19, 2008, at 11:28 AM, VanBuskirk, Patricia wrote: > 1) How do you force a field to be exactly two digits, ie. 01, 02, > 03 ... > 48? Make it a text field, Right ( number & "0" ; 2 ) > 2) How do you force Get( CurrentDate ) to have leading zeros in the > month/day? For display? Use the Format|Date menu. -- Don't sweat the petty stuff. And don't pet the sweaty stuff. Lorne Walton, Maple Ridge, BC, Canada _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosCan I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ?
-----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Steve Hearn Sent: Wednesday, November 19, 2008 2:36 PM To: FileMaker Experts Subject: Re: Forcing leading zeros Almost. Try Right ( "0" & number ; 2 ) ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: Lorne & Joan Walton <walton@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 11:31:34 -0800 > To: <fmpexperts@...> > Subject: Re: Forcing leading zeros > > Make it a text field, Right ( number & "0" ; 2 ) _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosOn Nov 19, 2008, at 11:38 AM, VanBuskirk, Patricia wrote: > 1) I may be looking at it wrong, but it seems that should be Right > ( "0" & number ; 2 )?? > Is my face red? ;-) > 2) It would be for an export file ... the people we are sending the > file to need it to be, for example, "OTCWOCREATE_10192008_01.dat" > with the current date in the middle (2-digit mo, 2-digit day, 4- > digit year) Then they need to have the field (that they're importing into) formatted with leading zeroes. Unless you want to send them dates that are actually text. In which case, see 1). -- I'm sorry, but I don't apologize for that. Lorne Walton, Maple Ridge, BC, Canada _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosYes.
On Nov 19, 2008, at 11:40 AM, VanBuskirk, Patricia wrote: > Can I do an auto-enter calc on the field using Right ( "0" & SELF ; > 2) ? -- Happiness is the perpetual possession of being well deceived. [Jonathon Swift] Lorne & Joan Walton, Maple Ridge, BC, Canada _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosHi Trish
> 1) How do you force a field to be exactly two digits, ie. 01, 02, > 03 ...48? Right ( "00" & Number , 2 ) > 2) How do you force Get( CurrentDate ) to have leading zeros in the > month/day? Select the field and use Date Format in the Format menu. Saludos Ibrahim Bittar Torres Director General Eikonsys FileMaker 9 Certified Developer http://www.eikonsys.com FileMaker Business Alliance _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosThese people make NO accommodations! We have to accommodate their every
whim! I am thinking maybe I can do a GetAsText and use the Right on the month and day part ... but not sure how to do that ... GetAsText (Date ( Right ( "0" & Get( CurrentDate ); 2 ); Right ( "0" & Get( CurrentDate ); Get( CurrentDate )) ?? -----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Lorne & Joan Walton Sent: Wednesday, November 19, 2008 2:42 PM To: fmpexperts@... Subject: Re: Forcing leading zeros On Nov 19, 2008, at 11:38 AM, VanBuskirk, Patricia wrote: > 1) I may be looking at it wrong, but it seems that should be Right > ( "0" & number ; 2 )?? > Is my face red? ;-) > 2) It would be for an export file ... the people we are sending the > file to need it to be, for example, "OTCWOCREATE_10192008_01.dat" > with the current date in the middle (2-digit mo, 2-digit day, 4- > digit year) Then they need to have the field (that they're importing into) formatted with leading zeroes. Unless you want to send them dates that are actually text. In which case, see 1). -- I'm sorry, but I don't apologize for that. Lorne Walton, Maple Ridge, BC, Canada _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosOn 11/19/08 at 2:40 PM -0500, VanBuskirk, Patricia wrote:
> Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ? Is the field in question a "number" field? Are you using the Separation Model? SELF doesn't work very well in the UI file; in fact, it may "?" your field because SELF will not resolve correctly. Best bet, if this auto-enter calculation is appropriate for the field in question, is to use the field's name iinstead of "SELF". Best wishes, Jason L. DeLooze Annapolis, MD USA "You must be the change you want to see in the world" _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosYes, you can do the auto-enter calc and have it replace existing data.
To format your dates for that export you'll need to put it together: Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( dateField ) ; 2 ) & Year ( dateField ) By habit, I add as many zeroes as digits I'm capturing in case the value I'm padding is empty. In this case that won't happen unless the entire date field is empty. ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 14:40:10 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ? > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:36 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Almost. Try Right ( "0" & number ; 2 ) > > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: Lorne & Joan Walton <walton@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 11:31:34 -0800 >> To: <fmpexperts@...> >> Subject: Re: Forcing leading zeros >> >> Make it a text field, Right ( number & "0" ; 2 ) > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosThanks Jason!
-----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Jason L DeLooze Sent: Wednesday, November 19, 2008 2:51 PM To: fmpexperts@... Subject: RE: Forcing leading zeros On 11/19/08 at 2:40 PM -0500, VanBuskirk, Patricia wrote: > Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ? Is the field in question a "number" field? Are you using the Separation Model? SELF doesn't work very well in the UI file; in fact, it may "?" your field because SELF will not resolve correctly. Best bet, if this auto-enter calculation is appropriate for the field in question, is to use the field's name iinstead of "SELF". Best wishes, Jason L. DeLooze Annapolis, MD USA "You must be the change you want to see in the world" _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosSo this might work?
Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) Also, right now I have it stripping out the "/" ... do I have to worry about that anymore using this method? -----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Steve Hearn Sent: Wednesday, November 19, 2008 2:51 PM To: FileMaker Experts Subject: Re: Forcing leading zeros Yes, you can do the auto-enter calc and have it replace existing data. To format your dates for that export you'll need to put it together: Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( dateField ) ; 2 ) & Year ( dateField ) By habit, I add as many zeroes as digits I'm capturing in case the value I'm padding is empty. In this case that won't happen unless the entire date field is empty. ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 14:40:10 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ? > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:36 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Almost. Try Right ( "0" & number ; 2 ) > > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: Lorne & Joan Walton <walton@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 11:31:34 -0800 >> To: <fmpexperts@...> >> Subject: Re: Forcing leading zeros >> >> Make it a text field, Right ( number & "0" ; 2 ) > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosIt is working!!! YeeHaw and thanks to all!
-----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of VanBuskirk, Patricia Sent: Wednesday, November 19, 2008 2:56 PM To: fmpexperts@... Subject: RE: Forcing leading zeros So this might work? Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) Also, right now I have it stripping out the "/" ... do I have to worry about that anymore using this method? -----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Steve Hearn Sent: Wednesday, November 19, 2008 2:51 PM To: FileMaker Experts Subject: Re: Forcing leading zeros Yes, you can do the auto-enter calc and have it replace existing data. To format your dates for that export you'll need to put it together: Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( dateField ) ; 2 ) & Year ( dateField ) By habit, I add as many zeroes as digits I'm capturing in case the value I'm padding is empty. In this case that won't happen unless the entire date field is empty. ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 14:40:10 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) ? > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:36 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Almost. Try Right ( "0" & number ; 2 ) > > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: Lorne & Joan Walton <walton@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 11:31:34 -0800 >> To: <fmpexperts@...> >> Subject: Re: Forcing leading zeros >> >> Make it a text field, Right ( number & "0" ; 2 ) > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosPatricia
This works. Let( [ d = Get(Currentdate); y = year(d); m = right("0" & Month(d);2); d = right("0" & Day(d);2) ]; // arrange in whatever date format is needed // d & "/" & m & "/" & y // y & "/" & m & "/" & d // m & "/" & d & "/" & y m&d&y ) Stephen --------- "The universe is a big place, perhaps the biggest." -- Kurt Vonnegut On Nov 19, 2008, at 12:55 PM, VanBuskirk, Patricia wrote: > So this might work? > > Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & > Day > ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) > > Also, right now I have it stripping out the "/" ... do I have to worry > about that anymore using this method? > > > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:51 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Yes, you can do the auto-enter calc and have it replace existing data. > > To format your dates for that export you'll need to put it together: > > Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( > dateField ) > ; 2 ) & Year ( dateField ) > > By habit, I add as many zeroes as digits I'm capturing in case the > value > I'm > padding is empty. In this case that won't happen unless the entire > date > field is empty. > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: "VanBuskirk, Patricia" <pvanbuskirk@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 14:40:10 -0500 >> To: <fmpexperts@...> >> Conversation: Forcing leading zeros >> Subject: RE: Forcing leading zeros >> >> Can I do an auto-enter calc on the field using Right ( "0" & SELF ; >> 2) > ? >> >> -----Original Message----- >> From: fmpexperts-bounces@... >> [mailto:fmpexperts-bounces@...] On Behalf Of Steve >> Hearn >> Sent: Wednesday, November 19, 2008 2:36 PM >> To: FileMaker Experts >> Subject: Re: Forcing leading zeros >> >> Almost. Try Right ( "0" & number ; 2 ) >> >> >> ------------------------------------------------ >> Steve Hearn >> :: FileMaker 9 Certified Developer :: >> FileMaker Technologies Team Leader >> CoreSolutions Development Inc. >> Web Site: http://www.coresolutions.ca >> London: (519) 641-7727 - Toronto: (416) 410-8649 >> ------------------------------------------------ >> software that works for you >> >> >>> From: Lorne & Joan Walton <walton@...> >>> Reply-To: <fmpexperts@...> >>> Date: Wed, 19 Nov 2008 11:31:34 -0800 >>> To: <fmpexperts@...> >>> Subject: Re: Forcing leading zeros >>> >>> Make it a text field, Right ( number & "0" ; 2 ) >> >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosThis method extracts the month, day and year values from the current date
(your calc is correct) and puts them all in one text string. Separators like "/" or "-" are stripped out unless the calc explicitly puts them in. For instance: Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & "/" & Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & "/" & Year ( Get ( CurrentDate ) ) ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 14:55:48 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > So this might work? > > Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & Day > ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) > > Also, right now I have it stripping out the "/" ... do I have to worry > about that anymore using this method? > > > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:51 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Yes, you can do the auto-enter calc and have it replace existing data. > > To format your dates for that export you'll need to put it together: > > Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( > dateField ) > ; 2 ) & Year ( dateField ) > > By habit, I add as many zeroes as digits I'm capturing in case the value > I'm > padding is empty. In this case that won't happen unless the entire date > field is empty. > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: "VanBuskirk, Patricia" <pvanbuskirk@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 14:40:10 -0500 >> To: <fmpexperts@...> >> Conversation: Forcing leading zeros >> Subject: RE: Forcing leading zeros >> >> Can I do an auto-enter calc on the field using Right ( "0" & SELF ; 2) > ? >> >> -----Original Message----- >> From: fmpexperts-bounces@... >> [mailto:fmpexperts-bounces@...] On Behalf Of Steve >> Hearn >> Sent: Wednesday, November 19, 2008 2:36 PM >> To: FileMaker Experts >> Subject: Re: Forcing leading zeros >> >> Almost. Try Right ( "0" & number ; 2 ) >> >> >> ------------------------------------------------ >> Steve Hearn >> :: FileMaker 9 Certified Developer :: >> FileMaker Technologies Team Leader >> CoreSolutions Development Inc. >> Web Site: http://www.coresolutions.ca >> London: (519) 641-7727 - Toronto: (416) 410-8649 >> ------------------------------------------------ >> software that works for you >> >> >>> From: Lorne & Joan Walton <walton@...> >>> Reply-To: <fmpexperts@...> >>> Date: Wed, 19 Nov 2008 11:31:34 -0800 >>> To: <fmpexperts@...> >>> Subject: Re: Forcing leading zeros >>> >>> Make it a text field, Right ( number & "0" ; 2 ) >> >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
RE: Forcing leading zerosThanks Steve AND Stephen!
Instead of trying to work it into all the scripts, I made a new calculated field: Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) I made it a global field ... do I need to make it an unstored calculated field in order for it to update each day, or will this way do it too? Trish -----Original Message----- From: fmpexperts-bounces@... [mailto:fmpexperts-bounces@...] On Behalf Of Steve Hearn Sent: Wednesday, November 19, 2008 3:07 PM To: FileMaker Experts Subject: Re: Forcing leading zeros This method extracts the month, day and year values from the current date (your calc is correct) and puts them all in one text string. Separators like "/" or "-" are stripped out unless the calc explicitly puts them in. For instance: Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & "/" & Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & "/" & Year ( Get ( CurrentDate ) ) ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 14:55:48 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > So this might work? > > Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & > ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) > > Also, right now I have it stripping out the "/" ... do I have to worry > about that anymore using this method? > > > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 2:51 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > Yes, you can do the auto-enter calc and have it replace existing data. > > To format your dates for that export you'll need to put it together: > > Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( > dateField ) > ; 2 ) & Year ( dateField ) > > By habit, I add as many zeroes as digits I'm capturing in case the > I'm > padding is empty. In this case that won't happen unless the entire date > field is empty. > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: "VanBuskirk, Patricia" <pvanbuskirk@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 14:40:10 -0500 >> To: <fmpexperts@...> >> Conversation: Forcing leading zeros >> Subject: RE: Forcing leading zeros >> >> Can I do an auto-enter calc on the field using Right ( "0" & SELF ; > ? >> >> -----Original Message----- >> From: fmpexperts-bounces@... >> [mailto:fmpexperts-bounces@...] On Behalf Of Steve >> Hearn >> Sent: Wednesday, November 19, 2008 2:36 PM >> To: FileMaker Experts >> Subject: Re: Forcing leading zeros >> >> Almost. Try Right ( "0" & number ; 2 ) >> >> >> ------------------------------------------------ >> Steve Hearn >> :: FileMaker 9 Certified Developer :: >> FileMaker Technologies Team Leader >> CoreSolutions Development Inc. >> Web Site: http://www.coresolutions.ca >> London: (519) 641-7727 - Toronto: (416) 410-8649 >> ------------------------------------------------ >> software that works for you >> >> >>> From: Lorne & Joan Walton <walton@...> >>> Reply-To: <fmpexperts@...> >>> Date: Wed, 19 Nov 2008 11:31:34 -0800 >>> To: <fmpexperts@...> >>> Subject: Re: Forcing leading zeros >>> >>> Make it a text field, Right ( number & "0" ; 2 ) >> >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosAn unstored calc will update each day; a global calc will only update if you
open and close Define Database. ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: "VanBuskirk, Patricia" <pvanbuskirk@...> > Reply-To: <fmpexperts@...> > Date: Wed, 19 Nov 2008 15:10:22 -0500 > To: <fmpexperts@...> > Conversation: Forcing leading zeros > Subject: RE: Forcing leading zeros > > Thanks Steve AND Stephen! > > Instead of trying to work it into all the scripts, I made a new > calculated field: > > Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & Day > ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) > > I made it a global field ... do I need to make it an unstored calculated > field in order for it to update each day, or will this way do it too? > > Trish > > -----Original Message----- > From: fmpexperts-bounces@... > [mailto:fmpexperts-bounces@...] On Behalf Of Steve > Hearn > Sent: Wednesday, November 19, 2008 3:07 PM > To: FileMaker Experts > Subject: Re: Forcing leading zeros > > This method extracts the month, day and year values from the current > date > (your calc is correct) and puts them all in one text string. Separators > like > "/" or "-" are stripped out unless the calc explicitly puts them in. > > For instance: > Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & "/" & > Right ( "00" & Day ( Get ( CurrentDate ) ) ; 2 ) & "/" & > Year ( Get ( CurrentDate ) ) > > ------------------------------------------------ > Steve Hearn > :: FileMaker 9 Certified Developer :: > FileMaker Technologies Team Leader > CoreSolutions Development Inc. > Web Site: http://www.coresolutions.ca > London: (519) 641-7727 - Toronto: (416) 410-8649 > ------------------------------------------------ > software that works for you > > >> From: "VanBuskirk, Patricia" <pvanbuskirk@...> >> Reply-To: <fmpexperts@...> >> Date: Wed, 19 Nov 2008 14:55:48 -0500 >> To: <fmpexperts@...> >> Conversation: Forcing leading zeros >> Subject: RE: Forcing leading zeros >> >> So this might work? >> >> Right ( "00" & Month ( Get ( CurrentDate ) ) ; 2 ) & Right ( "00" & > Day >> ( Get ( CurrentDate ) ) ; 2 ) & Year ( Get ( CurrentDate ) ) >> >> Also, right now I have it stripping out the "/" ... do I have to worry >> about that anymore using this method? >> >> >> >> -----Original Message----- >> From: fmpexperts-bounces@... >> [mailto:fmpexperts-bounces@...] On Behalf Of Steve >> Hearn >> Sent: Wednesday, November 19, 2008 2:51 PM >> To: FileMaker Experts >> Subject: Re: Forcing leading zeros >> >> Yes, you can do the auto-enter calc and have it replace existing data. >> >> To format your dates for that export you'll need to put it together: >> >> Right ( "00" & Month ( dateField ) ; 2 ) & Right ( "00" & Day ( >> dateField ) >> ; 2 ) & Year ( dateField ) >> >> By habit, I add as many zeroes as digits I'm capturing in case the > value >> I'm >> padding is empty. In this case that won't happen unless the entire > date >> field is empty. >> >> ------------------------------------------------ >> Steve Hearn >> :: FileMaker 9 Certified Developer :: >> FileMaker Technologies Team Leader >> CoreSolutions Development Inc. >> Web Site: http://www.coresolutions.ca >> London: (519) 641-7727 - Toronto: (416) 410-8649 >> ------------------------------------------------ >> software that works for you >> >> >>> From: "VanBuskirk, Patricia" <pvanbuskirk@...> >>> Reply-To: <fmpexperts@...> >>> Date: Wed, 19 Nov 2008 14:40:10 -0500 >>> To: <fmpexperts@...> >>> Conversation: Forcing leading zeros >>> Subject: RE: Forcing leading zeros >>> >>> Can I do an auto-enter calc on the field using Right ( "0" & SELF ; > 2) >> ? >>> >>> -----Original Message----- >>> From: fmpexperts-bounces@... >>> [mailto:fmpexperts-bounces@...] On Behalf Of Steve >>> Hearn >>> Sent: Wednesday, November 19, 2008 2:36 PM >>> To: FileMaker Experts >>> Subject: Re: Forcing leading zeros >>> >>> Almost. Try Right ( "0" & number ; 2 ) >>> >>> >>> ------------------------------------------------ >>> Steve Hearn >>> :: FileMaker 9 Certified Developer :: >>> FileMaker Technologies Team Leader >>> CoreSolutions Development Inc. >>> Web Site: http://www.coresolutions.ca >>> London: (519) 641-7727 - Toronto: (416) 410-8649 >>> ------------------------------------------------ >>> software that works for you >>> >>> >>>> From: Lorne & Joan Walton <walton@...> >>>> Reply-To: <fmpexperts@...> >>>> Date: Wed, 19 Nov 2008 11:31:34 -0800 >>>> To: <fmpexperts@...> >>>> Subject: Re: Forcing leading zeros >>>> >>>> Make it a text field, Right ( number & "0" ; 2 ) >>> >>> _______________________________________________ >>> FMPexperts mailing list >>> FMPexperts@... >>> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >>> _______________________________________________ >>> FMPexperts mailing list >>> FMPexperts@... >>> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >> >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au >> _______________________________________________ >> FMPexperts mailing list >> FMPexperts@... >> http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosOn 20/11/08 6:36 AM, "Steve Hearn" <shearn@...> wrote:
> Right ( "0" & number ; 2 ) Am I the only one that habitually writes this as Right ( "00" & number ; 2 ) (and no, not because 'number' might be empty) e. _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
|
|
Re: Forcing leading zerosAs I stated I also use 2 zeroes, more out of habit but it seems a good idea
in case 'number' is empty. Is there another reason? ------------------------------------------------ Steve Hearn :: FileMaker 9 Certified Developer :: FileMaker Technologies Team Leader CoreSolutions Development Inc. Web Site: http://www.coresolutions.ca London: (519) 641-7727 - Toronto: (416) 410-8649 ------------------------------------------------ software that works for you > From: Eric Scheid <genius@...> > Reply-To: <fmpexperts@...> > Date: Thu, 20 Nov 2008 10:01:22 +1100 > To: fmpexperts <fmpexperts@...> > Subject: Re: Forcing leading zeros > > On 20/11/08 6:36 AM, "Steve Hearn" <shearn@...> wrote: > >> Right ( "0" & number ; 2 ) > > Am I the only one that habitually writes this as > > Right ( "00" & number ; 2 ) > > (and no, not because 'number' might be empty) > > e. > > _______________________________________________ > FMPexperts mailing list > FMPexperts@... > http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au _______________________________________________ FMPexperts mailing list FMPexperts@... http://lists.ironclad.net.au/listinfo.cgi/fmpexperts-ironclad.net.au |
| < Prev | 1 - 2 | Next > |
| Free embeddable forum powered by Nabble | Forum Help |