Custom Control From Scratch?
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
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
Nov 14, 2010
I was wondering is it would be possible to create a web browser from scrach(meaning not the webbrowser object) in Visual basic(or any other visual studio languages).
View 3 Replies
May 18, 2012
I am trying to create an empty table from scratch using Microsoft SQL Server Compact 3.5 and I am running into this problem.Please take a look at the screenshot below.[code]How come I do not have the same screenshot as the web site link below as Frank Smith showed in his example? What Do I have to do/install to have the same screenshot as in the web site below? I have Visual Studio 2008, Microsoft SQL Server 2005 and Microsoft SQL Server Compact 3.5 installed on my computer..url...
View 1 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
Jun 22, 2011
I want to build a simple chat app where people can go a url, type in a name and a message and click submit and it will basically show that message to everyone that is current connected.Firstly i would like to state i've had zero experience in sockets programming and the like. I'm simply a web 2.0 person building websites with css/html/js/ajax and backend i have asp.net on vb and sql server for database.So basically coming from an ajax background, i was wondering why do we even need to download any additional stuff to do web sockets? I mean in ajax i can simply create a asd.aspx file and use Response.Write(text) (text based on the input which are available through dissecting the url) and voila, the server side is done, all that's left is just to create new XMLHttpRequest and stuff in the client side.
So ok I'm not worried about the client side part of Web Sockets. but the server side part of web sockets is just difficult. so in the client side i have this: ws://localhost:8080/websocket. Is it true that it will work if is also an .aspx file as such: ws://localhost:8080/websocket.aspx ?I'm wondering so how do i continue from here? in Ajax i will supply parameters from client in the url as such: page.aspx?a=1&b=2 and do output in the server using Response.Write it's all clear but how do we do it in web sockets?
View 1 Replies
Jul 15, 2010
Rather than create a Form and use Graphics generated via the CreateGraphics Method, how does a System.Drawing.Graphics Object get built?
View 16 Replies
Dec 25, 2009
I want to know how I could create a bitmap from scratch with no images to start with.(I would say need. but than you would think this was for some sort of school project and it's not.)Basically, what I have is an image which is perfectly square in shape and has a black border with a black x going through it, what is not black is white. What I'm looking to know is how to take that small image (50x50 pixels) and make an image based upon those by placing them in X Rows of X amount. I'll make a couple example to show what I mean.(X's represent the 50x50 image.
[Code]...
View 7 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
Apr 21, 2009
We are migrating our applications to VB.Net 2008 from Classic VB and I need to create a base namespace and business layer. My method of approach is going to be to visit our top BA and identify the common areas of our (Fixed Income) company and try to form a decent inheritence model with as much of the code in generics as possible. What's everyone's experience of doing this and also as a second part of the question, we are looking at incorporating Web Focus into the OLAP side, how would this affect the design of the corporate namespace and it's derivatives?
View 3 Replies
Oct 12, 2010
i would like for my first project to be a CPU stress testing program (kind of like Core Damage or Intel Burn Test).I have no problem designing the form, but how and where should I start? I've done some searching, but haven't really found much. I think the reason for that is because nobody is really going to just give out source code for anything (which is completely understandable).
The main thing I would like to understand is what exactly makes the CPU work at 100%? And how could I design it to where it automatically determines the amount of cores/threads the CPU has, and utilize them 100% without having to open up one instance for each? Or is that jumping too far ahead?
EDIT > I know that I'll need to create some kind of loop for the CPU to process over and over until closed. I was thinking something along the lines of calculating Pi to 32 million digits or something like that.
> Another goal is to have some sort of error checking capability. I am an overclocker, and I would like to have this ability with this program. For example, it I make it to calculate Pi, then I would like for it to tell me if there were any errors in the digits it produced.
View 8 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
May 13, 2012
I'm currently starting a new job in which I will be working on some coding in the future and need some advice on some good places to start so I can learn this correctly. Essentially we need to bring VB4 code over to the new VB.net language and I will be tasked with this. The project consists of a large battery of tests for psychiatric patients consisting of mostly multiple choice questions presented one at a time - since VB4 isn't very compatible, I think I will create a new battery from scratch while using the old code as a reference point.
I started creating the code this weekend for fun and am really enjoying it. However, a huge problem has been the abandonment of control arrays in the new language... by the time I got to creating my first questionnaire I'm stumped and can't follow the old code. Clearly I'm not ready to tackle such a large project with no experience and need to start from scratch; who would have thought .
The reason why I'm here is not to ask you to help me with my work. What I'm wondering is if any of you have any cool advice of great places to start learning the language (books, websites, etc). The amount of literature is very overwhelming so I thought I would ask some people with experience for tips. If any of you have stumbled across learning material with emphasis on coding that would be useful in the design of questionnaires or multiple choice exams, it would be particularly useful.
So far my starting place is Visual Basic 2010 Step by Step with Michael Halvorson, it seems good at a glance in the sense that it couples theory with practice but I'm already sure I'll need a little more.
View 12 Replies
Feb 2, 2010
I'm following the sops from msdn on how to create a database from scratch. I would now like to programmatically add a single record via a command button?
View 3 Replies
Mar 19, 2010
The Vb.Net application creates a bitmap from scratch and either converts to a tiff or sends it to a printer. In both cases, the quality of the image (in this case the font) is not good at all. The sample code listed below creates the graphics object that I use to write to the image.
Dim gr2 As Graphics = Graphics.FromImage(New Bitmap(800, 1000), Imaging.PixelFormat.Format32bppPArgb))
[code]......
View 2 Replies
May 4, 2012
Without using MVVMLight, I need to implement drag and drop for photos onto a listbox using mvvm using Icommands preferably and interaction triggers, however if i use commands then I don't know what to pass in for a command parameter? Any ideas? Thanks.
Heres some ideas I tried:
Public Property ImageList As New ObservableCollection(Of ListBoxItem)
Public Property AddImageCommand As ICommand = New Adjuster.DelegateCommand(AddressOf addImage)
Public Property DropCommand As ICommand = New Adjuster.DelegateCommand(AddressOf dropImage)
[code]....
View 1 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