Display issue with 2.0
Display issue with 2.0
The following code has worked for the past 10 years... it is displaying properly under 1.9SL1 (355) the british pound sign does not display properly in xbase++2.0
CREATEGET @PRO_CURRENCY ;
ROW @xx ITEM @num NSAYCOL Saycol NGETCOL getcol+1.5 ;
PICTURE "X";
VALID {|| PRO_CURRENCY$"123 " } ;
PROMPT "Enter currency Designation 1 = US ($) 2 = British (œ) 3 = Euro - (Leave Blank for None)" ;
MESSAGE 'Enter 1 for US Dollar ($) or 2 for British pound (œ) 3 for Euro '
this is all preprocessed into a dcsay/get
has anyone else come across this ??
CREATEGET @PRO_CURRENCY ;
ROW @xx ITEM @num NSAYCOL Saycol NGETCOL getcol+1.5 ;
PICTURE "X";
VALID {|| PRO_CURRENCY$"123 " } ;
PROMPT "Enter currency Designation 1 = US ($) 2 = British (œ) 3 = Euro - (Leave Blank for None)" ;
MESSAGE 'Enter 1 for US Dollar ($) or 2 for British pound (œ) 3 for Euro '
this is all preprocessed into a dcsay/get
has anyone else come across this ??
Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Re: Display issue with 2.0
Are you using SetLocale() to set the currency?
The eXpress train is coming - and it has more cars.
-
- Posts: 605
- Joined: Thu Jan 28, 2010 9:11 pm
- Location: Steven Point, Wisconsin USA
- Contact:
Re: Display issue with 2.0
I have not encountered this, but I have other items.
Re: Display issue with 2.0
rdonnay wrote:Are you using SetLocale() to set the currency?
only for euro
Code: Select all
IF PRO_CURRENCY=="3"
SetLocale( NLS_SCURRENCY, Chr(213) )
SetLocale( NLS_ICURRENCYEURO, "1" )
ELSE
SetLocale( NLS_SCURRENCY, "$" )
SetLocale( NLS_ICURRENCYEURO, "0" )
ENDIF
Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Re: Display issue with 2.0
bump...bwolfsohn wrote:rdonnay wrote:Are you using SetLocale() to set the currency?
only for euroCode: Select all
IF PRO_CURRENCY=="3" SetLocale( NLS_SCURRENCY, Chr(213) ) SetLocale( NLS_ICURRENCYEURO, "1" ) ELSE SetLocale( NLS_SCURRENCY, "$" ) SetLocale( NLS_ICURRENCYEURO, "0" ) ENDIF
I've tried
setlocale(NLS_SCURRENCY,"œ") // this s/b the pound sign.. When i paste this into xdot, it shows the lb sign, but it doesn't work... it returns a lower case o
the asc of œ is 111
when i originally wrote this in clipper, it worked....

but in 2.0, it doesn't

has anyone figured this out ??

Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Re: Display issue with 2.0
In most of our dialogs we do not actually display a pound sign.
But I do have a couple of dialogs that do display one and in those (in a DCSAY) I have to use ConvToOEMCP(<string including pound sign>) to get it to show correctly.
But I do have a couple of dialogs that do display one and in those (in a DCSAY) I have to use ConvToOEMCP(<string including pound sign>) to get it to show correctly.
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com
Real Business Applications Ltd
http://www.rbauk.com
Re: Display issue with 2.0
Reagan,
Thanks for the approach...
We use it more for printing invoices.. it's displayed in a few places, but bills are the key...
Thanks for the approach...
We use it more for printing invoices.. it's displayed in a few places, but bills are the key...
Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Re: Display issue with 2.0
It doesn't appear to work by itself, xdot still display a lower case oreganc wrote:In most of our dialogs we do not actually display a pound sign.
But I do have a couple of dialogs that do display one and in those (in a DCSAY) I have to use ConvToOEMCP(<string including pound sign>) to get it to show correctly.
are you using SET_CHARSET or localeconfigure() ??
I'm unable to test ? localeconfigure() in xdot since it throws an error...
Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Re: Display issue with 2.0
I don't use localeconfigure or SET CHARSET TO at all. Or XDot really.bwolfsohn wrote:It doesn't appear to work by itself, xdot still display a lower case oreganc wrote:In most of our dialogs we do not actually display a pound sign.
But I do have a couple of dialogs that do display one and in those (in a DCSAY) I have to use ConvToOEMCP(<string including pound sign>) to get it to show correctly.
are you using SET_CHARSET or localeconfigure() ??
I'm unable to test ? localeconfigure() in xdot since it throws an error...
On that dialog I have this DCSAY:
@ nRow,nCol DCSAY {|| UPLIFT_Disp_Value(iif(aTakings[TAK_EL_FO_VALUE]<>0,aTakings[TAK_EL_FO_VALUE],aTakings[TAK_EL_FO_ARRAY_TOTAL])) } ;
SIZE Rba_Col(12),Rba_GetHeight(1) ;
COLOR GRA_CLR_BLACK , Say_Field_Color() ;
OPTIONS XBPALIGN_RIGHT + XBPALIGN_VCENTER ;
ID "FO_TOTAL"
and the following function is the one used:
STATIC FUNCTION UPLIFT_Disp_Value(nValue)
LOCAL cValue
nValue := round(nValue,2)
if nValue < 0
cValue:="-£"+ntrim(abs(nValue),,2)
else
cValue:="£"+ntrim(nValue,,2)
endif
RETURN ConvToOEMCP(cValue)
The DCSAY on the dialog shows the pound sign followed immediately by the value to 2 decimal places. I have made a couple of small mods to remove some stuff to make it easier to read.
Incidentally, in your 1st post above, the pound sign in the PROMPT string shows as an 'oe' character in brackets...
Regan Cawkwell
Real Business Applications Ltd
http://www.rbauk.com
Real Business Applications Ltd
http://www.rbauk.com
Re: Display issue with 2.0
In xdot, when i ask it ? pound sign symbol, that is how it displays...reganc wrote:bwolfsohn wrote:reganc wrote:Incidentally, in your 1st post above, the pound sign in the PROMPT string shows as an 'oe' character in brackets...

Brian Wolfsohn
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises
Retired and traveling around the country to music festivals in my RV.
OOPS.. Corona Virus, so NOT traveling right now...
http://www.breadmanrises.com
FB travel group: The Breadman Rises