GetDataPresent On Custom Control?
Oct 13, 2010
I have a custom controll that is created at runtime this contol has several lables and list boxes. I want the user to move the controls from one panel to another. an not find the cirrect wat to impliment e.Data.GetDataPresent(DataFormats.???)
View 1 Replies
ADVERTISEMENT
Dec 29, 2011
how to specify a custom icon for display in the toolbox window when you create your own custom control? Something other than the dreaded "gearbox" icon.
View 2 Replies
Jul 11, 2011
I have an ASPX Custom Control which is supposed to load it's properties into an internal collection (defined with PersistenceMode.InnerProperty). Here's the ASPX
<cc:CustomControl runat="server">
<Queries>
<cc:QueryTypeOne ... />
[code]...
View 1 Replies
Jan 11, 2010
I am using custom textboxes and I need to be able to set the Text on txb1 based on the Text of txb2. I have simplied my code to the following:
Public Class customtextbox
Inherits TextBox
Public Event ControlReset()
[Code]....
So, when txb1 looses focus, if its Text is "fried", then it sets off txb2's ProcessAlert function. I had tried to change the value of txb2 Text in ProcessAlert function, but didnt work, so I tried to get it to raise an event instead, which then tries to set the Text property. However I still cant set txb2's Text property. The Text property seems to be set for the duration of the "life" of the Event handler. When I step through the forms controls within the Event handler, the changed Text value is there, but not outside of the Event handler.
View 2 Replies
Jul 29, 2009
I've created my own ascx control with button inside it. Now I'm using this control inside other control. (In my case it is a webpart). What I would like to do is program button.click logic from my custom control inside webpart
View 4 Replies
Jul 17, 2011
Can a custom control NEW Sub be the only one that executes when Inheriting from an existing control please?I am Inheriting from TabControl and I do not want the base New Sub called, is this possible?In other words, I do not want TabPage1 and TabPage2 to be added.A Form has an Activated Sub which runs once a Form is activated.It is a pity that Microsoft have not got such a method in the baseControl Class otherwise I could have used it within a custom TabControl.
Public Class Form1
Private Sub Form1_Activated(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Activated
End Sub
[code]....
View 8 Replies
Apr 29, 2010
We have a ASP.NET web application written in VB.NET where we build content programmatically during the Init event.We make extensive use of user controls, building them on the fly, and I now want to start including SilverLight content.Is there an easy way of embedding a SilverLight application in a control, and then instantiating the whole thing in code, in the same way as you'd programmatically add ordinary ASP.NET controls to a page?The SilverLight component itself works fine when added to a page using the <object> tag but I really want to be able to reuse it elsewhere in code.Since I'm expecting use of SilverLight to increase in our application, and the asp:Silverlight control seems now to be deprecated, I'm looking for an alternative way of wrapping the content.
View 1 Replies
Nov 25, 2009
What I've done is create a User Control Library (Project) and I've added a single User Control to that project. The control contains a single FlowLayoutPanel, and I created a Property on the control itself to pass the FlowDirection from the Control to its FlowLayoutPanel child.
Build, reference, component appears in the Toolbox and everything works fine, but the property on the control does not appear in the Properties window when I go to edit it at design time.
View 6 Replies
Jan 9, 2012
I want to understand N-tier architecture like when to use and so on.Also I would like to know about user control and custom control.
View 4 Replies
Sep 2, 2011
I am trying to make a listview custom control based on the standard listview control that will allow me to drag a column header outside the standard listview control and drop it on a panel. I plan to use the drop event to determine which column I should group by view on.
View 2 Replies
Jul 4, 2010
[URL]I tried dragging it but it didn't work. I'm not used to the IDE. Also, how would I make that control at runtime and place it on the form I understand you would do
PHP Code:
Dim myAccount as new TAccount
But how do I display it on the form?
View 2 Replies
Apr 2, 2010
I want to create a custom control in a dll file.
I can make this without a dll file, also inside a normal project, making a class for it and inheriting the desired base control class, compiling the project and the toolbox has the custom control.
But now I want to make it in a separate file, in a dll file. I use vb express 2008.
I start a new class library project, add the reference System.Windows.Forms to the project and add this code (this is only an example):
Inherits System.Windows.Forms.Button
Private Sub New()
Me.Backcolor=Color.Red
End Sub
I compile the project and get the dll file. Then I add this file to the toolbox, but I get the error message: "this control has no components."
View 3 Replies
May 3, 2010
I'm trying to play with this: [URL]..I have no clue how to use it though.What i THOUGHT i had to do was open the project and "build" it to produce a .dll or something which i would then add as a reference in my new project. I'm unable to open the solution so i could not test this theory.
View 6 Replies
Jul 1, 2010
Im trying to add a custom combobox to the database, the problem is i cant figure out how to do it. This combobox has images in it, i had to find the code to put the images in it cause the .net framework does not support icon's in combobox's. here is the code i found, cant remember where i got it, i think from code project.
Spoiler
Public Class ComboIcon
Inherits ComboBox
[Code].....
View 2 Replies
Apr 3, 2010
I have created a custom class, which contains a panel and a label on it. I added to this class a pcaption property, which holds the label text. This property is browsable and I can change its value.But when I drag the custom control to the form and change the pcaption property, it has no effect. Even the <Defaultvalue> has no effect. Why?
Here is the class code:
Imports System.ComponentModel
Public Class mypanel
Inherits Windows.Forms.Panel
Private panelcaption As String
[code]....
Color values are unimportant, you can change it.
View 3 Replies
Nov 19, 2010
I have created 2 WPF control which reside in the same folder and i want to add one control to the other.
The controls are added in a Win Forms project.
the thing is that in a custom Win Forms control I can see my two WPF controls in the toolbox but in the WPF designer I cannot see any WPF controls.[code]...
View 2 Replies
Oct 29, 2009
I took over a project for another individual. He has created a variety of custom controls (which I have no experience with). So one of these controls is displayed as a combo box. (It is called ctlTechnician). There are 4 items on the dropdown list. What I am trying to do is to set the selected index to -1 (along with other things) when the user logs off so that the control is back to its original state.[code]....
View 2 Replies
Dec 15, 2009
Is this possible? I am trying to create my own "X" and "minimize" buttons on my form -- the only way that I can currently think to do it is by making my form have no border, and creating a 'fake' menu bar using labels and buttons for minimizing and maximizing. The goal here is to be able to have custom icons for maximize, close, etc that may not match the Windows default scheme.
View 1 Replies
Apr 15, 2010
want to create a custom control of the button such as the button will be a bit enlarged and with a different colour.A custom control is a class that either inherits the Control class directly or some other control.So Iadded class named class1.vb and added this line:Inherits System.Windows.Forms.Button
View 6 Replies
Dec 29, 2011
I know how to create custom controls with all sorts of properties, but I cannot get a collection property to work
View 3 Replies
Jul 26, 2011
I looking for someone who are familar with custom control. I want to create two panels and the splitterbar to have a button in it where i can click to expandablecollaspe on either of the panels. I tried to use splitContainer where I can resize between the two panels and expandablecollaspe them, but I can't make the button on the splitterbar.
View 3 Replies
Jun 13, 2009
This is purely academic-- I'm looking for an example of a custom control, created from scratch as in not built out of existing controls, you're actually handling drawing it, ect entirely yourself.
View 4 Replies
Sep 28, 2007
I am new in .net framework 2.0. I have to create a custom control. How to create it?
View 7 Replies
Aug 5, 2009
I've been working with this for a while now and have finally come to you for help. I have a custom control that inherits from a label and I'm trying to use it in a datagridview. I have followed this example and have tried to adapt it to my needs.
The custom control in this case is a label with a boolean type property named Value. When value is true, the label.text = "ON" and the color is red. When value is false, the label.text = "off" and the color is transparent. This is the effect I need to show in the dgv.
I have attached my developing project and would like you to take a look if you can. The project has a single form with the dgv, the custom control and a button on it. When the button is clicked the value of the custom control toggles. The control on the form changes color and text as it should, but the cell in the dvg simple changes text from FALSE to TRUE.
View 2 Replies
Oct 4, 2011
I've not really worked with them before, well at all really. How would I go about creating a control which has multiple picture boxes, so then I can access each picturebox and refer to them via custom properties? I'm not aware you can draw several picture boxes and combine them into one control?
View 2 Replies
Mar 8, 2012
I am new to WPF and custom controls.I have implemented a custom control in VB with WPF and MVVM based on Davids example: [URL]..I have a custom control libary and a reference to my project to implement my control.I implement my contol in the View via XAML:
[Code]...
View 2 Replies
May 24, 2011
I am trying to add datagridview control in my custom control but i failed.I started creating new project[windows custom control library], added datagridview control on it and also added a property naming "DGVMain" which refers to datagridview control.I compiled it.
While testing i find its properties like visible and other working but when i click on columns property it doesn't work. i.e i cannot add/edit columns into the datagridview of my custom control.
Did i miss any steps or do i need to add some more actions?
View 1 Replies
Apr 16, 2009
In our IDE, for example, Visual Studio, if we display the properties of a System.Windows.Forms.Button control, we see some properties that expose anoter set of properties. For example: FlatAppearance, Font, Location, Margin, etcetera.I would like to do something similar in a custom control.I know the code behind is wrong, but here is an example of what I´m trying to do:
Public Class StateOfMyCustomControl
Public Enum EnumVisibility
Visible
[code]....
In my IDE, in the properties window of my custom control, I would like to see my property State, with the possibility of display it to set the properties Visibility and EventManagement.
View 1 Replies
Jul 8, 2009
is it possible to add a custom control to a datagridview column?
View 2 Replies
Oct 7, 2009
I'm trying to add a custom DropDown to the PropertyGrid for a control. I am adding the TrackBar control.It works fine, except, I would like to have the values updated in the PropertyGrid as I move the TrackBar. As it is now, it only updates the PropertyGrid when I finish and click off the TrackBar.I know the problem lies in the Type Editor. How can I get it to allow interim values to be processed. Is there some callback function I can use?
[Code]...
View 2 Replies