473,398 Members | 2,389 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

can't wrap my mind around events

My general problem with events seems to be that there are so many parts
to them, and I'm not sure where they all go or when you use which parts.
For example, there's the delegate, the event name, the event handler,
then the coding that wires it together. For the most part, I do
understand these things, but I get confused when it comes to putting it
all together.

More specifically, here's some code from a book:

this.txtMonthlyInvestment.TextChanged += new
System.EventHandler(this.txtMonthlyInvestment_Text Changed);

First off, do you need the 'this' keyword? Second, where does this code
go? In the Load event of the form that contains the text box?

Another example:

ProductList products = new ProductList(); //an array list object

products.Changed += new EventHandler(ChangedHandler);

Why isn't 'this' used in the second example? Is the book being
inconsistent, or is it a different situation? (In the book, it says it's
calling it from a different class, but I don't know what that means
exactly: "To handle an event from another class, you create an instance
of the class that raises the event and assign it to a class variable.")

Where does that first line go? (The declaration of products). The above
two lines are the entire example (except for the event handler itself),
so I think some stuff has been left out. It doesn't show which class
it's included in.
Basically I'm just very lost when it comes to events, and I always have.
I don't understand where all the code goes for each 'part', and that's
probably what it all comes down to, I guess.

Any help would be appreciated, or any suggestions for sites that clearly
explain events.

Thanks,
John
Nov 17 '05 #1
11 1487
John Salerno wrote:
More specifically, here's some code from a book:

this.txtMonthlyInvestment.TextChanged += new
System.EventHandler(this.txtMonthlyInvestment_Text Changed);

First off, do you need the 'this' keyword? Second, where does this code
go? In the Load event of the form that contains the text box?

this always refers to the current class instance. In your case, since
it is accessing text boxes, 'this' probably refers to the current form.
It may not be necessary to use 'this'. The author of the code may
have used it to stress that the txtMonthlyInvestment is part of the
current form. As to where it goes, it is normally placed in the
constructor of the form or in the load event. All that really matters
is that the line of code is executed before you need to catch the
events.
Another example:

ProductList products = new ProductList(); //an array list object

products.Changed += new EventHandler(ChangedHandler);
Why isn't 'this' used in the second example? Is the book being
inconsistent, or is it a different situation? (In the book, it says it's
It might be inconsistent, but 'this' may not be required here. It just
depends on where the code appears.
calling it from a different class, but I don't know what that means
exactly: "To handle an event from another class, you create an instance
of the class that raises the event and assign it to a class variable.")

Where does that first line go? (The declaration of products). The above
two lines are the entire example (except for the event handler itself),
so I think some stuff has been left out. It doesn't show which class
it's included in.


The declaration of Products could be anywhere. It could be at the top
of your form class. It could be a private variable inside a method or
as a property to a user defined class. Perhaps the author was
intending that it be placed in the top of the form class.
I hope this helped a little. I'm sure, once you look at events more
closely, that it will become easier for you.

Nov 17 '05 #2
John Salerno <jo******@NOSPAMgmail.com> wrote:
My general problem with events seems to be that there are so many parts
to them, and I'm not sure where they all go or when you use which parts.
For example, there's the delegate, the event name, the event handler,
then the coding that wires it together. For the most part, I do
understand these things, but I get confused when it comes to putting it
all together.

More specifically, here's some code from a book:

this.txtMonthlyInvestment.TextChanged += new
System.EventHandler(this.txtMonthlyInvestment_Text Changed);

First off, do you need the 'this' keyword?
Nope.
Second, where does this code
go? In the Load event of the form that contains the text box?
Well, you can put it wherever you want - but obviously the event won't
fire your handler until you've hooked it up.
Another example:

ProductList products = new ProductList(); //an array list object

products.Changed += new EventHandler(ChangedHandler);

Why isn't 'this' used in the second example? Is the book being
inconsistent, or is it a different situation? (In the book, it says it's
calling it from a different class, but I don't know what that means
exactly: "To handle an event from another class, you create an instance
of the class that raises the event and assign it to a class variable.")
That's just wrong. You don't need to have a member variable with a
reference to an instance in order to subscribe to an event - you just
need to have a reference for long enough to subscribe.
Where does that first line go? (The declaration of products). The above
two lines are the entire example (except for the event handler itself),
so I think some stuff has been left out. It doesn't show which class
it's included in.

Basically I'm just very lost when it comes to events, and I always have.
I don't understand where all the code goes for each 'part', and that's
probably what it all comes down to, I guess.

Any help would be appreciated, or any suggestions for sites that clearly
explain events.


There's nothing particularly magical about them - that's possibly
what's confusing you. Just think of the "+=" as calling an "add" method
and "-=" as calling a "remove" method, and think of a delegate as a
list of handlers. The only odd thing about delegates are C#'s handling
of += and -= (for the delegates themselves, not events), which are
actually calls to static methods which is how you can add to null...

--
Jon Skeet - <sk***@pobox.com>
http://www.pobox.com/~skeet
If replying to the group, please do not mail me too
Nov 17 '05 #3
InLine Comments:

"John Salerno" <jo******@NOSPAMgmail.com> wrote in message
news:Ao********************@rcn.net...
My general problem with events seems to be that there are so many parts to
them, and I'm not sure where they all go or when you use which parts. For
example, there's the delegate, the event name, the event handler, then the
coding that wires it together. For the most part, I do understand these
things, but I get confused when it comes to putting it all together.

More specifically, here's some code from a book:

this.txtMonthlyInvestment.TextChanged += new
System.EventHandler(this.txtMonthlyInvestment_Text Changed);

First off, do you need the 'this' keyword? Second, where does this code
go? In the Load event of the form that contains the text box? You do not need the "this" keyword. This just means use this classes method
named txtMonthlyInvestment_TextChanged. Without it, if there was a public
method with the same name 'txtMonthlyInvestment_TextChanged' on the base
class, and none on the derived class, it would use the base class' method
(if it had the same signature).

The event gets fired after Page_Load but the events get "attached" prior to
Page_Load. So, to make sure the event fires, you would place it in
InitializeComponent (I believe that is the correct method, may be
Page_Init...can't remember).

Another example:

ProductList products = new ProductList(); //an array list object

products.Changed += new EventHandler(ChangedHandler);

Why isn't 'this' used in the second example? Is the book being
inconsistent, or is it a different situation? (In the book, it says it's
calling it from a different class, but I don't know what that means
exactly: "To handle an event from another class, you create an instance of
the class that raises the event and assign it to a class variable.")

Where does that first line go? (The declaration of products). The above
two lines are the entire example (except for the event handler itself), so
I think some stuff has been left out. It doesn't show which class it's
included in.

Once again, the 'this' keyword is not required. You have class A and class
B. Class A exposes an event, Event E. In class B, you want to catch Event
E for when class A raises it. So, you would create a class B instance and
assign it to a variable of type "B". Then you would add the event handler
for Event E on the variable of type "B". ? Understand :)\

HTH a little at least ;)

Mythran

Nov 17 '05 #4
Mythran wrote:
Once again, the 'this' keyword is not required. You have class A and class B. Class A exposes an event, Event E. In class B, you want to catch Event
E for when class A raises it. So, you would create a class B instance and
assign it to a variable of type "B". Then you would add the event handler
for Event E on the variable of type "B". ? Understand :)\


I think this part is what confuses me.

Let's say you have class A, which is a button. The event for this class
is Click. You want class B to respond to this click. Now, is class B
responding to a particular button's Click event, or just any button that
is instantiated from class A?

For example: I have an OK button that was created from class A, and it's
on my main form. In class B, when I'm writing the code to wire the event
to the event handler, do I need to refer to this button specifically, or
do I simply create a new instance of A that isn't even used in the
program or anywhere on the form?
Nov 17 '05 #5
> Let's say you have class A, which is a button. The event for this class
is Click. You want class B to respond to this click. Now, is class B
responding to a particular button's Click event, or just any button that
is instantiated from class A?


Think delegate as a function pointer. Think of A as an object that will
need to call a function when an action occur. An event is associated
with the instance of a class not the class itself and when the event
occur it needs to call a function that could be anywhere.

Instantiate A, wire the event you want to A, this could be in any other
class such as B. A is the object, when it's click it has a function
pointer to a function in B.

--
Victor Hadianto
Blog: http://www.hadianto.net/destination

Nov 17 '05 #6
I had some trouble wrapping my head around them originally, but now I
consider them an indespensable tool.

Think of it like a radio broadcast. The message is only ever sent once,
but anyone that is 'tuned in' to the right station can hear the signal.

So, the broadcaster needs to declare a delegate (basically stating your
intention to broadcast). The delegate is then registered as an event in
a specific class (um, think of it like a radio station. Many stations
can be associated with one broadcaster)

Then, you need to set up your specific radios to tune into the Station
that you want to listen too. This is done by creating a function that
has the same signature as the original delegate. If the delegate says
it needs one string and two integers, then the 'Radio class' needs to
implement a function that takes one string and two integers as
parameters. This is the function that will process the request in any
way it decides too.

After this is done, you need to wire it all up. That's where the
Object.EventName += ... comes in. You must attach the event to the
function by creating a new Delegate reference to the function that will
eventually process the request.

So... (Warning, this was written in a text editor and is only for demo
purposes. Not sure if it will compile)

Namespace Broadcaster
{
public delegate void SendAMessage(string strMessage);

class RadioStation
{

public event SendAMessage BroadcastEvent;

public RadioStation() {}

public Broadcast Something(string strMyMessage)
{
if(broadcastEvent != null) //This is important. Always test
before firing
{
BroadcastEvent(strMyMessage);
}
}

} //End Class
class Radio
{
public string _strRadioName;
public radio(RadioStation rsNewStation, string strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}

public void DisplayBroadcast(string strStuff)
{
System.Forms.MessageBox.Show("Recieved from radio " +
_strRadioName + ": " + strStuff);
}
} //End class
} //End Namespace

/****************************/
Namespace Testing
{
using Broadcaster;
public class MyTest
{
public MyTest()
{
public RadioStation _rsHeavyMetalHeaven = new
RadioStation();

public Radio[3] _rRadio;

for(int i = 0; i < _rRadio.Length; i++)
{
_rRadio[i] = new Radio(rsHeavyMetalHeaven);
}

}

Main()
{
MyTest = new MyTest();

MyTest.rsHeavyMetalHeaven.BroadcastSomething("Grow l, growl,
DIE DIE DIE!");
MyTest.rsHeavyMetalHeaven.BroadcastSomething("That was
VegetarianDogs with 'die'. And now a word from our sponsor...");

}
}
}
This would be an even more effective example if there was another class
called say... OnlineListner that also implemented the BroadcastEvent
but did something different with it when the message is recieved.

Hope this helps a little.

Nov 17 '05 #7
I had some trouble wrapping my head around them originally, but now I
consider them an indespensable tool.

Think of it like a radio broadcast. The message is only ever sent once,
but anyone that is 'tuned in' to the right station can hear the signal.

So, the broadcaster needs to declare a delegate (basically stating your
intention to broadcast). The delegate is then registered as an event in
a specific class (um, think of it like a radio station. Many stations
can be associated with one broadcaster)

Then, you need to set up your specific radios to tune into the Station
that you want to listen too. This is done by creating a function that
has the same signature as the original delegate. If the delegate says
it needs one string and two integers, then the 'Radio class' needs to
implement a function that takes one string and two integers as
parameters. This is the function that will process the request in any
way it decides too (i.e. if different Radio classes implement an
abstract radio class, one can displays colors based on sound, one can
modulate out all the Bass notes, one just resends it).

After this is done, you need to wire it all up. That's where the
Object.EventName += ... comes in. This gets declared in the class that
you want to recieve the event (our Radio in this case). You must attach
the event to the function by creating a new Delegate reference to
whatever the end point is.

So... (Warning, this was written in a text editor and is only for demo
purposes. Not sure if it will compile)

Namespace Broadcaster
{
public delegate void SendAMessage(string strMessage);

class RadioStation
{

public event SendAMessage BroadcastEvent;

public RadioStation() {}

public void BroadcastSomething(string strMyMessage)
{
if(broadcastEvent != null) //This is important. Always test
before firing
{
BroadcastEvent(strMyMessage);
}
}

} //End Class
class Radio
{
public string _strRadioName;
public radio(RadioStation rsNewStation, string strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}

public void DisplayBroadcast(string strStuff)
{
System.Forms.MessageBox.Show("Recieved from radio " +
_strRadioName + ": " + strStuff);
}
} //End class
} //End Namespace

/****************************/
Namespace Testing
{
using Broadcaster;
public class MyTest
{
public MyTest()
{
public RadioStation _rsHeavyMetalHeaven = new
RadioStation();

public Radio[3] _rRadio;

for(int i = 0; i < _rRadio.Length; i++)
{
_rRadio[i] = new Radio(_rsHeavyMetalHeaven);
}

}

public Main()
{
MyTest = new MyTest();

MyTest._rsHeavyMetalHeaven.BroadcastSomething("Gro wl,
growl, DIE DIE DIE!");
MyTest._rsHeavyMetalHeaven.BroadcastSomething("Tha t was
VegetarianDogs with 'die'. And now a word from our sponsor...");

}
}
}
This would be an even more effective example if there was another class
called say... OnlineListner that also implemented the BroadcastEvent
but did something different with it when the message is recieved.

Hope this helps a little.

Russ

Nov 17 '05 #8

"John Salerno" wrote:

Let's say you have class A, which is a button. The event for this
class is Click. You want class B to respond to this click. Now, is
class B responding to a particular button's Click event, or just any
button that is instantiated from class A?
Depends on whether or not the event was declared as static. But we won't
go there because I think that would just make things more confusing,

So assuming the event exists at the instance level, in other words that
every instance of A has its own Click event, an instance of class B will
be responding to events from an instance of class A.
For example: I have an OK button that was created from class A, and
it's on my main form. In class B, when I'm writing the code to wire
the event to the event handler, do I need to refer to this button
specifically, or do I simply create a new instance of A that isn't
even used in the program or anywhere on the form?


You need the instance of class A, the OK button, in order to wire it to
the instance of class B.

public class A
{
public event EventHandler Click;

// Normally, the method for raising an event is protected virtual,
// but this is just for demonstration purposes.
public void OnClick()
{
EventHandler handler = Click;

if(handler != null)
{
handler(this, EventArgs.Empty);
}
}
}

public class B
{
public B(A aInstance)
{
// Here we are connecting the event in an instance of
// class A to an instance of class B.
aInstance.Click += new EventHandler(HandleClick);
}

private void HandleClick(object sender, EventArgs e)
{
Console.WriteLine("Handled Click event.");
}
}

// Somewhere else in your application...

A a1 = new A();
B b1 = new B(a1);

A a2 = new A();
B b2 = new B(a2);

Now, an instance of class A called 'a1' is connected via the Click event
to an instance of class B called 'b1'. And an instance of class A called
a2 is connected via the Click event to an instance of class B called
'b2'.

When a1 raises its event through a call to the OnClick method, only b1
will respond to the event. Likewise, when a2 raises the Click event,
only b2 will respond.


Nov 17 '05 #9
Woah, thanks for all that. But the book I'm reading doesn't even talk
about declaring delegates separately! Now there's even more I have to learn!

rh****@axys.com wrote:
I had some trouble wrapping my head around them originally, but now I
consider them an indespensable tool.

Think of it like a radio broadcast. The message is only ever sent once,
but anyone that is 'tuned in' to the right station can hear the signal.

So, the broadcaster needs to declare a delegate (basically stating your
intention to broadcast). The delegate is then registered as an event in
a specific class (um, think of it like a radio station. Many stations
can be associated with one broadcaster)

Then, you need to set up your specific radios to tune into the Station
that you want to listen too. This is done by creating a function that
has the same signature as the original delegate. If the delegate says
it needs one string and two integers, then the 'Radio class' needs to
implement a function that takes one string and two integers as
parameters. This is the function that will process the request in any
way it decides too (i.e. if different Radio classes implement an
abstract radio class, one can displays colors based on sound, one can
modulate out all the Bass notes, one just resends it).

After this is done, you need to wire it all up. That's where the
Object.EventName += ... comes in. This gets declared in the class that
you want to recieve the event (our Radio in this case). You must attach
the event to the function by creating a new Delegate reference to
whatever the end point is.

So... (Warning, this was written in a text editor and is only for demo
purposes. Not sure if it will compile)

Namespace Broadcaster
{
public delegate void SendAMessage(string strMessage);

class RadioStation
{

public event SendAMessage BroadcastEvent;

public RadioStation() {}

public void BroadcastSomething(string strMyMessage)
{
if(broadcastEvent != null) //This is important. Always test
before firing
{
BroadcastEvent(strMyMessage);
}
}

} //End Class
class Radio
{
public string _strRadioName;
public radio(RadioStation rsNewStation, string strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}

public void DisplayBroadcast(string strStuff)
{
System.Forms.MessageBox.Show("Recieved from radio " +
_strRadioName + ": " + strStuff);
}
} //End class
} //End Namespace

/****************************/
Namespace Testing
{
using Broadcaster;
public class MyTest
{
public MyTest()
{
public RadioStation _rsHeavyMetalHeaven = new
RadioStation();

public Radio[3] _rRadio;

for(int i = 0; i < _rRadio.Length; i++)
{
_rRadio[i] = new Radio(_rsHeavyMetalHeaven);
}

}

public Main()
{
MyTest = new MyTest();

MyTest._rsHeavyMetalHeaven.BroadcastSomething("Gro wl,
growl, DIE DIE DIE!");
MyTest._rsHeavyMetalHeaven.BroadcastSomething("Tha t was
VegetarianDogs with 'die'. And now a word from our sponsor...");

}
}
}
This would be an even more effective example if there was another class
called say... OnlineListner that also implemented the BroadcastEvent
but did something different with it when the message is recieved.

Hope this helps a little.

Russ


Nov 17 '05 #10
Hmm, it's starting to make a little more sense. I appreciate all this help.

I think one thing that had me confused at first (and that I see a little
more clearly now because I've seen an entire program presented in the
book I'm reading) is that I didn't realize that 'products' in one class
was different than 'products' in another class. I never realized this
because the code was presented in pieces, until I got to the end of the
chapter. Now I realize that each 'products' is a private member of its
own class, and is independent of the other.

Wavemaker wrote:
"John Salerno" wrote:
Let's say you have class A, which is a button. The event for this
class is Click. You want class B to respond to this click. Now, is
class B responding to a particular button's Click event, or just any
button that is instantiated from class A?

Depends on whether or not the event was declared as static. But we won't
go there because I think that would just make things more confusing,

So assuming the event exists at the instance level, in other words that
every instance of A has its own Click event, an instance of class B will
be responding to events from an instance of class A.

For example: I have an OK button that was created from class A, and
it's on my main form. In class B, when I'm writing the code to wire
the event to the event handler, do I need to refer to this button
specifically, or do I simply create a new instance of A that isn't
even used in the program or anywhere on the form?

You need the instance of class A, the OK button, in order to wire it to
the instance of class B.

public class A
{
public event EventHandler Click;

// Normally, the method for raising an event is protected virtual,
// but this is just for demonstration purposes.
public void OnClick()
{
EventHandler handler = Click;

if(handler != null)
{
handler(this, EventArgs.Empty);
}
}
}

public class B
{
public B(A aInstance)
{
// Here we are connecting the event in an instance of
// class A to an instance of class B.
aInstance.Click += new EventHandler(HandleClick);
}

private void HandleClick(object sender, EventArgs e)
{
Console.WriteLine("Handled Click event.");
}
}

// Somewhere else in your application...

A a1 = new A();
B b1 = new B(a1);

A a2 = new A();
B b2 = new B(a2);

Now, an instance of class A called 'a1' is connected via the Click event
to an instance of class B called 'b1'. And an instance of class A called
a2 is connected via the Click event to an instance of class B called
'b2'.

When a1 raises its event through a call to the OnClick method, only b1
will respond to the event. Likewise, when a2 raises the Click event,
only b2 will respond.

Nov 17 '05 #11
k. first off, this was GREAT exercise for me so thanks for the
googlespace.

This compiles in Mono (Fedora 4, Mono, MonoDevelop is my new toy :) -
can't get dovecot to work!!!) but I haven't figured out abstraction in
Mono so I had to implement everything three times... but this should be
a good example of delegates. Every call made to the BroadcastSomething
method in the 'RadioStation' class is handled by three entirely
independant 'Radio' objects. Two of them are BackwardsStation, one of
them is ForwardStation.
CODE:

//************RadioStationTesting.cs ---
// created on 9/6/2005 at 6:02 PM
namespace Broadcaster
{
using System.Diagnostics;
public delegate void SendAMessage(string strMessage);

public class RadioStation
{
public event SendAMessage BroadcastEvent;

public RadioStation() {}

public void BroadcastSomething(string strMyMessage)
{
if(BroadcastEvent != null) //This is important. Always test
//before firing
{
BroadcastEvent(strMyMessage);
}
}
} //End Class

public abstract class Radio
{
public string _strRadioName;
public Radio(RadioStation rsNewStation, string strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}
public abstract void DisplayBroadcast(string strStuff);
} //End class

public class BackwardsStation:RadioStation
{
public string _strRadioName;
public BackwardsStation(RadioStation rsNewStation, string
strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}

public void DisplayBroadcast(string strStuff)
{
string strTemp = "";
for(int i = strStuff.Length - 1; i > 0 ; i--)
{
strTemp += strStuff.Substring(i,1);
}
System.Console.WriteLine("Recieved from radio " +
_strRadioName + ": " + strTemp);
}
}

public class ForwardStation:RadioStation
{
public string _strRadioName;
public ForwardStation(RadioStation rsNewStation, string
strRadioName)
{
_strRadioName = strRadioName;
rsNewStation.BroadcastEvent += new
SendAMessage(DisplayBroadcast);
}

public void DisplayBroadcast(string strStuff)
{
System.Console.WriteLine("Recieved from radio " +
_strRadioName + ": " + strStuff);
}
}
}
/****************************/
namespace Testing
{
using Broadcaster;
using System.Collections;
public class MyTest
{
public RadioStation _rsHeavyMetalHeaven = new RadioStation();
public ArrayList _alRadio = new ArrayList();
private RadioStation RadioStation1;
private RadioStation RadioStation2;
private RadioStation RadioStation3;

public MyTest()
{
RadioStation1 = new BackwardsStation(_rsHeavyMetalHeaven,
"Radio #1");
RadioStation2 = new ForwardStation(_rsHeavyMetalHeaven,
"Radio #2");
RadioStation3 = new BackwardsStation(_rsHeavyMetalHeaven, "Radio
#3");
}
}
}
///-----------End File
//File: Main.cs
// project created on 9/6/2005 at 6:01 PM
using System;
using Testing;

class MainClass
{
public static void Main(string[] args)
{
MyTest mt= new MyTest();
mt._rsHeavyMetalHeaven.BroadcastSomething("Growl,g rowl...
DIE DIE DIE!");
mt._rsHeavyMetalHeaven.BroadcastSomething("That was
VegetarianDogs with 'die'. " +
"And now a word from our sponsor...");
}
}

OUTPUT:
--Sorry, I can't seem to capture my console window output in Fedora...
(I suck :{ )
Back to Windows Land:
If, in VS.Net (2003) you simply moved the Testing namespace to one
project, and the Broadcast namespace to a different one and included a
reference to Broadcast in Testing, you may start to see the value in
this. I have one class (a wrapper around a serial port driver) that
fires an event that is consumed by a windows form, a class on an
independant thread and Log4Net all at the same time, in multiple
projects and namespaces...

I have a different project where a Windows User control takes an object
from an independant thread as a parameter in the constructor (much like
Radio class). Basically it allows me to talk back to any independant
control from an entirely independant thread .

NOTE:
I have found that in any class I fire an event from, I MUST wrap the
call in a "!= null" check. Otherwise if no handler for the event is
ever created, it throws an exception. (Any opinions on this?)

k. Gonna give it a rest now. Hope nobody else ever has to go through my
pain to figure out delegates again. :)

Russ

Nov 17 '05 #12

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: lostinspace | last post by:
After four+ years of using FrontPage in a limited capacity and having created over 600 pages on my sites, I've finally (at least for the most part) abandoned FP, to begin the process of converting...
42
by: Mike P. | last post by:
Hello I come from the world of C++ programming, and I'm used to writing programs that are actually executed by the CPU, and that run with some semblance of performance. I have taken the time to...
13
by: LRW | last post by:
Having a problem getting a onSubmit function to work, to where it popsup a confirmation depending on which radiobutton is selected. Here's what I have: function checkdel() { if...
10
by: Kobu | last post by:
My question is about EOF (which is (int)-1 on the implementation I use). Type char on my implementation is 'signed' too. How is it that the input library functions that return EOF can be used...
15
by: Adam J. Schaff | last post by:
I have noticed that if a user closes a form via pressing return (either while the OK button has focus or if AcceptButton is set to OK for the form) then the "ENTER" keypress event fires ON THE...
6
by: scottyman | last post by:
I can't make this script work properly. I've gone as far as I can with it and the rest is out of my ability. I can do some html editing but I'm lost in the Java world. The script at the bottom of...
10
by: Benton | last post by:
Hi there, I have a UserControl with a couple of textboxes and a couple of buttons ("Save" and "Cancel"). The Click event for this buttons is in the UserControl's codebehind of course, so here's...
1
by: maya | last post by:
hi, I have to do a page where there's a paragraph with an img on top left and the text in paragr has to wrap around the image.. pls see screen-shot here......
8
by: Skeer | last post by:
This is what I'm having problems with: I have a image that is in an absolute positioned div at the bottom left of my content. I want the content to be full width until reaching the image then wrap...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.