473,396 Members | 1,997 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Console.WriteLine Hebrew

Hi!

I am trying to print Hebrew characters:

Module Module1

Sub Main()

Console.WriteLine("איתי")

End Sub

End Module

And the output is:

????

How can I print in Hebrew to the console window?
Question number 2:

I am trying to insert data in Hebrew into my database:

Dim conn As New System.Data.SqlClient.SqlConnection()
conn.ConnectionString = "DataSource=.
\SQLEXPRESS;AttachDbFilename=|DataDirectory|\Datab ase2.mdf;Integrated
Security=True;User Instance=True"
conn.Open()
Dim cmd1 As New System.Data.SqlClient.SqlCommand("INSERT
DomainTable (EmailID, Email, Domain) VALUES('2', 'איתי', 'לוז')",
conn)
cmd1.ExecuteNonQuery()
I have configured the Email and Domain field as nvarchar(50) which is
supposed to take care of unicode. However, I am not certain that the
values are stored in the database as Hebrew. Any suggestions on how to
do this?

Thanks in advance,

Etay

Apr 18 '07 #1
2 3482
Etayki wrote:
Dim cmd1 As New System.Data.SqlClient.SqlCommand("INSERT
DomainTable (EmailID, Email, Domain) VALUES('2', 'איתי', 'לוז')",
conn)
cmd1.ExecuteNonQuery()
I have configured the Email and Domain field as nvarchar(50) which is
supposed to take care of unicode.
As far as I understand it you should prefix the nvarchar string literals
with N e.g.
VALUES('2', N'לוז', N'איתי')
However, I am not certain that the
values are stored in the database as Hebrew. Any suggestions on how to
do this?
Use SQL Server 2005 Management Studio Express and look at the table data.

--

Martin Honnen --- MVP XML
http://JavaScript.FAQTs.com/
Apr 18 '07 #2
On Apr 18, 5:42 pm, Martin Honnen <mahotr...@yahoo.dewrote:
Etayki wrote:
Dim cmd1 As New System.Data.SqlClient.SqlCommand("INSERT
DomainTable (EmailID, Email, Domain) VALUES('2', 'איתי', 'לוז')",
conn)
cmd1.ExecuteNonQuery()
I have configured the Email and Domain field as nvarchar(50) which is
supposed to take care of unicode.

As far as I understand it you should prefix the nvarchar string literals
with N e.g.
VALUES('2', N'לוז', N'איתי')
However, I am not certain that the
values are stored in the database as Hebrew. Any suggestions on how to
do this?

Use SQL Server 2005 Management Studio Express and look at the table data.

--

Martin Honnen --- MVP XML
http://JavaScript.FAQTs.com/
As far as I understand it you should prefix the nvarchar string
literals
with N e.g.
VALUES('2', N'לוז', N'איתי')

Yep, that did the trick - thanks there.

Apr 18 '07 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: jabailo | last post by:
This is driving me crazy. I finally got the Remoting sample chat application working almost. When I run the chat client in VS.NET it goes into an endless loop -- that's because I assume that...
1
by: Oz | last post by:
This is long. Bear with me, as I will really go through all the convoluted stuff that shows there is a problem with streams (at least when used to redirect stdout). The basic idea is that my...
7
by: shawnk | last post by:
Hello Everyone How do you format format numbers right-justified using Console.WriteLine(), i.e I need to line up numbers in vertical columns and the MSDN documentation is pretty poor Here is the...
5
by: Publicjoe | last post by:
I am working on a little app which uses colour in the console window. I have created a class to extend the console functionality but the ClearScreen method does not work correctly. I am enclosing a...
17
by: MumboJumbo | last post by:
Hi I have a really basic question hopefully some can help me with: Can you write a (i.e. one) C# project that works from the cmd line and gui? I seems if i write a GUI app it can't write to...
5
by: portroe | last post by:
Hi I am using console.Writeline in my simple program. I do not however see anything happening in the output window when I debug, there are also no error messages, Has anybody a tip on what...
2
by: djc | last post by:
out of all the overloads that pop up via intellisense for console.writeline() the following one confuses me: Console.WriteLine (string format, params object arg) 1) whats the deal with...
1
by: John Wright | last post by:
I am running a console application that connects to an Access database (8 million rows) and converts it to a text file and then cleans and compacts the database. When it runs I get the following...
1
by: Etayki | last post by:
Hi! I am trying to print Hebrew characters: Module Module1 Sub Main() Console.WriteLine("איתי")
0
by: Stephen Thomas | last post by:
Hi there I wonder if any one has encountered this problem or can suggest what is wrong. I am trying the a procedure from the msn site but get the following message: Error 1 The type or...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development projectplanning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.