Is it stored in 4D as a date if so just do this C_DATE($Date_d) $Date_d:=!2019-01-01! c_text($result_txt) $result_txt:=String(Month of($date_d);"00")+String(Month of($date_d);"00")+Substring(String(Year of($date_d);"0000");3;2)
You will always have a 6 character result On Tue, Jan 29, 2019 at 12:26 PM Douglas von Roeder via 4D_Tech <[email protected]> wrote: > > Hilsen: > > How about putting the logic in 4D code and then branch to the appropriate > format. Intelligent formats are handy and elegant but don't have the > simplicity, flexibility, or transparency of 4D code. > > This sort of code is very quick to code and very easy to understand: > > If(length of date=5) > use format with leading 0 > Else > use standard date format > End if > > -- > Douglas von Roeder > 949-336-2902 > > > On Tue, Jan 29, 2019 at 3:45 AM 4dialog via 4D_Tech <[email protected]> > wrote: > > > I need to build a excel document where born date (6 char) needs to be > > number > > format with leading zero if only 5 chars. > > How can i do this in XLS plugin, what command, what params. > > There is many format commands but cant find any documentation on them with > > explanation? > > > > > > > > ----- > > Hilsen > > -------------------------------------- > > Helge Antonsen > > www.4dialog.no > > -- > > Sent from: http://4d.1045681.n5.nabble.com/4D-Tech-f1376241.html > > ********************************************************************** > > 4D Internet Users Group (4D iNUG) > > Archive: http://lists.4d.com/archives.html > > Options: https://lists.4d.com/mailman/options/4d_tech > > Unsub: mailto:[email protected] > > ********************************************************************** > ********************************************************************** > 4D Internet Users Group (4D iNUG) > Archive: http://lists.4d.com/archives.html > Options: https://lists.4d.com/mailman/options/4d_tech > Unsub: mailto:[email protected] > ********************************************************************** -- ----------------------------------------------------------------------------------------- Chuck Miller Voice: (617) 739-0306 Fax: (617) 232-1064 Informed Solutions, Inc. Brookline, MA 02446 USA Registered 4D Developer Providers of 4D, Sybase & SQL Server connectivity http://www.informed-solutions.com ----------------------------------------------------------------------------------------- This message and any attached documents contain information which may be confidential, subject to privilege or exempt from disclosure under applicable law. These materials are intended only for the use of the intended recipient. If you are not the intended recipient of this transmission, you are hereby notified that any distribution, disclosure, printing, copying, storage, modification or the taking of any action in reliance upon this transmission is strictly prohibited. Delivery of this message to any person other than the intended recipient shall not compromise or waive such confidentiality, privilege or exemption from disclosure as to this communication. ********************************************************************** 4D Internet Users Group (4D iNUG) Archive: http://lists.4d.com/archives.html Options: https://lists.4d.com/mailman/options/4d_tech Unsub: mailto:[email protected] **********************************************************************

