Difference in dates (SOLVED) tnks Mr. RAO

Difference in dates (SOLVED) tnks Mr. RAO

Postby Armando » Sat May 13, 2023 7:26 pm

Mr. Rao And friends:

I have these two codes

First one
Code: Select all  Expand view  RUN

            REDEFINE XBROWSE oBrw ID 200 OF oDlg;
                DATASOURCE oRsHdr;
                COLUMNS "HDR_FOL","HDR_FDM","HDR_REF","","","","","","SUC_NOM","HDR_CAN";
                HEADERS "Folio","Fecha","Referencia","Tipo","Unidades","Costos","Unidades","Costos","Sucursal","Can";
                COLSIZES 50,80,80,60,70,75,70,75,110,32;
                PICTURES "@Z 9999999","dd/mmm/yyyy",Nil,Nil,"@Z 9,999,999","@Z 99,999,999.99","@Z 9,999,999","@Z 99,999,999.99",Nil,Nil;
                JUSTIFY {AL_RIGHT,AL_RIGHT,AL_LEFT,AL_LEFT,AL_RIGHT,AL_RIGHT,AL_RIGHT,AL_RIGHT,AL_LEFT,AL_CENTER};
                FOOTERS AUTOSORT


Second one
Code: Select all  Expand view  RUN

         REDEFINE XBROWSE oBrw ID 200 OF oDlg;
            DATASOURCE oRsEfe ;
            COLUMNS "EFE_FEC","EFE_VTA","EFE_GAS","EFE_TOT","EFE_EFE","EFE_FAL";
            HEADERS "Fecha","Venta","Gastos","Total","Efectivo","Falta";
            COLSIZES 80,100,100,100,100,100;
            PICTURES "dd/mmm/yyyy","@Z 999,999,999,999.99","@Z 999,999,999,999.99","@Z 999,999,999,999.99","@Z 999,999,999,999.99","@Z 999,999,999,999.99";
            JUSTIFY {AL_RIGHT,AL_RIGHT,AL_RIGHT,AL_RIGHT,AL_RIGHT,AL_RIGHT};
            FOOTERS AUTOSORT
 


In the first example, the name of the month (second column) is displayed in Spanish, example 15/Ene/2023

But in the second code the name of the month (first column) is displayed in English, example 15/Jan/2023

Why?, I couldn't find the solution

Btw, The structure of both columns is defined the same

Code: Select all  Expand view  RUN

          "HDR_FDM DATE    NOT NULL DEFAULT '0000-00-00' COMMENT 'Fecha del movimiento'," +;
          "EFE_FEC DATE    NOT NULL DEFAULT '0000-00-00' COMMENT 'Fecha de la venta'," +;
 


And the difference is in the same PC

With best regards
Last edited by Armando on Sat May 13, 2023 8:15 pm, edited 1 time in total.
SOI, s.a. de c.v.
estbucarm@gmail.com
http://www.soisa.mex.tl/
http://sqlcmd.blogspot.com/
Tel. (722) 174 44 45
Carpe diem quam minimum credula postero
User avatar
Armando
 
Posts: 3229
Joined: Fri Oct 07, 2005 8:20 pm
Location: Toluca, México

Re: Difference in dates

Postby nageswaragunupudi » Sat May 13, 2023 8:05 pm

1. This has nothing to do with the database. XBrowse displays the date as FW_TRANSFORM( datevalue, "dd/mmm/yyy" ) and it depends on the language setting in the application.

2) Please clarify if you see the difference in the same application or different applications.

3) Please test
Code: Select all  Expand view  RUN

? FW_TRANSFORM( Date(), "dd/mmm/yyyy" )
 

and let us know the result.
Regards

G. N. Rao.
Hyderabad, India
User avatar
nageswaragunupudi
 
Posts: 10646
Joined: Sun Nov 19, 2006 5:22 am
Location: India

Re: Difference in dates

Postby Armando » Sat May 13, 2023 8:15 pm

Mr. Rao:

With your hint I have found the solution, I omitted these two lines of code, sorry, my mistake

Code: Select all  Expand view  RUN

   HB_CDPSELECT("ESWIN")
   HB_LangSelect( "ESWIN" )
 


Thank you very much

With best regards
SOI, s.a. de c.v.
estbucarm@gmail.com
http://www.soisa.mex.tl/
http://sqlcmd.blogspot.com/
Tel. (722) 174 44 45
Carpe diem quam minimum credula postero
User avatar
Armando
 
Posts: 3229
Joined: Fri Oct 07, 2005 8:20 pm
Location: Toluca, México


Return to FiveWin for Harbour/xHarbour

Who is online

Users browsing this forum: No registered users and 105 guests