textbox

Expandable WinForms TextBox

I have created a textbox in a Windows Forms application that starts out at a height for entering text in a single line. But I would like the textbox to automatically increase its height if the user enters text that is wrapped within the control. Currently, for this textbox, I have the properties multiline and wordwrap set to true. I'v...

Resizing a WinForms textbox control based on MaxLength

I've got a situation (a key-based search) where I'm going to have multiple inputs of varying, but constrained, length. So I'm building a common control to use for each input, and this control has a TextBox for use when the input type is free-form text. In that case I'd like the length of the TextBox to reflect the constraint placed on th...

How to let AutoComplete in .NET Winforms 2.0 TextBox suggest even if the user input is contained in middle of of the suggestion items.

How to let AutoComplete in .NET Winforms 2.0 TextBox suggest even if the user input is contained in middle of the suggestion items? ...

CSS question - transparent underlined textbox - howto?

Good Morning, Quick CSS question. Does anyone know any quick css to make an underlined transparent textbox? I basically want the textbox to be invisible except for the bottom border. I need it to function normally. Do I just remove left, right, and top borders and set it's background to transparent or something? Any examples of how to p...

WPF user control with a property of type Enum

I have a usercontrol called "InputSensitiveTextBox" that inherits from Textbox. It has a property I define called "CurrentInputType", which is of type "MyControlsNamespace.SupportedInputTypes" (with values Keyboard, Mouse, Touchpad, VirtualKey). I need to have this property be set in Xaml just like I might set "HorizontalAlignment" or ...

Using Dojo passing value from textbox to alert on click

Using the Dojo Toolkit I am trying to pass the value from textbox to an alert on click. I tried attr to obtain value inside the function helloPressed(), but I am not even able to reset the textbox value when I tried the other way. I am new to the programming world. function helloPressed() { var gt = dojo.attr("htext1","value"); ...

WinForms Cursor disappears in (some) textboxes!?

Helly guys! Currently i have the following problem: on a WinForms-Mask there are some textboxes. For some of the textboxes i use the Event "TextChanged" to check if the textbox-content reaches its "MaxLength" AND the cursor is at the end of the textbox. It's one handler for all the "TextChanged" textboxes. The problem: as soon as i cli...

How can I create a finger scrollable Textbox in WM 6.5?

Hi everybody. I just noticed something weird in WM 6.5 emulators. Unlike 6.1 where finger panning kind of worked, the only way to scroll a Textbox appears to be through scrollbars. This behaviour is in contrast to what they have done for comboboxes: they are now gesture-friendly without the programmer's intervention. I.e. the user can ...

Custom validation of dijit textboxes

Hello everybody, I was today seeking the net for information about textbox-validation, but even on Dojo-Homepage I couldn't get any useful information. My problem: I've got a NumberSpinner, in which only numbers in steps of ten (10, 20, 30, ...) should be allowed. But I've got no idea how to set a validator for this. In the 'constraint...

Scroll to bottom of C# TextBox

I have a TextBox on a C# Forms Application. I populate the TextBox with information on the Load event of the form. I then call the following: this.txtLogEntries.SelectionStart = txtLogEntries.Text.Length; this.txtLogEntries.ScrollToCaret(); However the TextBox does not scroll to the bottom ? This only applies to the Load event though...

Is there an easy way to make a code TextBox?

Is there an easy way to make a code TextBox? I'm trying to make my own limited/specialized version of XAMLPad. Displaying the current XAML object tree in the top display is simple enough, using XamlReader.Parse() ... But I'd like the actual XAML code in the bottom window to show up in its appropriate colors. Here is an example o...

Default textbox border-style and width.

IE7 and FFox seem to render textboxes very slightly differently by default. This seems to be fixed by setting their border-style and border-width css properties. The odd thing is, it seems that out of all the options vstudios intellisense gives me, none of them match? The closest I've found is border-width:1px; border-style:inset; ...

ASP.NET MVC - Html.TextBox - Value not set via ViewData dictionary

I have a search box on a page (actually in a partial view though not sure that is relevant) with an Html.TextBox control. <%= Html.TextBox("query", ViewData["query"], new { style = "width: 90%;" })%> The action method takes "query" as a parameter, and I edit this value to clean up the string that is passed in: public ActionResult S...

I want different colours in my C# webform textbox!

I want to format lines of text differently in a .net C# webforms text box, eg. some lines italic or different colour? I know I can in windows forms, is there a richtextbox alternative for webforms? I find a lot of people asking but no answer...please can you help? ...

Non-editable text box in wxPython

How to create a non-editable text box with no cursor in wxPython to dump text in? ...

Changing the color of a text box depending on its content

I have in a VS2005 C++ Form application a table adapter and a Text box that displays data from a specific column. What I want to do is to have its color changed on whether the content is >0 or <0. I tried adding this: if(this->CSumTextBox->TabIndex<0) { this->CSumTextBox->ForeColor = System::Drawing::Color::Red; } But it doesn't ...

Textbox validation

I am working on windows form based application. I want to validate textbox values. User enter only Numeric values in the textbox , now i am able to validate keypressevent, but i want validate copied value should be numeric then only paste(Mouse right click paste or Ctrl+v) textbox. ...

How to bind TextBoxes to individual elements in a Collection

I have a class with an ObservableCollection called List and I am trying to bind to textboxes individually. I have been trying: <TextBox Text="{Binding Source=List[0], Path=Value}" /> <TextBox Text="{Binding Source=List[1], Path=Value}"/> The StringObject class is just: class StringObject { public string Value { get; set; } } Ca...

Reporting Services: Using Multiple Datasets in one Textbox

RS2005 doesn't like this syntax. What's wrong with it? How do reference multiple tables in one textbox? =sum(Fields!onHand.Value, "Table1") / sum(Fields!QTY.Value,"Table1") ...

How do I get a TextBox to only accept numeric input in WPF?

I'm looking to accept digits and the decimal point, but no sign. I've looked at samples using the NumericUpDown control for WinForms, and this sample of a NumericUpDown custom control from Microsoft. But so far it seems like NumericUpDown (supported by WPF or not) is not going to provide the functionality that I want. The way my app i...