|
-
Jul 9th, 2002, 03:49 PM
#1
Thread Starter
Need-a-life Member
-
Jul 9th, 2002, 09:31 PM
#2
Thread Starter
Need-a-life Member
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 9th, 2002, 09:45 PM
#3
The picture isn't missing
it looks good... but it's as hard to look through as the Registry
Remember, if someone's post was not helpful, you can always rate their post negatively  .
-
Jul 9th, 2002, 09:50 PM
#4
Thread Starter
Need-a-life Member
What do you mean with "hard to look through"? Would you change anything? The idea is to make it "universal" so that anyone could use it for his/her app.
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 9th, 2002, 09:57 PM
#5
The picture isn't missing
Remember, if someone's post was not helpful, you can always rate their post negatively  .
-
Jul 10th, 2002, 05:51 PM
#6
Thread Starter
Need-a-life Member
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 10th, 2002, 10:45 PM
#7
PowerPoster
So you're saying that I can create my app in English and then start up your app and convert it to Spanish, for example?
-
Jul 11th, 2002, 12:17 PM
#8
Thread Starter
Need-a-life Member
Yes... but you have to bear in mind that it's an INI what you're creating. So, you have to translate each caption as it says in the INI file. This app would be to create the INI file easily, with a graphical interface an some "tips" that the INI itself won't show (such as the tooltip for each key or the version where it was released)
In other words... you'll be able to translate but you will have to load the caption of all your control. This is the code I'm using:
(in a module)
VB Code:
Option Explicit
Private Declare Function GetPrivateProfileString Lib "kernel32" Alias _
"GetPrivateProfileStringA" (ByVal lpApplicationname As String, _
ByVal lpKeyName As String, ByVal lpDefault As String, _
ByVal lpReturnedString As String, ByVal nSize As Long, _
ByVal lpFileName As String) As Long
Public IniFile As String
Public Function GetCaption(AppName As String, KeyName As String, _
Default As String)
GetCaption = GetIniStr(AppName, KeyName, Default)
GetCaption = Trim(GetCaption)
End Function
Private Function GetIniStr(lpAppName As String, lpKeyName As String, _
lpDefault As String)
Dim ret As Long
Dim Temp As String * 200
Dim lpFileName As String
lpFileName = IniFile
ret = GetPrivateProfileString(lpAppName, lpKeyName, lpDefault, Temp, _
Len(Temp), lpFileName)
If ret <> 0 Then
GetIniStr = Trim0(Temp)
End If
End Function
Private Function Trim0(Word As String)
Dim i As Integer
For i = Len(Word) To 1 Step -1
If Asc(Mid$(Word, i, 1)) <> 0 Then Exit For
Next i
Trim0 = Left$(Word, i)
End Function
Usage
VB Code:
cmdOK.Caption = GetCaption("Preferences", "OkButton", cmdOK.Caption)
You should also bear in mind that you need to set the IniFile variable with the file you want to get info from.
One thing that should be more flexible is the extension of the file (since MOF might not be the extension you'd like for your program). Also, correct the error that (I guess) it would be raised if a commented line was between the keys (not at the top of the INI file)
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 11th, 2002, 12:30 PM
#9
Thread Starter
Need-a-life Member
After re-reading your question... I guess the answer is "No". Or at least... no, not that easily (the answer is in the previous post)
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 12th, 2002, 01:00 PM
#10
Thread Starter
Need-a-life Member
Any other comment? Do you think anyone would be interested?
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 12th, 2002, 01:48 PM
#11
Frenzied Member
still dunno what the feck its supposed to do
but im using xp and cant see what the status bar in the lower right corner says... also if u take the lower right corner and resize the window by going all the way to the top left, the prog promtly freezes
-
Jul 12th, 2002, 06:12 PM
#12
Thread Starter
Need-a-life Member
It's an interface to let you translate your INI files into other languages.
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 12th, 2002, 06:18 PM
#13
PowerPoster
Well
I'd be interested in it. Can your program analyze and determine the controls withing the program? (Can't tell much form the screenshot)
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Jul 12th, 2002, 09:55 PM
#14
I wonder how many charact
Pearl Jam:
'he can't see, so he chases them away...'
You see McBain, you have by blind luck stumbled onto something probably far more useful than a MP3 Organizer..
-
Jul 13th, 2002, 08:08 AM
#15
I wonder how many charact
If you open up any form such as below in Wordpad or Notepad, if you edit caption property and save it, the caption has permenantly changed, and will show that when you open the project through Visual Basic.
Therefore, it is possible to write a scanner to change captions, whether they are button captions, labels, etc, on all your forms to a different language..
VB Code:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Begin VB.Form Form1
Begin VB.Label NOfficeLabel
BackColor = &H80000004&
[b]Caption = "Next Office Visit"[/b]
BeginProperty Font
Name = "Times New Roman"
Size = 14.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Left = 1320
TabIndex = 20
Top = 1680
Width = 1935
End
Last edited by nemaroller; Jul 13th, 2002 at 08:18 AM.
-
Jul 13th, 2002, 11:42 AM
#16
Fanatic Member
I think this is a cool idea, although i would have no use for it
as far as i can tell it does this..
you store all of your controls captions names into a INI file, then when your program starts up, you check the ini file and set the captions on your controls to what they are in that ini file
and that program above allows you to change the language of the text that is stored in the INI file.
So next time your program starts up, it reads in the captions and will be a differnt language
am i right?
if so i like the idea but as i said above, i have no use for one
-
Jul 13th, 2002, 11:54 AM
#17
Thread Starter
Need-a-life Member
Originally posted by nemaroller
VB Code:
VERSION 5.00
Object = "{5E9E78A0-531B-11CF-91F6-C2863C385E30}#1.0#0"; "MSFLXGRD.OCX"
Begin VB.Form Form1
Begin VB.Label NOfficeLabel
BackColor = &H80000004&
[b]Caption = "Next Office Visit"<b>If you open up any form such as below in Wordpad or Notepad, if you edit caption property and save it, the caption has permenantly changed, and will show that when you open the project through Visual Basic.
Therefore, it is possible to write a scanner to change captions, whether they are button captions, labels, etc, on all your forms to a different language..
</b>
BeginProperty Font
Name = "Times New Roman"
Size = 14.25
Charset = 0
Weight = 400
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 255
Left = 1320
TabIndex = 20
Top = 1680
Width = 1935
End
[/B]
Yes, but you have to re-compile and provide one EXE for each language you might upload (or distribute in any way). What I'm doing is getting the captions from an INI file so that you don't have to translate them by hand, and you can use one single EXE and dozens, or hundreds of translation files (which are merely text files which are very small)
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 13th, 2002, 12:02 PM
#18
Thread Starter
Need-a-life Member
Originally posted by Geespot
I think this is a cool idea, although i would have no use for it
as far as i can tell it does this..
you store all of your controls captions names into a INI file, then when your program starts up, you check the ini file and set the captions on your controls to what they are in that ini file
and that program above allows you to change the language of the text that is stored in the INI file.
So next time your program starts up, it reads in the captions and will be a differnt language
am i right?
if so i like the idea but as i said above, i have no use for one
You're almost right. It doesn't use the control's name. You can use the key you'd like, I mean, your control can be named Command1, and the INI's key could be cmdOk, anyway.
I don't use controls key for one reason.... you may don't want to translate a control... what about a MsgBox, or an InputBox?... what about the tooltips for the controls?... what about the text that you may ocassionally show in the status bar?
I guess you got the idea. You can name the keys in the INI as their controls, but you will still have to code the read-the-text-from-the-INI for each control's caption, tooltip, msgbox.... whatever.
Am I clear?
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 13th, 2002, 12:42 PM
#19
Thread Starter
Need-a-life Member
Originally posted by dis1411
also if u take the lower right corner and resize the window by going all the way to the top left, the prog promtly freezes
Not anymore...
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 14th, 2002, 03:10 PM
#20
PowerPoster
Re: Re: Well
Originally posted by Mc Brain
No it can't. Anyway.... why would you like to do that? You have to code your forms so that the captions are changed, they won't change by magic. In that case, why would you want to get it scanned??
I just thought it would be anneat idea to scan, provide a list of controls (buttons), and allow you to change the captions...
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Jul 14th, 2002, 03:25 PM
#21
PowerPoster
Re: Re: Re: Well
Originally posted by James Stanich
I just thought it would be anneat idea to scan, provide a list of controls (buttons), and allow you to change the captions...
You mean scan through an exe file? If yes, then it'll probably only work for standard Windows controls or common controls because if you create a control and draw the text yourself, you won't be able to change the language from English to something else.
...or maybe I am thinking completely different stuff...
-
Jul 14th, 2002, 03:35 PM
#22
PowerPoster
Re: Re: Re: Re: Well
Originally posted by abdul
You mean scan through an exe file? If yes, then it'll probably only work for standard Windows controls or common controls because if you create a control and draw the text yourself, you won't be able to change the language from English to something else.
...or maybe I am thinking completely different stuff...
What I meant was to build a list of buttons in the project (not exe).
Then form this list, create sections (LANGUAGES) in the INI file.
With a sinple Flag in the INI file, you could make the program read any text on the button captions (at least, that is what I was thinking)...
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Jul 14th, 2002, 06:01 PM
#23
PowerPoster
I believe he is trying to make a GUI to create the INI files to translate all the words into other words. I just used his code and made this (attached)
-
Jul 15th, 2002, 11:52 AM
#24
Thread Starter
Need-a-life Member
Pretty much... that's the idea. However, since there are so many key on a text file I'm creating a new file for each language with its key and its translation. The UI shows you the key to translate, a brief explanation what (or where or when) is that key shown and the version when it was released (this is useful so that if you have a language file which version is 1.6.5 you know you only have to translate the versions 1.6.6 on to update the language file to the last one.
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 15th, 2002, 11:58 AM
#25
PowerPoster
Well
Suggestion :
Add additional keys for the tooltips...
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Jul 15th, 2002, 11:58 AM
#26
Thread Starter
Need-a-life Member
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
-
Jul 15th, 2002, 12:00 PM
#27
Hyperactive Member
what languages does it do?
-
Jul 15th, 2002, 12:00 PM
#28
PowerPoster
Well
Tooltips of the buttons...
Explanation of what each button does....
Question though, isn't this waht a resource file is meant for?
Remaining quiet down here !!!
BRAD HAS GIVEN ME THE ULTIMATIVE. I have chosen to stay....
-
Jul 15th, 2002, 12:09 PM
#29
Thread Starter
Need-a-life Member
Re: Well
Ain't you following me at all? 
Originally posted by James Stanich
Tooltips of the buttons...
Explanation of what each button does....
Originally posted by Mc Brain
I don't use controls key for one reason.... you may don't want to translate a control... what about a MsgBox, or an InputBox?... what about the tooltips for the controls?... what about the text that you may ocassionally show in the status bar?
I meant that you have to code any translation.... to translate Msgboxes, Tooltips, inputboxes, any kind of message... So, you a need one key for each "message" you want to get translated.
Originally posted by James Stanich
Question though, isn't this waht a resource file is meant for?
As far as I know, you can create multiple EXEs just by changing the resource file (to another language). I don't want to create multiple EXEs. You downloaded the English version and now wanted to have in portuguese... translated yourself, or get someone to translate a TXT file (with any editor) and you're done!! The only goal for this UI is to help the translator (user) when translating each key.
Last edited by Mc Brain; Jul 15th, 2002 at 12:13 PM.
Emiliano F. Martín
If a post has helped you then please Rate it! (and give the user points he/she deserves by clicking on the image).
Encourage the person who helped you to keep doing it, and give him the points he deserves.
MP3 Organizer: Freeware to logically organize all your MP3s.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|