views:

97

answers:

5

i'm tring to display hebrew string which should look like

1 גיל

when the number should be from the right side then space then Hebrew character

it seem to be easy but until now i didn't succeed to do it

when trying to build the string in bytes array it look in correct format but when displaying it the text changed that the number always in the left side

any suggestion?

A: 

When displayed where (file, console, web page)?

It sounds to me like an issue with right-to-left vs. left-to-right, can you set the page orientation?

Tamar
+1  A: 

The answer to this depends on how you're rendering the text.

Many environments (Word, WinForms, and others) have a right-to-left mode, which is exactly what you're looking for.

In WinForms, you can set the RightToLeft property of a control to true.

SLaks
+1  A: 

You need to specify the technology involved in order to get a specific helpful answer.

In general, when dealing with mixed Hebrew/English, there are two components. One is the paragraph orientation, and second is the characters orientation. In Hebrew, right-to-left mode would be the typical result for a paragraph, your text would be more like this:

<Hebrew> 1

(I can't imitate it using Hebrew characters due to the editor's limitation on SO, apparently).

What you want is a left-to-right paragraph orientation, that happens to have a Hebrew item in the list. How you accomplish that (or indeed if it can be done) will depend on the technology you are using.

Yishai
A: 

in HTML:

<tag style="direction:rtl;">hebrew text</tag>

Of course you should extract the style into an external CSS stylesheet and probably apply it to the body tag

Manu
A: 

Thanks guys,

i'm working with c#, the problem is that idon't work with controls or web page i trying to write it to stream which i send to file.

shlomtzi