Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: WPF
how to make non editable textbox in wpf.
when i debug it has to be some non editable text
Posted 29-Jun-11 23:01pm
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Add IsReadOnly = "True" in xaml of textbox.
  Permalink  
v2
Comments
Wayne Gaylard at 30-Jun-11 5:07am
   
Good answer, but I think the OP should use a Label instead. Just a case of using the right tool for the job sort of thing. +5
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Use a Label. That's what a Label is for. A textbox is for user input.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

Prerak and Wayne have answered your question very well, just to add to that :
 
1. Everything you can do with a text box in WPF[^]
2. Read only Text Box[^]
 
Hope you find this helpful.
All the best.
  Permalink  
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 Sergey Alexandrovich Kryukov 404
1 Richard MacCutchan 240
2 OriginalGriff 230
3 Jared Sanow 145
4 Vinay Mistry 143
0 Sergey Alexandrovich Kryukov 5,955
1 OriginalGriff 4,805
2 CPallini 2,473
3 Abhinav S 1,507
4 Richard MacCutchan 1,437


Advertise | Privacy | Mobile
Web02 | 2.8.140814.1 | Last Updated 30 Jun 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100