I looking for a way to add what would look like a drop down box when the user reaches the end of the visible space of a textbox. the drop down would then show what they have already typed pulse what there still typing tell they hit enter. Any ideas? The bigger pitcher is to add whatever method we come up with to a GridViewTextbox where space is limited in a row however the data they enter can be much longer then the box. The idea is to keep user from getting lost in what there typing and can provide easy review and edit. something like this but pops up when you enters then gos back on leave but just be for text as 'enter' will move the user to the next control aka enter as tab
It won't let me post the image I was talking about so use this like as a refrence .NET 2010 custom control, multiline String property to be edited in the designer
In the ASP.NET there is control which suits the need.I hope it helps
It is
<asp:AutoCompleteExtender
runat="server"
BehaviorID="AutoCompleteEx"
ID="autoComplete1"
TargetControlID="targetID"
ServicePath="Give the Path of the web service"
ServiceMethod="Name of the ID "
MinimumPrefixLength="1"
CompletionInterval="500"
EnableCaching="true"
CompletionSetCount="10"
DelimiterCharacters=";, :"
ShowOnlyCurrentWordInCompletionListItem="true"
/>
You could also use a ToolTip control to show a popup message to the user. I've read your question three times now and I'm still not sure entirely what it is you're asking.
Related
Having a bit of a problem doing this and not sure of it can be done. I have an edit control that a user types into, I would like for the input to be all in capital letters. I tried having a custom action on the edit control to get the property, convert to capital letters and set the property again each time a letter is set but it does not work. I guessed it wouldn't but no harm in trying..:)
Has anyone else solved this? I would like to do it without having a button to press if possible. The dialog in question is a twin dialog if that helps at all.
Thanks for your help
It's not possible using the native built-in Windows Installer UI. The underlying MaskedEdit Control is primitive. There are no events to tie into to validate and modify as the characters are entered. You can only ToUpper() the property when the user clicks Back or Next.
The alternative would be to go with an external UI handler which is a lot of learning and work.
How do I create a Control to input email addresses, similar to how capturing tags on stackoverflow works?
I am using C# and Xaml.
You will need:
TextBox(to show input area where you can type)
Popup(to show suggestions below TextBox like StackOveflow does)
ItemsControl(it goes into Popup, so you can just have collection of items and they will be displayed, note that ItemsPanel should be probably GridView)
Then you will need custom Button, that will be overlaid top of TextBox once tag has been added. You need to calculate how big is the button(width) and fill TextBox with empty spaces, to advance cursor further.
Also you need to control what keys are being pressed.
The effect you are after is probably that you recognize complete e-mail addresses, and render them in a custom way. I would do this by removing the completed addresses from the textbox, and wrap them in a skinned label (or maybe a custom control with a delete button).
The most straightforward way is to implement the textbox as a DockPanel with a border, suggesting that it is a text box. On the left side of your DockPanel, you have a StackPanel where you stack the completed address controls left-to-right. Then add a textbox with DockStyle=Fill to fill up the remainder of the DockPanel. Once you detect an email address is entered, you remove the characters from the textbox and add a matching control to the StackPanel.
There is probably a way to change the textbox contents without losing focus, otherwise you need to fix this though code.
Good luck!
Hi I have a VBA application with a combobox selection option.One of the combobox option is Other which when user select that option an invisibled label will pops up and prompt the user to fill the txtOther control.now my question is how I can get rid of the prompted label and make it to invisible after user fill the txtOther and move(focused)in other control?
here is a shot of my app:
Thanks for your time and help
It depends on how often or when you want the check to be done. I couldn't find a good reference to show you all of this, but you can view your VBE.
Within the code behind your userform you can use events for the text box.
If you want the check done every time you leave the text box:
Use the TextBox_Exit event.
If you want it to fire whenever the contents are changed, used TextBox_Change. There's lots of options, but based on your explanation I'd probably use Exit.
This answer shows some syntax examples for using the Textbox_Exit event.
I'm running with an 8.5.3 UP1 server and I have a need to have many dialog boxes (for confirmation purposes) for a whole bunch of "action buttons" on an xpage. The code for these dialog boxes is almost exactly the same with the exception of the confirmation message being different and the client-side JS function they are calling if the Yes button is selected.
Since I really hate repeating code over and over, I was wondering if it is at all possible to put a xe:dialog control within a repeat control and specify the message and function call from an array of values? I know I can't compute the ID of the dialog control and without that I'm not sure how I would reference the dialog to open and close it.
Any ideas? Thanks
Yes, this is possible.
Make sure that you specify that the dialog box's property for keepComponents is set to False. You don;t have to do anything special for opening or closing the dialog box, just use whatever ID you give the dialog box in you client-side action to open the dialog box in the repeat such as XSP.openDialog('#{id:myDialog}')
The XPages renderer will automatically calculate the correct ID names for you.
I have an MDI application. When I show a message box using MessageBox.Show(), the entire application disappears behind all of my open windows when I dismiss the message box.
The code is not doing anything special. In fact, here is the line that invokes the message box from within an MDI Child form:
MessageBox.Show(String.Format("{0} saved successfully.", Me.BusinessUnitTypeName), "Save Successful", MessageBoxButtons.OK, MessageBoxIcon.Information, MessageBoxDefaultButton.Button1, MessageBoxOptions.DefaultDesktopOnly)
Me.BusinessUnitTypeName() is a read only property getter that returns a string, depending upon the value of a member variable. There are no side effects in this property.
Any ideas?
Remove the last parameter, MessageBoxOptions.DefaultDesktopOnly.
From MSDN:
DefaultDesktopOnly will cause the
application that raised the MessageBox
to lose focus. The MessageBox that is
displayed will not use visual styles.
For more information, see Rendering
Controls with Visual Styles.
The last parameter allows communication of a background Windows Service with the active desktop through means of csrss.exe! See Bart de Smet's blog post for details.
Remove the MessageBoxOptions.DefaultDesktopOnly parameter and it will work correctly.
DefaultDesktopOnly specifies that "The message box is displayed on the active desktop" which causes the focus loss.
These answers are correct, but I wanted to add another point. I came across this question while working with someone else's code. A simple message box was causing the front most window to move to the back:
MessageBox.Show("Hello").
Turns out, there was a BindingSource.Endedit command before the MessageBox. The BindingSource wasn't connected to any controls yet, but it caused the window to change z-positions.
I am only including this note since my search brought me to this question and I thought it might be helpful to someone else.