Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > ActiveX COM > MarkupLabel Control
  New Posts New Posts RSS Feed - special unicode characters in XAML
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

special unicode characters in XAML

 Post Reply Post Reply
ElvisM View Drop Down
Senior Member
Senior Member

Joined: 12 October 2006
Location: Venezuela
Status: Offline
Points: 129
Post Options Post Options   Thanks (0) Thanks(0)   Quote ElvisM Quote  Post ReplyReply Direct Link To This Post Topic: special unicode characters in XAML
    Posted: 13 July 2016 at 7:23pm
Another thing...

Iam working with accent letters (Á, á, Ë, e, Ñ, ñ, etc) but markip fails if you use this special characters... Confused

I read some post, and I saw that for special characters as "&", "<", ">", "/", etc, you can solve it using escape words as &amp, &it, &gt, etc... However if you try to use the escape words for accents, they dont work, markup fails... 

Is there either a solution or tip for this behavior?

Best regards,
Product: Xtreme SuitePro (ActiveX) version 17.2
Platform: Windows 10 64bits
Language: Visual Basic 2015
Back to Top
olebed View Drop Down
Admin Group
Admin Group

Joined: 01 July 2014
Location: Ukraine
Status: Offline
Points: 841
Post Options Post Options   Thanks (0) Thanks(0)   Quote olebed Quote  Post ReplyReply Direct Link To This Post Posted: 17 July 2016 at 7:31am
Hello ElvisM,

I think you forgot something from declarations in XAML, see our sample 

c:\Program Files (x86)\Codejock Software\ActiveX\Xtreme SuitePro ActiveX v17.2.0\Samples\Common\VB\MarkupSample\frmMain.frm

See using MarkupLabel1.
<!-- xaml code from VB MarkupSample samle -->
<Border xmlns='' xmlns:x='' Background="Yellow">

<ScrollViewer HorizontalAlignment="Center" VerticalAlignment="Center" VerticalScrollBarVisibility="Auto">
<StackPanel TextElement.FontSize="14" TextElement.FontFamily="Tahoma" Background="LightGreen">
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Arabic"/>             <TextBlock Text="مـرحبــاً"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Danish"/>             <TextBlock Text="Velkommen"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Dutch"/>             <TextBlock Text="Welkom"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="English"/>             <TextBlock Text="Welcome"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Farsi"/>             <TextBlock Text="خـوش آمديـد"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="French"/>             <TextBlock Text="Bienvenue"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Gaelic"/>             <TextBlock Text="Fбilte"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="German"/>             <TextBlock Text="Willkommen"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Greek"/>             <TextBlock Text="Καλώς ήλθατε"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock Width= "100" Text="Gujarati"/>             <TextBlock Text="આવો યઘારો"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Hebrew"/>             <TextBlock Text="בִּרוּבִים חַבָּאִים"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Hindi"/>             <TextBlock Text="रवागत"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Italian"/>             <TextBlock Text="Benvenuto"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Japanese"/>             <TextBlock Text="よろてそ"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Korean"/>             <TextBlock Text="여보세요"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Polish"/>             <TextBlock Text="Witamy"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Portuguese"/>             <TextBlock Text="Bemvindo"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Punjabi"/>             <TextBlock Text="ਜੀ ਆਇਆਂ ਨੂੰ"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Russian"/>             <TextBlock Text="Добро пожаловать"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Simplified Chinese"/>             <TextBlock Text="欢迎"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Slovak"/>             <TextBlock Text="Vнtame vбs"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Spanish"/>             <TextBlock Text="Bienvenido"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Traditional Chinese"/>             <TextBlock Text="歡迎"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Turkish"/>             <TextBlock Text="Hoş geldiniz"/></StackPanel>
<StackPanel Orientation="Horizontal"><TextBlock MinWidth= "100" Text="Welsh"/>             <TextBlock Text="Croeso"/></StackPanel>


<!-- also xaml code from MFC samle -->
<?xml version='1.0' encoding='utf-8'?>
<Border xmlns='' xmlns:x='' 
Background='#eeffee' BorderBrush='#999999' BorderThickness='1'>
<StackPanel TextElement.FontFamily='Tahoma' Margin='4'>
<TextBlock TextWrapping='Wrap'><Bold>Markup supports Unicode text in ANSI applications.<LineBreak/>Use UTF-8 encode to enter it:</Bold></TextBlock>
<TextBlock TextWrapping='Wrap'><Italic>Languages:</Italic> العربية (ar) • Azərbaycan (az) • Български (bg) • Català (ca) • Česky (cs) • Deutsch (de) • Ελληνικά (el) • English (en) • Esperanto (eo) • Español (es) • فارسی (fa) • Suomi (fi) • Français (fr) • 日本語 (ja) • 한국어 (ko) • Lietuvių (lt) • മലയാളം (ml) • Македонски (mk) • नेपाल भाषा (new) • ਪੰਜਾਬੀ (pa) • Polski (pl) • Português (pt) • Română (ro) • Русский (ru) • Svenska (sv) • தமிழ் (ta) • ไทย (th) • Türkçe (tr) • Українська (uk) • Tiếng Việt (vi) • 中文 (zh)</TextBlock>

 Oleksandr Lebed
Back to Top
jpbro View Drop Down
Senior Member
Senior Member

Joined: 12 January 2007
Status: Offline
Points: 1345
Post Options Post Options   Thanks (0) Thanks(0)   Quote jpbro Quote  Post ReplyReply Direct Link To This Post Posted: 17 July 2016 at 10:23am
Make sure you are using the Unicode version of the control, and then just use the actual characters "Á, á, é, É, Ñ, ñ" or Chr$W() control codes.
Product: Xtreme SuitePro (ActiveX) version 16.2.6
Platform: Windows XP - SP3

Language: Visual Basic 6.0 SP6

Back to Top View Drop Down

Joined: 05 July 2017
Location: Brasil
Status: Offline
Points: 9
Post Options Post Options   Thanks (0) Thanks(0)   Quote Quote  Post ReplyReply Direct Link To This Post Posted: 16 December 2017 at 7:59am
I am building a report using MARKUP LABEL and PRINT PREVIEW for printing.
The Portuguese language is full of accents.
When I use accents, MARKUP works correctly, but when sending to PRINT PREVIEW printing does not work because PRINT PREVIEW does not carry accents.
To solve I had to build the MARKUP string in UTF-8 and use UTF-8 in PRINT PREVIEW and ANSI in MARKUP.
I believe this is not the best practice.

Looking at the MARKUP PAD (EXE) I realized that I can write an ANSI XAML and that the print works correctly.
I also noticed that the PRINT PREVIEW menu is disabled initially, but after some time it enables.
This gave me the impression that there is some kind of ANSI CONVERTER for UTF-8 to allow PRINT PREVIEW to work correctly.

I also noticed that the MARKUP PAD (VBP - Visual Basic 6) does not have the same behavior, forcing me to write in UTF-8 and then convert to ANSI
as mentioned initially.

The question is:
How can MARKUP PAD (exe) be able to receive ANSI text and print correctly?
Does it convert from ANSI to UTF-8?
How can we do this conversion?
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

This page was generated in 0.109 seconds.