Combining two non-ascii languages in userform

nd0911

Board Regular
Joined
Jan 1, 2014
Messages
166
I have userform with 2 textbox's, each textbox is for a different non-ascii language.

The user fill the textbox's and press "Submit" then in my code I generate a string of SQL query (INSERT INTO query) and send this string to SQL Server (in the SQL Server I have a "stored procedure" that continues from there, but that's not important for my question).

The thing is that I get a question marks (??????????) insteadof the text that the user submitted, I can solve one language if I change the windows language for non-unicode programs, but I can select only one language there, the second language is still creates thos question marks.

Is it possible for a string variable (or any other variable) to hold a string with 2 non-ascii language so I can send my SQL string to SQL server ?
 
Last edited:

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
I have userform with 2 textbox's, each textbox is for a different non-ascii language.

The user fill the textbox's and press "Submit" then in my code I generate a string of SQL query (INSERT INTO query) and send this string to SQL Server (in the SQL Server I have a "stored procedure" that continues from there, but that's not important for my question).

The thing is that I get a question marks (??????????) insteadof the text that the user submitted, I can solve one language if I change the windows language for non-unicode programs, but I can select only one language there, the second language is still creates thos question marks.

Is it possible for a string variable (or any other variable) to hold a string with 2 non-ascii language so I can send my SQL string to SQL server ?
How did you "change the windows language for non-unicode programs?" Did you change the system locale to a Unicode language?

I have my system locale set to traditional Chinese. I just created a userform with three texboxes and was able to enter traditional Chinese in one textbox, simplified Chinese in another, and copied and pasted Arabic to the third.

The problem may also be on the user's side, not on your side.
 
Upvote 0
How did you "change the windows language for non-unicode programs?" Did you change the system locale to a Unicode language?

I have my system locale set to traditional Chinese. I just created a userform with three texboxes and was able to enter traditional Chinese in one textbox, simplified Chinese in another, and copied and pasted Arabic to the third.

The problem may also be on the user's side, not on your side.
Ok, I was able to solve the problem and here are the conclusions:

1. The question marks that appear do not affect the text that will be send to SQL SERVER, even if it is concatenated with other text to a new variable.

2. The problem was probably within the stored procedure, although I had a very hard time checking it out there, because it's a long and very complex code that handles a lot of things, but my feeling that the problem is in the "dynamic SQL" that executes the SQL string I send there.

3. I solved the problem by sending a SQL string cleanly without the stored procedure.
 
Upvote 0

Forum statistics

Threads
1,214,985
Messages
6,122,606
Members
449,089
Latest member
Motoracer88

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top