[RESOLVED] how to twist alpha from eng 2 any
hi guys
how to twist a alpha from eng like ex 2 any alpha lang
Code:
Private Sub Command1_Click()
Dim i As Integer
If i = a Then i = z
Select Case i
Case a: Text1.Text = Text2.Text & " ش "
Case b: Text1.Text = Text2.Text & " لا"
Case c: Text1.Text = Text2.Text & " ؤ "
Case d: Text1.Text = Text2.Text & " ي "
Case e: Text1.Text = Text2.Text & " ث "
Case f: Text1.Text = Text2.Text & " ب "
Case g: Text1.Text = Text2.Text & " ل "
Case h: Text1.Text = Text2.Text & " ا "
Case i: Text1.Text = Text2.Text & " ه "
Case j: Text1.Text = Text2.Text & " ت "
Case k: Text1.Text = Text2.Text & " ن "
Case l: Text1.Text = Text2.Text & " م "
End Select
End Sub
and i hope some one heeelp me
Re: how to twist alpha from eng 2 any
Could you try and explain a bit more what you are trying to do please.
Is this correct: If i = a Then i = z
Did you mean "a" and "z" maybe, or is a a long type variable you declared somewhere?
Also, you don't set the value of i anywhere, Select Case will always go to the 0 value as that is what i will hold every time.
Re: how to twist alpha from eng 2 any
thnx for ur post
in this line
Code:
If i = a Then i = z
i want to apha from a - z
ok
and i want to like replace some alpha with another alpha
like if i wrote Like Ex :
Code:
if text1 = "Hi how r U" then
text2 = "H1 H0W r U"
end if
maybe is a German alpha or France alpha
ok i hope u got it
Re: how to twist alpha from eng 2 any
For example:
Text2.Text = Replace(Text1.Text, "i" , "1")
and so on.
Re: how to twist alpha from eng 2 any
but its just duplicate from text1 2 text2
i want to replace some word from text1 and view the word
like i sad
Code:
if text1 = "Hi how r U" then
text2 = "H1 H0W r U"
end if
Re: how to twist alpha from eng 2 any
Deadly
Do you mean you want to loop thru the characters
in a text string and replace them depending on the case?
Something like this maybe? It will
- "read" each character in Text1.Text
- create a new string Text2.Text with the replaced characters
Code:
Private Sub Command1_Click()
Dim ii As Integer
Dim nn As Integer
Dim txt as String
nn = Len(Text1.Text)
Text2.Text = Empty ' initialize new string as Empty
For ii = 1 to nn
txt = Mid(Text1.Text, ii, 1) ' reads 1 character at a time from Text1.Text
Select Case txt ' build new string Text2.Text
Case "a": Text2.Text = Text2.Text & " ش "
Case "b": Text2.Text = Text2.Text & " لا"
Case "c": Text2.Text = Text2.Text & " ؤ "
Case "d": Text2.Text = Text2.Text & " ي "
Case "e": Text2.Text = Text2.Text & " ث "
Case "f": Text2.Text = Text2.Text & " ب "
Case "g": Text2.Text = Text2.Text & " ل "
Case "h": Text2.Text = Text2.Text & " ا "
Case "i": Text2.Text = Text2.Text & " ه "
Case "j": Text2.Text = Text2.Text & " ت "
Case "k": Text2.Text = Text2.Text & " ن "
Case "l": Text2.Text = Text2.Text & " م "
End Select
Next ii
End Sub
Spoo
Re: how to twist alpha from eng 2 any
Spoo Ur Fantastic
Thnx For Ur Help
Re: [RESOLVED] how to twist alpha from eng 2 any
Deadly
Glad it worked out :)
Spoo