September 20, 200520 yr Right, ive got a small problem, i need to be able to format a date in a certain field like this Saturday 22[color:blue]nd October. Is there anyway to get that second part (the nd) to automatically change according to what the date is... i.e. 21[color:blue]st or 23[color:blue]rd. Cheers for help, genx
September 20, 200520 yr Hy aflgenx! Look attachment. You must to continue calculation formula for all choices. Date.zip
September 20, 200520 yr For the life of me, I can't understand why you are creating those extra fields, aaa. Day and DayName are already functions. Hi aflgenx, This calculation (result of text) will do it all. Just copy/paste it into your calc box then change date to your real field name: Case( not IsEmpty( date ); DayName( date ) & " " & Day (date) & Case( PatternCount( " 1 21 31 "; " " & Day( date ) & " " ); "st"; PatternCount( " 2 22 "; " " & Day( date ) & " "); "nd"; PatternCount( " 3 23 "; " " & Day( date ) & " " ); "rd"; "th" ) & " " & MonthName( date ) ) The principle behind this pretty thing was gleaned from -Queue- LaRetta Edited September 20, 200520 yr by Guest Calc correction
September 20, 200520 yr Hi LaRetta it is fine... but with a little typo: Case(not IsEmpty(date); DayName(date) & " " & Day (date)& Case( PatternCount( " 1 21 31 "; " " & Day(date) & " " ); "st"; PatternCount( " 2 22 "; " " & Day(date) & " "); "nd"; PatternCount( " 3 23 "; " " & Day(date) & " " ); "rd"; "th" ) & " " & MonthName(date))
September 20, 200520 yr For the life of me, I can't understand why you are creating those extra fields, aaa. Hi, Laretta! I created this fields only for easy understanding. You are right, this fields is not necessary.
September 20, 200520 yr Thanks for the catch, Daniele! I will edit my calc also. That's what happens when I wake up at 2:30 AM and think I can work. :tongue2:
September 20, 200520 yr I created this fields only for easy understanding. You are right, this fields is not necessary. Hmmm, my concern is that others (particularly those new) may not realize those fields are unnecessary and will duplicate your example exactly to reproduce your suggestion. So instead of adding to their understanding, it adds to convolution instead because they will perpetuate 'fluff' fields unnecessarily. And each of these unnecessary calculations (used to then combine with the final calculation) will slow a system down substantially. The other issue that is important here is to be sure and type the darned calculations right the first time (my example above). LaRetta
Create an account or sign in to comment