textbox

jQuery: Making corresponding text boxes affect eachother's values.

Situation: 2 text boxes, TextBoxA and TextBoxB. I enter text into TextBoxA and it sets the value of TextBoxB. Now, I need to be able to edit the value of TextBoxB, and have that set the value of TextBoxA. Simple enough, but I need this to work for several pairs of text boxes on a single page. This is what I have so far: $(function() {...

How to make an Access TextBox, with a Numberic Value, Equal to DLookup with the TextBox as the Criteria

I really have no idea why this doesn't work, but I am trying to get the following to work: If Me.Text1 = DLookup("Field1", "Test1_Table", "Test1_Table.Field1= _ & Me.Text1") Then MsgBox "It works" Else End If The above code is a test code for a larger project that I am working on, so the table and field names are just for test...

wpf textbox textwrapping

I need some help. Don't know if this is possible. I want to have the following: <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="Auto"/> <ColumnDefinition Width="*"/> </Grid.ColumnDefinitions> <TextBox TextWrapping="Wrap" MinLines ="5"/> </Grid> which is a textbox wrappin...

EndEdit equivalent in WPF

I have a WPF Window that contains a TextBox. I have implemented a Command that executes on Crtl-S that saves the contents of the window. My problem is that if the textbox is the active control, and I have newly edited text in the textbox, the latest changes in the textbox are not commited. I need to tab out of the textbox to get the chan...

vb.net textbox validation against a database?

one of the fields on my form is a textbox that the user types an id. this is the foreign key to another table so I need to bounce the data against that table before letting them submit. I'd rather not use textchanged as every letter they type may incur another query, focus lost would only show an error or validate when they are already i...

Textbox stretching issue

I have the following code <table cellpadding="2" cellspacing="2"> <tr> <td>Factory:</td> <td> <asp:TextBox ID="txtFactory" runat="server" Width="100%"></asp:TextBox> </td> </tr> </table> My problem is that sometimes the factory textbox can hold a fairly long description of 100 or more characters, and when this ha...

Windows forms: how to do a thick blinking cursor on a textbox?

I am rewriting a windows forms application (updated framework, rewrote the logic, etc.) and there is one thing that I just can't figure out how they did. Textboxes in the original application had a thick blinking cursor like so: http://screencast.com/t/8QYUcjuh3n For the life of me I can't figure how to do this. Please help? ...

How do I automatically scroll to the bottom of a multiline text box?

I have a textbox with the .Multiline property set to true. At regular intervals, I am adding new lines of text to it. I would like the textbox to automatically scroll to the bottom-most entry (the newest one) whenever a new line is added. How do I accomplish this? ...

Set the text color in a Java textbox

How does one set the color of text in a Java Swing textbox at run-time? At startup, the color is grayish and when the user enters the textbox, I wish to change the color to the normal text color. I am currently using the following code: private void txtScheduleInfoFocusGained(java.awt.event.FocusEvent evt) ...

How to Make a Text Box Equal All Letters To The Left of a Specific Letter or Character From Another Text Box in C#

I am trying to figure out a simple way of making a text box equal all letters to the left of a "-" in another text box. Basically, if an end-user types blah-test in textbox1, I would like textbox2 to equal blah. I have tried if statements and substrings based off of letter position count (i.e. substring(0, 5); however, this got very le...

How can I monitor the winforms TextBox.SelectionStart property for changes?

I have a multiline text box, and I'd like to display the user's current line number and column number in a label below the text box. It looks like I can get the line number and column number using the SelectionStart property, GetLineFromCharIndex method, and GetFirstCharIndexOfCurrentLine method. However, I can't see any event that gets ...

Append INPUT to TEXTAREA as being types in JQuery

I have an INPUT text box. As someone types into the INPUT text box, i need it to append/add-to a TEXTAREA value. Lets say user types '12345' into the text box. The textarea (default value="Comment: ") will automatically add: 'Comment: 12345'. Adding '12345' as they type. ...

WPF - ListBoxItem selection

I have a ListBox showing items using the following DataTemplate: <DataTemplate x:Key="PersonTemplate" DataType="{x:Type DAL:ResultItem}" > <StackPanel Width="280" > <TextBox BorderThickness="0" IsReadOnly="True" Background="Transparent" Text="{Binding FullName1, Mode=OneWay}"/> ... </StackPanel> </DataTemplate> I am using...

How to move insert caret on textbox when accepting a Drop

I have a TreeView and a Multiline Textbox together on the same form in a Windows form. I have drag and drop setup so that I can drag a node from the TreeView over to the textbox and insert text into the textbox (this is working). I would like to enhance this so that as the mouse is dragged over the textbox some sort of indicator moves ...

jQuery textbox and html

Hi, I am manipulating some data in ms ajax and return a string which I insert into a textbox by using jQuery.val(). Unfortunately the textbox doesn't intrepret either or \n, so how can I make it render the text inside textbox so it still looks nice? Update (by request): I use something similar to this: var sendEmailText = Hi, you foun...

How to neatly align text in a textbox and keep it when exporting to .txt

Hi, I am having a small stupid issue and I was hoping you guys could join in with your experience. I need a textbox with the following (dynamic) data: TEXT TEXT TEXT TEXT _______________________ Name: Amount: Blah 3 Blahblah 10 _______________________ But the text inside the box is the issue. S...

Custom shaped text box/edit control in .net?

I'm looking for a way to display and edit text inside a custom shaped box (e.g. a circle.) The text needs to use as much of the allowed space as possible, so just positioning an edit box inside the shape is not good enough. Requirements: 1) Given a GraphicsPath and a string, draw the text within the path. If the text overflows, truncate...

How do I make the autocomplete list for a TextBox editable?

I have an application with a lot of TextBox controls that use autocomplete. Each one uses AutoCompleteMode.CustomSource to get the autocomplete text from an associated AutoCompleteStringCollection. Whenever the user enters a new value in the TextBox, it gets added to the associated AutoCompleteStringCollection, and at the end of the se...

AutoComplete TextBox in WPF

Hi, Can we make textbox to autocomplete in WPF? I found a sample where a combox box is used and the traingle is removed by editing style template. Do we better solution for autocomplete textbox? Thanks in advance Sharath ...

How to compare text in one box to another and highlight what's wrong in red

I'm brand new at VB and I made a program that utilizes two languages. I want to check one box against another and highlight, in red, the text that doesn't match up. Does anyone know an easy way for me to do this? Thanks! ...