Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. combo box and richtext help

combo box and richtext help

Scheduled Pinned Locked Moved C#
questioncsharphelptutorial
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    r_jaz
    wrote on last edited by
    #1

    Hi, I have a couple of questions in c# desctop Applics, 1)how can i respond to hitting the enter key on a combobox, to take the value entered from the user as if it's a text box? 2)how to allign the text in a rich text box to be centered?? ur help is appreciated, Thanks

    M K 2 Replies Last reply
    0
    • R r_jaz

      Hi, I have a couple of questions in c# desctop Applics, 1)how can i respond to hitting the enter key on a combobox, to take the value entered from the user as if it's a text box? 2)how to allign the text in a rich text box to be centered?? ur help is appreciated, Thanks

      M Offline
      M Offline
      MoustafaS
      wrote on last edited by
      #2

      r_jaz wrote:

      how can i respond to hitting the enter key on a combobox, to take the value entered from the user as if it's a text box?

      Override the OnKeyPress event.


      About : Islam
      About : Me

      1 Reply Last reply
      0
      • R r_jaz

        Hi, I have a couple of questions in c# desctop Applics, 1)how can i respond to hitting the enter key on a combobox, to take the value entered from the user as if it's a text box? 2)how to allign the text in a rich text box to be centered?? ur help is appreciated, Thanks

        K Offline
        K Offline
        Keshav V Kamat 0
        wrote on last edited by
        #3

        Check the OnkeyPress event for the first question. regarding the second one, right click the RTB. There is a property called TextAlign. Choose accordingly.

        Keshav Kamat :) India

        R 1 Reply Last reply
        0
        • K Keshav V Kamat 0

          Check the OnkeyPress event for the first question. regarding the second one, right click the RTB. There is a property called TextAlign. Choose accordingly.

          Keshav Kamat :) India

          R Offline
          R Offline
          r_jaz
          wrote on last edited by
          #4

          Hi, Thanks all for reply, there's no TextAlign property for richtextboxes its for textboxes only, i used the property of SelectionAligment by SelectAll() and then DeSelectAll() to centralize it but i wanted to see if there's a direct proprty such as TextAlign to do the job.. Thanks

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups