Different Languages on different textbos

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • =?Utf-8?B?R2lkaQ==?=

    #1

    Different Languages on different textbos

    Hi,

    I have a windows form with few TextBoxs,
    In textbox1 i want always to write in English with Capital Letters, and in
    all other textBoxs i want to write in the default language of the OS.

    I tried to turn on\off the CapsLock with Enter and LostFocus event, but the
    when i'm turning off the capsLock by clicking another button, the LostFocus
    event is called but the click event doesn't (only on the next click).

    So, what will be the best way to do it?

    Thanks,
    Gidi.


  • =?Utf-8?B?TWFuaXNoIEJhZm5h?=

    #2
    RE: Different Languages on different textbos

    Hi,
    If you want to write content of particular textbox in capital letters then
    in Design Mode you just need to set its CharacterCasing property to Upper.
    --
    Hope this helps.
    Thanks and Regards.
    Manish Bafna.
    MCP and MCTS.



    "Gidi" wrote:
    Hi,
    >
    I have a windows form with few TextBoxs,
    In textbox1 i want always to write in English with Capital Letters, and in
    all other textBoxs i want to write in the default language of the OS.
    >
    I tried to turn on\off the CapsLock with Enter and LostFocus event, but the
    when i'm turning off the capsLock by clicking another button, the LostFocus
    event is called but the click event doesn't (only on the next click).
    >
    So, what will be the best way to do it?
    >
    Thanks,
    Gidi.
    >
    >

    Comment

    • =?Utf-8?B?R2lkaQ==?=

      #3
      RE: Different Languages on different textbos

      Hi,

      Thanks for the answers, but i'm sorry to tell you the UPPER works only if my
      default language is English, but i'm talking about different situation, which
      my default languge is hebrew and i've one textbox which i want to write only
      in English Capital letters.

      Thanks,
      Gidi.

      "Manish Bafna" wrote:
      Hi,
      If you want to write content of particular textbox in capital letters then
      in Design Mode you just need to set its CharacterCasing property to Upper.
      --
      Hope this helps.
      Thanks and Regards.
      Manish Bafna.
      MCP and MCTS.
      >
      >
      >
      "Gidi" wrote:
      >
      Hi,

      I have a windows form with few TextBoxs,
      In textbox1 i want always to write in English with Capital Letters, and in
      all other textBoxs i want to write in the default language of the OS.

      I tried to turn on\off the CapsLock with Enter and LostFocus event, but the
      when i'm turning off the capsLock by clicking another button, the LostFocus
      event is called but the click event doesn't (only on the next click).

      So, what will be the best way to do it?

      Thanks,
      Gidi.

      Comment

      • Morten Wennevik [C# MVP]

        #4
        Re: Different Languages on different textbos

        On Sun, 29 Jul 2007 14:38:05 +0200, Gidi <shnapsi@hotmai l.com.dontspamw rote:
        Hi,
        >
        Thanks for the answers, but i'm sorry to tell you the UPPER works only if my
        default language is English, but i'm talking about different situation, which
        my default languge is hebrew and i've one textbox which i want to write only
        in English Capital letters.
        >
        Thanks,
        Gidi.
        >
        "Manish Bafna" wrote:
        >
        >Hi,
        >If you want to write content of particular textbox in capital letters then
        >in Design Mode you just need to set its CharacterCasing property to Upper.
        >--
        >Hope this helps.
        >Thanks and Regards.
        >Manish Bafna.
        >MCP and MCTS.
        >>
        >>
        >>
        >"Gidi" wrote:
        >>
        Hi,
        >
        I have a windows form with few TextBoxs,
        In textbox1 i want always to write in English with Capital Letters, and in
        all other textBoxs i want to write in the default language of the OS.
        >
        I tried to turn on\off the CapsLock with Enter and LostFocus event, but the
        when i'm turning off the capsLock by clicking another button, the LostFocus
        event is called but the click event doesn't (only on the next click).
        >
        So, what will be the best way to do it?
        >
        Thanks,
        Gidi.
        >
        >
        >
        You could handle the KeyPress event on that TextBox and cancel the user input, replacing it with the English character (asuming Hebrew characters can translate to English ones), or trap the KeyDown event to get the keyboard key pressed to determine which English character should be entered.

        --
        Happy coding!
        Morten Wennevik [C# MVP]

        Comment

        Working...