Code: ChangeLang.doc Public Sub ChangeLang() Dim S$, s1$ S = Selection.Text Dim i&, c$ For i = 1 To Len(S) c = Mid$(S, i, 1) Select Case c 'английские буквы в русские Code: Case "q": c = "й" Case "w": c = "ц" Case "e": c = "у" Case "r": c = "к" Case "t": c = "е" Case "y": c = "н" Case "u": c = "г" Case "i": c = "ш" Case "o": c = "щ" Case "p": c = "з" Case "[": c = "х" Case "]": c = "ъ" Case "a": c = "ф" Case "s": c = "ы" Case "d": c = "в" Case "f": c = "а" Case "g": c = "п" Case "h": c = "р" Case "j": c = "о" Case "k": c = "л" Case "l": c = "д" Case ";": c = "ж" Case "'": c = "э" Case "z": c = "я" Case "x": c = "ч" Case "c": c = "с" Case "v": c = "м" Case "b": c = "и" Case "n": c = "т" Case "m": c = "ь" Case ",": c = "б" Case ".": c = "ю" Case "Q": c = "Й" Case "W": c = "Ц" Case "E": c = "У" Case "R": c = "К" Case "T": c = "Е" Case "Y": c = "Н" Case "U": c = "Г" Case "I": c = "Ш" Case "O": c = "Щ" Case "P": c = "З" Case "{": c = "Х" Case "}": c = "Ъ" Case "A": c = "Ф" Case "S": c = "Ы" Case "D": c = "В" Case "F": c = "А" Case "G": c = "П" Case "H": c = "Р" Case "J": c = "О" Case "K": c = "Л" Case "L": c = "Д" Case ":": c = "Ж" Case """": c = "Э" Case "Z": c = "Я" Case "X": c = "Ч" Case "C": c = "С" Case "V": c = "М" Case "B": c = "И" Case "N": c = "Т" Case "M": c = "Ь" Case "<": c = "Б" Case ">": c = "Ю" 'Русские буквы в английские HTML: Case "й": c = "q" Case "ц": c = "w" Case "у": c = "e" Case "к": c = "r" Case "е": c = "t" Case "н": c = "y" Case "г": c = "u" Case "ш": c = "i" Case "щ": c = "o" Case "з": c = "p" Case "х": c = "[" Case "ъ": c = "]" Case "ф": c = "a" Case "ы": c = "s" Case "в": c = "d" Case "а": c = " Помогите, в чем моя ошибка ?
Это как будет выглядеть ? Типо: Case "ф": c = "a" Case "ы": c = "s" Case "в": c = "d" Case "а": c = " Next End Select Так ?
Блин, забыл что тут ограничено символов ((( Case "а": c = "f" Case "п": c = "g" Case "р": c = "h" Case "о": c = "j" Case "л": c = "k" Case "д": c = "l" Case "ж": c = ";" Case "э": c = "'" Case "я": c = "z" Case "ч": c = "x" Case "с": c = "c" Case "м": c = "v" Case "и": c = "b" Case "т": c = "n" Case "ь": c = "m" Case "б": c = "," Case "ю": c = "." Case "Й": c = "Q" Case "Ц": c = "W" Case "У": c = "E" Case "К": c = "R" Case "Е": c = "T" Case "Н": c = "Y" Case "Г": c = "U" Case "Ш": c = "I" Case "Щ": c = "O" Case "З": c = "P" Case "Х": c = "{" Case "Ъ": c = "}" Case "Ф": c = "A" Case "Ы": c = "S" Case "В": c = "D" Case "F": c = "F" Case "П": c = "G" Case "Р": c = "H" Case "О": c = "J" Case "Л": c = "K" Case "Д": c = "L" Case "Ж": c = ":" Case "Э": c = """" Case "Я": c = "Z" Case "Ч": c = "X" Case "С": c = "C" Case "М": c = "М" Case "И": c = "B" Case "Т": c = "N" Case "Ь": c = "M" Case "Б": c = "<" Case "Ю": c = ">" End Select s1 = s1 & c Next Selection.TypeText Text:=s1 End Sub