Windows Develop Bookmark and Share   
 index > Windows Forms Sample Applications > Web Based Windows Application
 

Web Based Windows Application

Hi all,

Currently I develping web based windows application, means it is windows application but communicate with server via http reqeust/httpresponse. The server could be windows server or other type like linux or unix.

For one action that performed from windows application, there is one request to server and server will returns with response.

My windows application also stores the session id, to identify user's action that performed.

I am looking for any reference for this kind like architecture.

Thanks.

AhJian

AhJian  Tuesday, August 26, 2008 4:56 AM

Hi!

First of all, there is no such thing as a web based windows application. Your application is a Windows Application. The architecture is called "client-server" architecture, because your windows application communicates with a server.

If you wanna know how to construct such a program, you could take a look at this example: http://www.codeproject.com/KB/IP/tcpclientserver.aspx.

If you have other questions, please ask.

Regards,

Lucian Baciu  Wednesday, August 27, 2008 10:07 AM

Well,

thanks Naicul for replying for this.

May be the term 'web based windows application' not so good to use. The piece of software that similar is just like MSN messenger, Yahoo messenger. User has to logon to server's and communicates with server to carry out necessary action such as add new friend, get latest friends list and etc.

Thus, on top of tcp/ip client server, I am wondering how the transfer of data is going on. For example, I logon to newly installed MSN messenger, it will fetch/synchronize all my MSN list to my pc, so the questions are:

1) I presume the data are transferred in form of XML? so, end up there will be many data in XML format for many actions?

2) There will bespecific action for the action, such as GetAllUsers, GetGroups, and so on....?

3) How do the messenger can dynamically locate server's url?

I appreaciate whoever reply on this.

AhJian  Tuesday, September 02, 2008 9:04 AM
AhJian wrote:

Well,

thanks Naicul for replying for this.

May be the term 'web based windows application' not so good to use. The piece of software that similar is just like MSN messenger, Yahoo messenger. User has to logon to server's and communicates with server to carry out necessary action such as add new friend, get latest friends list and etc.

Thus, on top of tcp/ip client server, I am wondering how the transfer of data is going on. For example, I logon to newly installed MSN messenger, it will fetch/synchronize all my MSN list to my pc, so the questions are:

1) I presume the data are transferred in form of XML? so, end up there will be many data in XML format for many actions?

2) There will bespecific action for the action, such as GetAllUsers, GetGroups, and so on....?

3) How do the messenger can dynamically locate server's url?

I appreaciate whoever reply on this.

For the first two question I'll have to ask you to take a look at the project at the link I've provided in my last post.

3) It does not dynamicly locate the server. You're gonna provide it's IP address in the client. Please also review that project.

Lucian Baciu  Tuesday, September 02, 2008 9:09 AM

Well, thanks for replying first.

I know and already take a look for the tcp client.

So my question now is... for example,

Stream stm = tcpclnt.GetStream();

1) I get the stream, let say, its list of user, so, whether the format could be in xml, like

<user id="1">User's Name 1</user>

<user id="2">User's Name 2</user>

or

user1;user2;user3.

Of course I know there's no definite format for the action, that's why I said its mostly XML. Because I will have many different type of action with different type of data to exchange, definately... simple string cannot be used.

2) Since I have many actions, thus what is the proper way of writting those action into functions or class?

Thanks.


AhJian  Tuesday, September 02, 2008 9:23 AM
AhJian wrote:

Well, thanks for replying first.

I know and already take a look for the tcp client.

So my question now is... for example,

Stream stm = tcpclnt.GetStream();

1) I get the stream, let say, its list of user, so, whether the format could be in xml, like

<user id="1">User's Name 1</user>

<user id="2">User's Name 2</user>

or

user1;user2;user3.

You can do it either way, you decide.

Of course I know there's no definite format for the action, that's why I said its mostly XML. Because I will have many different type of action with different type of data to exchange, definately... simple string cannot be used.

In this case, I'd go for XML too.

2) Since I have many actions, thus what is the proper way of writting those action into functions or class?


This is also an architectural problem. You can define a list of actions and send them as strings. Like you'd do with comands.

Lucian Baciu  Tuesday, September 02, 2008 9:40 AM

Hey... thanks Naicul for your promptly reply.

So your answer is actually what I coding right now.

And back to my question at top, am looking for reference for this kind of windows application, thus the tcpclient server would be too simple to handle this. You have any?

Cause when many actions... many data and it keeps growing, bad architecture will results in bad code maintaining in the future.

AhJian  Tuesday, September 02, 2008 9:45 AM

Well, there are many articles on the web and many books about this. You can start by reading this paper: http://www.sei.cmu.edu/str/descriptions/clientserver_body.html

Also, you could try and use the Architecturesection on this forum.

Regards,

Lucian Baciu  Tuesday, September 02, 2008 9:53 AM

Hi Ahjian,

For ur problem u need to use web service on the server. And to store or retrive data to-from server and client u had to call that service using ur windows application.

rajesh4ever  Tuesday, September 23, 2008 10:34 AM

You can use google to search for other answers

Custom Search

More Threads

• Error 1920 Verify that you have sufficient privilege to start system services while installing a web application.
• DataGrid row selection help !!!!
• Pocket TaskVision in VB.NET
• Thumbnail Generation
• Terrarium download not working
• Is there a standart control for "File, Edit, view, ..."?
• All Green Lights and No Critters
• access application settings from code
• Direct ADO instead of Web Service
• Exception Error