Printing in different language in dos mode with VB
Hi, anyone of you know what do if a vb program is not printing, local language words. It prints everything but not those words. So please help me.
Yeah of coz, printer does support those words, and it does print norwegian words from any other program. So nothing wrong with the printer...
Regards
lakki
[Edited by lakki_lakki on 04-05-2004 at 04:12 PM GMT]
04-05-2004 at 08:59 AM
|
stickleprojects Level: Moderator Registered: 09-09-2002 Posts: 891
Re: Printing in different language in dos mode with VB
Hi lakki,
The title of your question suggests that you are printing to STDOUT or some-such from VB.
If so,
Windows was created (amongst other reasons) to provide a standard method for programmers to control printers and graphics...
Therefore,
You need to send special control characters to your printer from DOS mode in order for it to print the norwegian character-set.
You will need to obtain these codes from your manual or the manufacturer... good luck! ;)
Kieron
____________________________
Build it better, faster, quicker, easier.. then fix it (non-offical MS mission statement)
04-05-2004 at 11:11 PM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi, take a look on the code below which we are using to print..
Now we have to use the manual or manufacturer what do you mean by that..
Next we tried to make a funtion to map characters, mean to convert it. But does not work it either..
Now tell me how to send those special control characters...??
thanks anyway..
[Edited by lakki_lakki on 05-05-2004 at 05:50 PM GMT]
05-05-2004 at 05:41 PM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi, Steve...it does not work, now please read this..when i try to use "edit" to check it then it does not appear those words in edit either..i don't what do. I have tried everything i could but same result..please to understand my problem do this or come on chatting tommarow...
" make a print.dat file first and output forinstance some text like "norwegian is a funny language..i can't print Ø or æ
and then print from that print.dat file while using batchfile with shell command or just try to open the print.bat file in "edit" dos..
regards
lakki
05-05-2004 at 08:13 PM
|
steve_w Level: Moderator Registered: 18-04-2003 Posts: 1156
Re: Printing in different language in dos mode with VB
Re: Printing in different language in dos mode with VB
well,
i don't think that is the case here, it is something with the dos, which simply refuse to print norwegian words..now i have checked it, there is no problem in windows., if i give ascii value of 248 mean ø but when i open that file in Edit then i can't se that word, but i see something else..and ascii code 155 shows that word ø, now that's not correct.so there is something more...you just try to write those words in note pad and then try to open it in "Edit(dos)", then you'll know what i am talking about. So pls try again.
Regards
lakki
07-05-2004 at 12:08 PM
|
steve_w Level: Moderator Registered: 18-04-2003 Posts: 1156
Re: Printing in different language in dos mode with VB
Dos is only going to display what it thinks the ascii char is going to look like, that will depend on the code page you are using. The printer will also do the same. If its any help I have attached a dos application which displays the characters for each ascii value.
Re: Printing in different language in dos mode with VB
well, i have that list already. But let me try one thing more. Everything is being printed correctly if i open that dat.file in the note pad. And then print form the note pad. But that prints on full display, i mean On a A4 paper.
But i am using a different type of paper..well let's what happens..
regards
lakki
07-05-2004 at 01:07 PM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi steve
I have still not mananged to print norwegian words..did you find any more information about that please help me..
Waiting for you reply
lakki
09-05-2004 at 06:28 PM
|
steve_w Level: Moderator Registered: 18-04-2003 Posts: 1156
Re: Printing in different language in dos mode with VB
Sorry, misunderstood you , I thought you said that you were going to try something. I'll look again tomorrow.
Steve
10-05-2004 at 03:53 PM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi, Steve..
Thanks for paying tention to me. I think my problem is not with the print, it is more for vb code. Because is just doing his job. He is getting something and throwing it to the paper. It is dos which is not accepting norwegian chracters.
So if you just write some norwegian words..like
Løk(onions) is good for the health, and åpen(open)..save this file and open this is in dos..and then print from the dos(on the screen or to a printer)..then you know my problem...
I hope we manange this togehter...i am so depressed because of this.
lakki
10-05-2004 at 08:05 PM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi, I did it, thanks for your help, if you want to know how i did it, then you are welcome to ask me...
bye
lakki
12-05-2004 at 04:48 PM
|
steve_w Level: Moderator Registered: 18-04-2003 Posts: 1156
Re: Printing in different language in dos mode with VB
Well done, please post how you did for two reasons, a) I'd like to know if I was on the right track and b) for any future posts we get.
Thanks Steve
13-05-2004 at 09:42 AM
|
lakki_lakki Level: Guest
Re: Printing in different language in dos mode with VB
Hi,
I made a funtion as " string" using "replace"....to replace the words.. by using a public funtion...and then just finding out the chr(value) of each word, using "if and else"...through out..