Yes that's correct. You can build on that base and expand the functionality.
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
The following code will do what you want without casting at all. I have omitted all the "extra" code, just the necessary functionality.
public abstract class DataType<T>
{
protected T _objCurrent;
protected T _Data
{
get { return _objCurrent; }...
You are using the Data field of the base class, where you should be using the TypedData field of the derived classes.
In other words:
s1.Data = "This is a test";
s2 = s1.TypedData;
This should work (unverified).
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they...
Here's some example code that you can tweak to suit your needs:
// This is the method you were using, taking a string
// and an image as arguments.
private void addWatermark(string text, Image img)
{
// Get the Graphics object from the image
Graphics G = Graphics.FromImage(img);
// Set...
Dim sngl As Single = 3.959
Dim intgr As Integer = CInt((sngl Mod 1) * (10 ^ (Len(sngl.ToString) - 2)))
;P
Only works if 0 < sngl < 10
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
You might want to look up Object Serialization. You can also start by looking at this page: http://www.codeproject.com/cs/miscctrl/ControlCloneTst.asp
It will explain, with source code, how to serialize form controls and other objects.
Regards, Ruffnekk
---
Is it true that cannibals don't eat...
Either serialize only one document per stream or deserialize all documents and then write a method that selects a particular document. As far as I know you can't serialize a collection and then deserialize one item of that collection only.
Regards, Ruffnekk
---
Is it true that cannibals don't...
I wrote an article explaining a bit about serialization here: http://www.donationcoder.com/Forums/bb/index.php?topic=7274.0
I might be of use to you.
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
Yes I tried debugging it but I can't see any event being fired after I start editing the treenode label's text.
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
Hi all,
I have an MDI parent form which has a Treeview control directly on it, docked left. The remaining space will have MDI child forms.
When I (at runtime) add a node to the Treeview, I want the user to be able to edit the textlabel of the node immediately without interaction. The code I...
Is "GlobalDeclaration.vb" a module? If so, is the module itself declared Private?
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
Start your application with a Sub Main from a module, and define Sub Main like this:
Module Module1
Public Sub Main(args() As String)
For Each arg As String In args
'Do something
Next
End Sub
End Module
The args() array is a String array containing all arguments passed...
Hi,
I´m using VB .NET 2003 and I´m trying to accomplish the following:
I want to be notified when a user scrolls the textbox horizontally.The TextBox is multi-line, no wordwrap and showing both scrollbars.
The reason I want to do this is to update a ruler that indicates the column number in...
You are taking the wrong approach here. You loop through each existing datarow and check if the current term is different from the user entered term. If this is not so then the term is added. This means that a new term will be added every time an existing term is not the same, that is the reason...
Hi,
I have a small problem which I can't seem to solve.
I have made a UserControl, completely user drawn. I need to override the BackColor property. The problem that arises when I override it, is that whenever I change the backcolor of the control on a Windows Form, the property is not set in...
If it's an ADO RecordSet you can populate a dataset with first:
Dim myDA As OleDbDataAdapter = New OleDbDataAdapter
Dim myDS As DataSet = New DataSet
myDA.Fill(myDS, myRecordSet, "MyTable")
Then you can use an SQL statement like:
Dim myDRS As DataRow() =...
xlDoc.SaveAs("c:\temp.csv", FileFormat:=Excel.XlFileFormat.xlCSVWindows, AddToMru:=False, TextVisualLayout:=Excel.XlTextVisualLayoutType.xlTextVisualLTR, CreateBackup:=True)
xlDoc is an object of type Excel.Worksheet
Intellisense *will* show you the enumeration possibilities. Just try it by...
What exactly are you trying to do? You can access all values on the form after creating a new instance and then showing it. After the dialog has closed you can still access all (changed) values untill you dispose it...
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because...
Here http://www.dotnet247.com/247reference/msgs/53/267819.aspx you can find a way to do it, but only with 1-bit (monochrome) uncompressed TIFF files.
Regards, Ruffnekk
---
Is it true that cannibals don't eat clowns because they taste funny?
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.