离线申请 [英] offline application

查看:108
本文介绍了离线申请的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

HI,

 我想开发一个WPF应用程序,该应用程序必须支持离线功能.

 I want to develop a WPF application where it has to support offline features.

当用户连接到Internet时,如果连接断开,它应该在SQL Server数据库中工作;当用户再次建立连接时,它应该从本地工作,然后连接至sql server.

When the user connects to the internet it should work from SQL server database when the connection is lost it should work from local and then connect to sql server when the connection established once again.

有人可以有效地对我说吗?

Can any one say me the effective way ?

任何示例代码都会有所帮助

any sample code for that would be helpful

 

此致

Jayakumar Natarajan

Jayakumar Natarajan

推荐答案

嗨杰伊,

我对您的要求感到困惑.但是,在这种情况下,您可以做的是在进行任何查询之前,或者更确切地说,在建立与数据库的连接之前,您可以编写一个通用代码来检查Internet连接.

I am baffled with ur requirement. However, in ur case what u can do is before making any query or rather before establishing the connection to database you can write a common code that checks internet connectivity.

根据响应,您可以建立与本地或SQL Server的连接.

Based upon the response you can establish the connection either to local or to SQL Server.

希望这对您有所帮助.

此致

Parth Shah.

Parth Shah.


这篇关于离线申请的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆