TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
Answers
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
Forums
Monthly Leaders
Forum guidelines
Vasu Gadhiya
NA
429
102.9k
stop receiving data from Serial Port.
Dec 9 2015 7:20 AM
Hello i have write code (event Handler) for get data from Serial port.
its completely fire when data is received.
but my requirement is to disable or enable data receive in between programme.
i cant stop receiving data from serial port using DisableRec Method.
class i
{
public i()
{
// ---------
port.DataReceived += new SerialDataReceivedEventHandler(port_DataReceived);
}
void port_DataReceived(object sender, SerialDataReceivedEventArgs e)
{
MessageBox.Show("Data Receive");
}
public void DisableRec()
{
port.DataReceived -= new SerialDataReceivedEventHandler(this.port_DataReceived);
}
public void EnableRec()
{
port.DataReceived += new SerialDataReceivedEventHandler(port_DataReceived);
}
}
Reply
Answers (
1
)
code for send mail in asp net using c# through asp.net from
How to validate all HTML Tags using Regular Expression in