Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
Word
application.errors
conversions
docmanagement
drawing.graphics
formatting.longdocs
international
internet.assistant
mail
mailmerge.fields
menustoolbars
newusers
numbering
oleinterop
pagelayout
printingfonts
setup.networking
spelling.grammar
tables
vba.addins
vba.beginners
vba.customization
vba.general
vba.userforms
web.authoring
word6-7macros
word97vba
  
 
date: Mon, 11 Feb 2008 07:50:49 -0700,    group: microsoft.public.word.vba.beginners        back       


Date Format   
I am using a Macro Public Function in Excel which format the date:

Optional Formato As String = "dd mmmm yyyy" _
                        ) As Variant

this display by example 11 Febrero 2008, 
but I need to display     11 de Febrero de 2008

It's possible to change to this format?

Thanks for your help

Complete Macro:
Public Function FechaSi( _
  Optional Condicion As Variant = "", _
  Optional SiCumple As Variant = "", _
  Optional SiNoCumple As Variant = "", _
  Optional Formato As String = "dd mmmm yyyy" _
                        ) As Variant
  If Condicion = "" Or Condicion = True Then
    If SiCumple = "" Then
      SiCumple = Format(Now, Formato)
    ElseIf IsDate(SiCumple) Then
      SiCumple = Format(CLng(CDate(SiCumple)), Formato)
    End If
    FechaSi = SiCumple
  Else
    If IsDate(SiNoCumple) Then SiNoCumple = _
      Format(CLng(CDate(SiNoCumple)), Formato)
    FechaSi = SiNoCumple
  End If
End Function
date: Mon, 11 Feb 2008 07:50:49 -0700   author:   Juan E. Acuña K.

Re: Date Format   
Try "dd \de mmmm \de yyyy"

-- 
Enjoy,
Tony

"Juan E. Acuña K."  wrote in message 
news:892D140A-22E9-492D-BFAD-E15C570AA9B5@microsoft.com...
>I am using a Macro Public Function in Excel which format the date:
>
> Optional Formato As String = "dd mmmm yyyy" _
>                        ) As Variant
>
> this display by example 11 Febrero 2008, but I need to display     11 de 
> Febrero de 2008
>
> It's possible to change to this format?
>
> Thanks for your help
>
> Complete Macro:
> Public Function FechaSi( _
>  Optional Condicion As Variant = "", _
>  Optional SiCumple As Variant = "", _
>  Optional SiNoCumple As Variant = "", _
>  Optional Formato As String = "dd mmmm yyyy" _
>                        ) As Variant
>  If Condicion = "" Or Condicion = True Then
>    If SiCumple = "" Then
>      SiCumple = Format(Now, Formato)
>    ElseIf IsDate(SiCumple) Then
>      SiCumple = Format(CLng(CDate(SiCumple)), Formato)
>    End If
>    FechaSi = SiCumple
>  Else
>    If IsDate(SiNoCumple) Then SiNoCumple = _
>      Format(CLng(CDate(SiNoCumple)), Formato)
>    FechaSi = SiNoCumple
>  End If
> End Function
>
date: Mon, 11 Feb 2008 15:20:35 -0000   author:   Tony Jollans My forename at my surname dot com

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us