Remote work with DB in C#

The question was asked: 6 years 11 months ago   views: 23

Please suggest architecture, tomorrow at work will have to do a big project.

The bottom line:

  • The user visits the site, makes something in the base to spell what he wants
  • The program tells your computer that came new client(updated once per minute for new customers) and shown in the system tray, immediately request a printout
  • The Manager sees the client and his order, print out the order form with data
  • Actions are performed, and the order enters a "Done"

Generally tough!

So, I connect remotely with mysql, take a table such as orders and bring her every minute I update it, here the question:

 How to announce that new customer came from?

There is this idea yet, the Manager will not be the same to watch all of the orders, for this you can do a select where orders = 'Not done' like this, record the number of rows which are returned to the base, for example 5, in a minute check again 5, again checking for already 6 ( > 5), i.e. there is a new order, correctly I think, friends? How to translate the order mode made it I know what I will do.

I almost forgot!The most important question!

How to get table from remote database and display it on the form, and the option to download the entire database every minute is not an option...

In General, if there are more ideas on architecture, tells.

Damn, now I can't sleep, think I will...

Asked: johniek_comp johniek_comp 21-06-2012 в 17:10:27
Judging by the question you are not interested in architecture, and the actual mechanism of how to do it. Moreover, it is unclear - web face where orders can be filed Yes or no? In General, the question reframe explained - Barmaley Barmaley 22-06-2012 в 11:38:00
Learn how to work with remote database in C#. The task is actually very simple, srednichek =) - AseN AseN 22-06-2012 в 13:43:29

Answers   2


I would work out WPF with database via WCF services, namely dualBindings for two-way communication. This will allow you to get away from timers and spam the database with repeated requests from customers (1st question). When adding a new customer get new information and send it to your customers challenge the "colback" (2nd).

Answered: wind wind 22-06-2012 в 14:04:16
  1. The order came
  2. The Manager shows a notification (new order 5).
  3. The Manager presses the button, he issued the first order of order, and simultaneously translates the status of this order in the treatment. 3.1. second, the Manager presses the button and he issued the order of the remaining new.
  4. The Manager calls the customer agrees the order. At the end puts the status to be sent.
  5. The courier taking your order. Returns to the office, hands over the loot to the cashier puts the order is executed.

something like that.

Answered: Yura Ivanov Yura Ivanov 21-06-2012 в 17:22:00