I am writing an invoice program that monitors the state of the invoice on an android tablet. For simplicity consider the invoice as an integer variable that dynamically is changed in the PC program. How can I show the last value of the variable in the tablet? In fact, the customers see the last state of their order in the tablet, while the main program is running in the PC. My first initial guess is to simulate a web server in my PC (for example using IIS or wamp) and periodically request the value from it and show the result in the tablet. But I think this is not optimal and depletes the tablet battery. Do you have any better Idea?
- PC Platform: windows 7
- PC programming Language: C#
- PC DB: Access
- Android version 2.3
This is my sample code written in C# in the PC. I want to see the value of ''i'' on Tablet.
class sample
{
// I want the variable to be visible from the tablet
public int i;
}
** EDIT: **
My program is a standalone desktop program written in C#. My database engine is MS ACCESS. The security is not important for my case (at least for now), TCP connection through wifi is preferred (between PC and tablet), but if bluetooth has any advantage, I can also use it.