OVH Cloud OVH Cloud

Date avec heure. MAINTENANT() et NOW

4 réponses
Avatar
tintin92
Bonjour,

Souhaitant afficher l'heure en plus de la date j'ai modifié mon VBA de

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Date
End Sub

en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value =
MAINTENANT()
End Sub

Cette modification ne fonctionne pas.
J'ai une erreur.

Puis en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Now
End Sub

Ce code donne le résultat escompté.
Pourquoi "Now" marche et "MAINTENANT()" ou "MAINTENANT" non ?

Merci

Tintin92

4 réponses

Avatar
Philippe.R
Bonsoir Tintin,
" Pourquoi "Now" marche et "MAINTENANT" ?"
C'est tout simplement parce que VBA ne parle que Grand Breton.
--
Amicales Salutations
Retirer A_S_ pour répondre.
XL 97 / 2000 / 2002

"tintin92" a écrit dans le message de news:40a93029$0$31388$
Bonjour,

Souhaitant afficher l'heure en plus de la date j'ai modifié mon VBA de

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Date
End Sub

en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value > MAINTENANT()
End Sub

Cette modification ne fonctionne pas.
J'ai une erreur.

Puis en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Now
End Sub

Ce code donne le résultat escompté.
Pourquoi "Now" marche et "MAINTENANT()" ou "MAINTENANT" non ?

Merci

Tintin92






Avatar
GD
bonsoir,
;-)))
simplement parceque VbA ne comprend que le grand breton.....
on pourrait ....
y'en a qui ont essayé...
c'est vous qui voyez ...
pourquoi faire simple ???

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then
zz.Offset(0, 2).FormulaLocal = "=Maintenant()"
zz.Offset(0, 2).value=zz.Offset(0, 2).value
End if
End Sub
;-)))
@+


"tintin92" a écrit dans le message de
news:40a93029$0$31388$
Bonjour,

Souhaitant afficher l'heure en plus de la date j'ai modifié mon VBA de

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Date
End Sub

en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value > MAINTENANT()
End Sub

Cette modification ne fonctionne pas.
J'ai une erreur.

Puis en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Now
End Sub

Ce code donne le résultat escompté.
Pourquoi "Now" marche et "MAINTENANT()" ou "MAINTENANT" non ?

Merci

Tintin92






Avatar
GD
<);o}
même pô vrai !!!

mon mien d'excel il parle français ;-P
Oui... c'est vrai avec un horrible accent anglais.
par contre j'ai beau crier dans le micro il comprend pas le français
je lui causerai : arabe, chinois, javanais..... pour lui tout ça c'est de
l'hébreu
faut que je lui écrive tout en anglais !!!

voir là : http://www.microsoft.com/msagent/downloads/user.asp#tts
../..
Further note, that these text-to-speech engines are licensed only for use in
Microsoft Agent enabled applications and Web pages with a visibly displayed
Microsoft Agent character.
Select a text-to-speech (TTS) engineLernout & Hauspie® TruVoice TTS
engine - American English (1 MB exe)Lernout & Hauspie® TTS3000 TTS engine -
British English (2.5 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Dutch
(2.6 MB exe)Lernout & Hauspie® TTS3000 TTS engine - French (2.2 MB
exe)Lernout & Hauspie® TTS3000 TTS engine - German (2.2 MB exe)Lernout &
Hauspie® TTS3000 TTS engine - Italian (2 MB exe)Lernout & Hauspie® TTS3000
TTS engine - Japanese (3 MB exe)Lernout & Hauspie® TTS3000 TTS engine -
Korean (3 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Portuguese (Brazil)
(2.4 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Russian (2.9 MB
exe)Lernout & Hauspie® TTS3000 TTS engine - Spanish (2.4 MB exe)
Download selected engine

@+

;o)))


"Philippe.R" a écrit dans le message de
news:e8$
Bonsoir Tintin,
" Pourquoi "Now" marche et "MAINTENANT" ?"
C'est tout simplement parce que VBA ne parle que Grand Breton.
--
Amicales Salutations
Retirer A_S_ pour répondre.
XL 97 / 2000 / 2002

"tintin92" a écrit dans le message de
news:40a93029$0$31388$

Bonjour,

Souhaitant afficher l'heure en plus de la date j'ai modifié mon VBA de

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Date
End Sub

en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value > > MAINTENANT()
End Sub

Cette modification ne fonctionne pas.
J'ai une erreur.

Puis en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Now
End Sub

Ce code donne le résultat escompté.
Pourquoi "Now" marche et "MAINTENANT()" ou "MAINTENANT" non ?

Merci

Tintin92










begin 666 download_icon.gif
M1TE&.#EA$ `0`+,```#__W]_?# P ```/___X ``/```#_``" ````````
M`````````````````````"'Y! $`````+ `````0`! `0 1#$,@)2AET!L&[
MYP%&684QG-06K&PKK&)6QIELUMOG(0?<_C_:Z%:KS8HV`S$#' `!`8)T2I7Z
0=+IKM?H*`4[@<%@2`0`[````
`
end


Avatar
Philippe.R
Et v'la t'y pas qu'y chipote le GD !
;o)))))
--
Amicales Salutations

"GD" a écrit dans le message de news:
<);o}
même pô vrai !!!

mon mien d'excel il parle français ;-P
Oui... c'est vrai avec un horrible accent anglais.
par contre j'ai beau crier dans le micro il comprend pas le français
je lui causerai : arabe, chinois, javanais..... pour lui tout ça c'est de
l'hébreu
faut que je lui écrive tout en anglais !!!

voir là : http://www.microsoft.com/msagent/downloads/user.asp#tts
../..
Further note, that these text-to-speech engines are licensed only for use in
Microsoft Agent enabled applications and Web pages with a visibly displayed
Microsoft Agent character.
Select a text-to-speech (TTS) engineLernout & Hauspie® TruVoice TTS
engine - American English (1 MB exe)Lernout & Hauspie® TTS3000 TTS engine -
British English (2.5 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Dutch
(2.6 MB exe)Lernout & Hauspie® TTS3000 TTS engine - French (2.2 MB
exe)Lernout & Hauspie® TTS3000 TTS engine - German (2.2 MB exe)Lernout &
Hauspie® TTS3000 TTS engine - Italian (2 MB exe)Lernout & Hauspie® TTS3000
TTS engine - Japanese (3 MB exe)Lernout & Hauspie® TTS3000 TTS engine -
Korean (3 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Portuguese (Brazil)
(2.4 MB exe)Lernout & Hauspie® TTS3000 TTS engine - Russian (2.9 MB
exe)Lernout & Hauspie® TTS3000 TTS engine - Spanish (2.4 MB exe)
Download selected engine

@+

;o)))


"Philippe.R" a écrit dans le message de
news:e8$
Bonsoir Tintin,
" Pourquoi "Now" marche et "MAINTENANT" ?"
C'est tout simplement parce que VBA ne parle que Grand Breton.
--
Amicales Salutations
Retirer A_S_ pour répondre.
XL 97 / 2000 / 2002

"tintin92" a écrit dans le message de
news:40a93029$0$31388$

Bonjour,

Souhaitant afficher l'heure en plus de la date j'ai modifié mon VBA de

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Date
End Sub

en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value > > > MAINTENANT()
End Sub

Cette modification ne fonctionne pas.
J'ai une erreur.

Puis en

Private Sub Worksheet_Change(ByVal zz As Range)
If zz.Row Mod 4 = 0 And zz.Column = 3 Then zz.Offset(0, 2).Value = Now
End Sub

Ce code donne le résultat escompté.
Pourquoi "Now" marche et "MAINTENANT()" ou "MAINTENANT" non ?

Merci

Tintin92