5 messages in org.openoffice.fr.progRe: [prog] Calcul sur les dates (suite)
FromSent OnAttachments
Bernard MarcellyJun 29, 2005 5:39 am 
GeGeJun 29, 2005 12:16 pm 
GeGeJun 29, 2005 12:26 pm 
Bernard MarcellyJun 29, 2005 1:05 pm 
GeGeJun 29, 2005 11:35 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:Re: [prog] Calcul sur les dates (suite)Actions...
From:GeGe (ggn@free.fr)
Date:Jun 29, 2005 12:26:17 pm
List:org.openoffice.fr.prog

Je me répond en partie. Plus court:

oDocument = ThisComponent oForm = oDocument.DrawPage.Forms.Standard dim nouvDate as new com.sun.star.util.Date dim vDate as date if oForm.DateDebut.date>0 then vDate= cdatefromiso(oForm.DateDebut.date) nouvDate.Day = day(vDate) nouvDate.Month = month(vDate) nouvDate.Year = year(vDate)+1 oForm.updateDate(oForm.findColumn ("DATEFIN"),nouvDate)

Voila! Voili!

Question subsidiaire: peut-on vérifier la validité d'une date. Le calcul sur 29/02/2004 donne 29/02/2005!