Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

C# windows form application with SQL connection

Posted on 2010-11-09
2
1,056 Views
Last Modified: 2013-12-17
Hi,
 
I'm developing an application called SysCons.. This application receives data from a serial port and stores it in a database and displays it on the screen..

I have already done with the connection part and everything works fine and also I have a sample database attached to see what kind of data I receive.

This application has been programmed in such a way that on start up when the user presses F10 the application loads the most recent 50 rows from the database and displays it on the screen.

The buffer or temp database table which I have created is called as currentTable which stores the data in a buffer before it is being pushed into the database.

The application is not in history mode when it is first initialized. Now I need an help so that when the user does PAGEUP and PAGEDOWN then the data on the screen should be refreshed. The table which I have created to hold the history data in a buffer is called HistoryTable.

I'm attaching my working application if you want to have a look at it... There is no to worry about serial port and all... Just u can run it without the need of any hardware interfaces. Just change the path of the database.

C-Application.zip
0
Comment
Question by:sairam123
2 Comments
 
LVL 40

Accepted Solution

by:
Kyle Abrahams earned 400 total points
ID: 34093382
http://edn.embarcadero.com/article/30129  

add a case for the appropriate keys and call your refresh routine.

case Keys.PgDown,  Keys.PgUp:  Refresh(); break;

private void WinForm_KeyDown(object sender,
             System.Windows.Forms.KeyEventArgs e)
{
  e.Handled = true;

  switch(e.KeyCode) {
    case Keys.Left:   label1.Text = "Left Arrow";   break;
    case Keys.Right:  label1.Text = "Right Arrow";  break;
    case Keys.Up:     label1.Text = "Up Arrow";     break;
    case Keys.Down:   label1.Text = "Down Arrow";   break;
    case Keys.Space:  label1.Text = "Space";        break;
    default:          e.Handled   = true;           break;
  }
}

Open in new window

0
 
LVL 21

Assisted Solution

by:Alpesh Patel
Alpesh Patel earned 100 total points
ID: 34101629
Hi,

write code on Form KeyDown, KeyUp or KeyPress event to sense the PageUP and PAge Down key is pressed.

If that is pressed then bind data again.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question