Click here to Skip to main content
15,887,822 members
Everything / Controls

Controls

controls

Great Reads

by Graeme_Grant
A Modern Toggle Switch - From mock concept to a full custom WPF control that you can plug into your own apps
by Ajcek84
Open source library for music engraving in desktop, mobile and web applications
by Leif Simon Goodwin
This article presents a simple WPF Carousel Control
by Member 4206974
FormGen, a JavaScript Form Generator

Latest Articles

by Member 4206974
FormGen, a JavaScript Form Generator
by Graham Wilson
A progress bar which displays progress as passage through a simple maze.
by Graham Wilson
A collection of simple .NET Framework/.NET WinForm controls and utilities.
by Graham Wilson
A track bar control which displays the track line as a spiral

All Articles

Sort by Updated

Controls 

2 Apr 2024 by kmoorevs
Tables/nested tables are the way to handle layout.
2 Apr 2024 by Dave Kreskowiak
You really don't want to use the designer to layout web pages. That's going to generate a ton of inflexible HTML that you're going to have to rip out and redo for a really flexible page layout when screen sizes change. You typically just write...
2 Apr 2024 by Jo_vb.net
Check if Tools > Options > Web Forms Designer "Legacy Web Forms Designer" is selected.
2 Apr 2024 by Rama2F
I'm trying to move the controls (label, textbox, etc..) freely on the [Design] screen of an [ASP.NET Web Forms Site] template, using VS 2022. What I have tried: I know that to achieve it, I should ... select the control I want to move around...
15 Jan 2024 by Member 4206974
FormGen, a JavaScript Form Generator
17 May 2023 by Olivier Levrey
[Description("Very basic slider control with selection range.")] public partial class SelectionRangeSlider : UserControl { /// /// Minimum value of the slider. /// [Description("Minimum value of the...
25 Apr 2023 by Richard MacCutchan
See ComboBox.AutoCompleteMode Property (System.Windows.Forms) | Microsoft Learn[^]. My apologies, try CB_FINDSTRING message (Winuser.h) - Win32 apps | Microsoft Learn[^]
25 Apr 2023 by Avtem
So, many WinAPI controls have a very useful feature - you can select an item in Listbox, ListView, Combobox by typing first several letters. You can try it out: just open your windows calculator, hit Ctrl+U to enable converting units view and in...
3 Apr 2023 by Member 15758581
I am Working on a Backuptool but now i ran into a problem, all my Items in my ListBox where they were read from an OpenFolderDialog all have checkboxes. Now here is my Problem, I want to get the checked Items into another ListBox called...
3 Apr 2023 by Graeme_Grant
You are using MVVM. You can use DataBinding to track selection. 1. Wrap the Model: public class CheckItemModel : ObservableObject { private bool isChecked; public bool IsChecked { get => isChecked; set => Set(ref...
15 Mar 2023 by dtbroo
make it so the classic volume control pops up on the lower left hand side of my screen? When I click it now, it only appears locked in the upper right hand side of screen :( What I have tried: I tried looking for a way but to no avail
15 Mar 2023 by dtbroo
I'll give it a go. Thank you, OG, for not making me feel like I was from Mars asking this question (like others did)!
15 Mar 2023 by OriginalGriff
The article you reference was deleted in 2014, along with all his other material - I have no idea why, but the author's participation with the site stopped at the same time so it's likely that the two were connected. I can still access the text...
30 Dec 2022 by Graham Wilson
A progress bar which displays progress as passage through a simple maze.
30 Dec 2022 by Graham Wilson
A collection of simple .NET Framework/.NET WinForm controls and utilities.
6 Dec 2022 by Graham Wilson
A track bar control which displays the track line as a spiral
25 Oct 2022 by ♥…ЯҠ…♥
Hi All,I am using Visual studio 2010 ultimate, now I want to add AnkhSVN to visual studio for that I downloaded the same from internet and installed.Then only I noticed I cant find Source control option in Tools --> options menu.Only 4 options are listed below that1) General2)...
25 Oct 2022 by Suchitra Kuchipudi
Tools->Options->Web Forms designer->enable legacy webforms designer and Source view ->OK ->Restart the system It will display the Source button in bottom of editor
18 Oct 2022 by lelouch_vi 2
I'm just wondering while I'm looking at my project it has 6 forms and a bunch of labels and textboxes. Can I change the font style or font sizes of the controls all at once without having to edit them one by one in the designer? What I have...
2 Sep 2022 by Peter Huber SG
Concurrent threads can use LogViewer to show the user scrollable information efficiently
15 Jun 2022 by termine1
in my productservice.ts I got : getProductById(id: number){ return this.http.get(`${this.baseUrl}/getProductById/${id}`); } ``` in my UpdateProductComponent: ngOnInit() { this.initializeForm(); const id =...
15 Jun 2022 by Richard MacCutchan
if (id) { console.log(id); this.productService.getProductById(id).subscribe( product => this.product = product) } else { console.log('id is not defined') } this.updateForm.setValue( { 41*** productId:...
15 Jun 2022 by OriginalGriff
If you don't understand an error message, google it: typescript cannot read properties of undefined - Google Search[^] The top hit explains the problem: Resolving the TypeError: Cannot Read Property of Undefined in JavaScript[^]
28 Apr 2022 by free5lot
Camera_Net is a FLOSS library for using video-cameras and video-inputs in .NET projects easily
28 Mar 2022 by Member 15581865
cant upload images here.... Let me describe the BOX I want. Its a password text box, but on the right side (inside the box) is a rainbow/wifi looking image. You momentarily click down on it and it shows your password on the left thanks for any...
28 Mar 2022 by OriginalGriff
Quote: thought i would start with lazyness. While we are more than willing to help those that are stuck, that doesn't mean that we are here to do it all for you! We can't do all the work, you are either getting paid for this, or it's part of...
21 Mar 2022 by Peter Huber SG
WpfTestbench helps you to write sophisticated test windows for your WPF controls with few lines of code
24 Feb 2022 by Zamec 2022
Hello, I have put site into a host and I am very green with PhPmyadmin so I am asking for help. I have shopping cart in js everything works very good the cart total price etc but I couldnt find any guilde or help how to make an order. Basicly I...
24 Feb 2022 by Andre Oosthuizen
Seriously??? Question mentions e-mail, no code shown. Question mention PHPMyAdmin which is database management, nothing to do with code to interact with database. Has your city banned Google? If not, you can try THIS link for starters. Maybe...
4 Dec 2021 by Bill Joeden
Suppose, I have the following DataGrid: How do I add the following list of objects to the customershowgrid DataGrid to display all the customer instances' attributes like name, phoneno etc. What I have...
4 Dec 2021 by Gerry Schmitz
Based on your "field names" and your "property" reference (name {get;set;}) I would say you did not use the (private) "fields" as backing stores for the "properties", and you should be using "property names" in your initializer. i.e. new xxx() {...
3 Dec 2021 by #realJSOP
The bound collection property has to be public, or it won't bind. public class MainWindow: Window, INotifyPropertyChanged { // put your INotifyPropertyChanged implementation here // private...
8 Nov 2021 by Yount_0701
I want to redraw syslistview32 , I mean each pixels. The content of client zone now is working well, but the non-client zone, the scrollbar, still flicker. the flicker img What I have tried: I handled several messages, WM_NCCALCSIZE: resize the...
8 Nov 2021 by Rick York
One thing I noticed in the video is it seems to flicker when it hits the scrollbar hits the far, right-hand edge. I think that is a key point to the problem. Have you used Spy++ to monitor which messages are being sent? It might take a while...
19 Jul 2021 by shiva_yn
i tried the following. i created the progress bar. and set the visible property=false and style=marquee. when i clicked the button1 change the progress bar visibility=true and then do some lines...these lines are taking nearly about 2 mins....
19 Jul 2021 by Richard Deeming
Your code is running on the UI thread. Any updates you make to the UI will not be shown until your method returns. You should move your code to a background thread using a BackgroundWorker[^]: Public Sub button1_click() Handles button1.Click ...
18 Jul 2021 by Chris Copeland
That doesn't seem quite right, the only reasons I can think of that happening are: The logic executes really quickly The DirSize method runs on a separate thread You need to provide more information on what the DirSize method is doing....
4 Jun 2021 by Member 11728887
I've got a custom control, "ButtonControl", which contains a property of a custom class "Corners". This class has four properties of the custom class "Corner", which has a value for the angle and the radius of a corner (both type int). Whenever I...
4 Jun 2021 by OriginalGriff
If I copy'n'paste your code into a new UserControl of an existing project, then comment out the unknown stuff, change the base class to UserControl and rebuild, I get no errors: using System; using System.Collections.Generic; using...
20 May 2021 by DebugST
Have you ever imagined that your flowchart is executable?
27 Apr 2021 by RichardK151
Hi, i have a partially transparent windowless ATL control. The control is hosted in a third party container, which i can't change. When the control paints via OnDraw, the transparent part is flickering (showing a black background in the...
27 Apr 2021 by KarstenK
Dont set the background to transparent. Read this Understanding OnPaint() article to better understand the drawing system. You must return TRUE from OnEraseBkground. Best is to drawn an own background color in it. Be sure that no reload or...
12 Apr 2021 by Lazie Wouters 2021
Hi, I'm starting to learn C# in .NET Core 5, I know something about C# in the .NET Framework... But one of the different things I'm seeing in .NET Core is that in place of the MessageBox there is now the TaskDialog. Well, I created a message...
12 Apr 2021 by RannyMeier
Hello Lazie, I believe that you may want to use System.Windows ShowDialog instead of Windows Controls TaskDialog from the Win32 API. For C# .Net Core 5 the ShowDialog is normally used. system.windows.window.showdialog I suppose the...
4 Apr 2021 by Daniel Peqini
I want to find the order that the buttons are clicked and add them in an Array where they are sorted by their click order. Then i want to know the name of the last button clicked (4 buttons). What I have tried: I have tried to check when a...
4 Apr 2021 by OriginalGriff
So create a class level List of Buttons, and handle their Click events. In the handler, check if the button has been added already, and if so, remove it. Then add the button. Since a List is ordered by "last entry at the end" you just need to...
25 Mar 2021 by Aleh Baradzenka
In this article, you will learn about an adjustable control that has zooming and scrolling tabs, dragging with the mouse, custom drawing and much more.
16 Mar 2021 by Aleh Baradzenka
This control is another kind of tab. Tabs are displayed as horizontal stripes and can be collapsed into buttons. Each tab is assigned its own window, which is shown when you click on the tab.
16 Mar 2021 by Aleh Baradzenka
In this article, you will learn about a control that is necessary for the partition of the dialog, main or child window of your program by several parts.
2 Feb 2021 by Unforgiv3n
Hi people,I have a problem with the Datagrid in WPF. I'm busy writing a WPF browser application. I have a datagrid declared on my page as follows:
2 Feb 2021 by Member 15062583
Previous Link looks to be broken here is a working one
27 Jan 2021 by Richard Deeming
You need to recreate the controls on every postback. The best place to do that would be the Init event of the placeholder you're adding them to. Dynamically Adding Wired Controls to Web Forms[^] Remember, your page and the entire control...
27 Jan 2021 by Member 11760345
I have a user control MembersFoundControl.ascx that is loaded into the MembersControl.ascx when duplicate members are found. The MembersFoundControl control definition is:
27 Jan 2021 by Member 11760345
I am not sure what you mean. The initialization of a control is OnInit. This would meant that this would fire everytime the MembersContol is refreshed. And the lifecycle of the MembersFoundControl is only for the duration of selecting one of...
1 Dec 2020 by leon_saks
Hi, all! I have a problem with TextBoxes in my form. Screenshot as picture http://rghost.ru/5011999/image.png Let's show the situation on a simple example. 1) Create a new winforms project with Form1; 2) Create a new Form2, put TextBox control onto it; 3) Let's write...
1 Dec 2020 by Member 11948810
Try setting the FormBorderStyle property of the child form to 'none'
6 Nov 2020 by RickZeeland
Take a look at: GitHub - GroupDocs.Annotation for .NET examples, plugins and showcase projects[^] Although it is on GitHub, it does not seem open-source however ...
6 Nov 2020 by vetrichelvi
I want to draw text, mark up and draw lines, rectangle, arrow marks on image. My application is windows based desktop application and it depends on .NET framework 3.5. User must be able to edit the image, draw text over image at run time. There...
6 Nov 2020 by OriginalGriff
What you are trying to do is pretty complicated - there are a huge number of packages available which will let you do that, and which provide the important "layered storage" that you need to save it and then continue working later. This is...
21 Sep 2020 by auto9817
This is probably the most wanted question I think if you are using the Dot Net Chart Control. I searched on many Q&A sites but I still have not find an answer. I have about 6 to 7 chart areas alinged in one chart. I allowed the horiozontal...
22 Jul 2020 by siliconvideo
This StringBox control implements keystroke validation using regular expressions and a touch of glue logic
17 Jul 2020 by honey the codewitch
Add a flexible knob control to your .NET projects
30 May 2020 by Helin1
Each Control has properties and methods. These can be used to handle the interaction with the user. Which statements are correct? 1.Textbox: txtName = "Nisse"; 2.Listbox: lstResults.Items.Add = "New text row"; 3.1Label: lblCaption =...
30 May 2020 by OriginalGriff
We are more than willing to help those that are stuck: but that doesn't mean that we are here to do it all for you! We can't do all the work, you are either getting paid for this, or it's part of your grades and it wouldn't be at all fair for us...
30 May 2020 by phil.o
Read your course, and refer to the documentation of corresponding controls. There are lot of examples out there. You have to do it by yourself; the quiz is there to test your knowledge and understanding, not ours. Please try it; that's not really...
16 May 2020 by OriginalGriff
No, you have to either skin your form: Skinning form VB.NET[^] which will mean changes to a lot of your existing app, or use the Control.Controls Property (System.Windows.Forms) | Microsoft Docs[^] recursively to set your font height in your form...
23 Mar 2020 by Reza Ahmadi
Hello guys, I'm using Janus 3.0 controls(it is a fairly old version but the company insists to use that version) in a win-based application to create UI in the application. I see a bug in the FilterEditor control and here is the whole story ( I presume you know how it works basically): I...
4 Mar 2020 by A. J. Bozdar
Could you please tell me how second loop or the if statement breaks here? int outer; int inner; for (outer = 2; outer
8 Dec 2019 by zlristovski
I have C# who communicate with dot matrix printer on LPT1 port. I want to send control codes on the printer, but when I am sending the codes, printer is not responding, it answers only when I send FF code. I want to send this code ESC EM 82, but I don't know how to format it, FF I am sending hex...
21 Nov 2019 by Leif Simon Goodwin
This article presents a simple WPF Carousel Control
1 Nov 2019 by derek9999
I have a picturebox control in a groupbox control on a VB winform app I'm developing under VS2010. I use the designer to add a MouseClick() event as you would normally. In my code I create a bitmap thus:Dim bmSource As Bitmap = New Bitmap(nWidth,...
1 Nov 2019 by Member 2524527
Same problem, same mysterious solution in VS 2019 - add a new control and it fires events OK
8 Oct 2019 by Bilal N Gharib
This article is about automatic resizing of a frame and its controls with the same ratio in Java.
1 Sep 2019 by Ashley Davis
This article examines the use and implementation of a WPF custom control that is used to display and edit networks, graphs and flow-charts.
23 Aug 2019 by Leif Simon Goodwin
This article presents a highly configurable rotary dial control.
6 Aug 2019 by Michael Waguih
Hi all,I have a DataGridView where I am setting its AllowUserToAddRow property to true,When using keyboard for input, it works and give me a new row,but when trying to fill the row using the code like this :dataGridView1.Rows[dataGridView1.RowCount - 1].Cells["ID"].Value = "1";It...
6 Aug 2019 by Member 14190010
You cannot modify the cells in the row in the UserAddedRow event. Use DefaultValuesNeeded[^] instead.
17 Jul 2019 by Edwyn Amador
Handles and validates input typing and pressed keys in TextBox, RichTextBox and ComboBox, displaying custom balloon tips messages
14 Jul 2019 by Richard MacCutchan
Take a look at Using Windows - Windows applications | Microsoft Docs[^].
14 Jul 2019 by benjweston
I have an Win32 C++ MDI form with a toolbar at the top, a statusbar at the bottom and an edit control sitting on top of the statusbar, with the rest of the client area clear for child windows. Here's the code to create the edit control: HFONT hfDefault; HWND hEdit; TCHAR lpszSometext[] =...
13 Jul 2019 by benjweston
In a win32 mdi desktop app, how would you place an edit control in the mdi client area (just like the Output window in Visual Studio when it's docked at the bottom of the main window)? I'm doing an OpenGL graphics app and to complement using mouse input and getting coordinates from the cursor...
13 Jul 2019 by Richard MacCutchan
Why not just create it as another child (Edit) window and let the MDI window control its positioning? See How to: Create MDI Child Forms | Microsoft Docs[^] for some sample code.
15 Jun 2019 by Member 13694561
A database contains all controls and their elements We call the element AND the value of this element via the code. Result: we can build, adapt, rebuild, make custom styles etc, in a couple of lines These are the lines:: ' an sql string to define the data sql = "" : sql = "select * from...
15 Jun 2019 by #realJSOP
0) unless you’re using .Net, this will never work. 1) even if you do use .net, you’d have to make extremely heavy use of reflection. As a result, your app would absolutely suck in terms of performance. 2) if the controls you’re using ever become deprecated and disappear from your frameworks,...
26 Mar 2019 by Vincent Maverick Durano
You haven't set any bootstrap css in your ASP Menu Control. Check this article to get started: Responsive ASP.NET Menu Control With Twitter Bootstrap - TechBrij[^]
26 Mar 2019 by Member 14171287
Start Bootstrap Dashboard Shortcuts Overview ...
28 Feb 2019 by SSDiver2112
A custom Panel that creates a glow effect around a child control or a drop shadow when it receives focus
21 Jan 2019 by Gerry Schmitz
What you're referring to is (generally) a "wait cursor". The one I use in WPF is below; wrapped in a using; around the "waiting" code. Don't know if you can customize it to what you want. For a kiosk, I created my own (bigger) "wait (for it) window" (WPF storyboard with rotating sprocket and...
21 Jan 2019 by Brian C Hart
Hi, I am not sure if I am even using the name correctly, but I have google searched and google search for this over a period of uncountably many several years, and as of so far I have been unable to find a reference for what control or Windows API I call to get the progress wheel/spinner control...
19 Jan 2019 by MadMyche
It looks like you may be creating an endless loop; as your validation script calls to submit, which calls validation, which calls submit.... You should be using something like this quasi-code: function validateit() { // do validation stuff if validated { return true; } return false; }
19 Jan 2019 by TheBigBearNow
Hello all, I have a quick question that should actually be real simple but I haven’t been able to find it online through MANY searches. I have a HTML form and a submit button. In the form I have an ‘onsubmit()’ event which does validation. How do I call a submit function after I return my...
8 Jan 2019 by TheBigBearNow
Hello all, I am validation off bootstrap currently so it validates all $(“:input”) and I use a switch statement so it does case “text” case “password” and case “textarea” I want to validate a case “email” or by the #ID and have it be with the same CSS of of a textbox. Because I have floating...
15 Dec 2018 by Smurf Iv
Hello, I have made changes to allow focus and Space bar switching for these controls. What I have tried: How would you like me to return the code updates to you ? Do you have the project on Git Hub ? If not then would you mind me having this on GitHub ? (Not sure what the license would be...
15 Dec 2018 by OriginalGriff
Don't post this under Quick Answers - if you got the code from an article, then there is a "Add a Comment or Question" button at the bottom of that article, which causes an email to be sent to the author. They are then alerted that you wish to speak to them. Posting this here relies on them...
7 Nov 2018 by TheBigBearNow
Hello all, I have a question. I have a user object with properties. I have a login screen and when the user logins correctly I pass the user object to the next window. On the top of this next window I would like to display this below with the new line in the control. Should I use a text block or...
7 Nov 2018 by M.Kamran Asim
1. Choice between Label and Textblock depends on requirements. If your data is only text, go for TextBlock. As it is light weight, but if you need some content like image, grid or other complex typed, then label is fine for you. Personally for simple messages, I use textblock with some styling...
6 Nov 2018 by #realJSOP
should i be doing this with data binding because this is WPF? Yes.
22 Oct 2018 by Dave Kreskowiak
How about asking this question in the forum at the bottom of the article. That way the author gets notified you have a question about his/her code.
22 Oct 2018 by MekVala
I'm using this Move and Resize Controls on a Form at Runtime (With Mouse)[^] for move and resize control runtime. It's working fine except when cursor crosses border of control(e.g shrinking) it forcefully closes application. I can not understand where to put exception handling code. What I...
4 Oct 2018 by Frank R. Haugen
Background I'm working on personal project, (a mobile app), in which geolocation is a feature. The users log a location in a MongoDB, (if commercially viable, it'll be an Azure CosmosDB, but for now I'm testing with simulated data locally). To account for scale, I'm developing with the mind that...