如何使用 Silverlight 访问 PostgreSQL

发布于 2024-10-08 17:54:03 字数 133 浏览 0 评论 0原文

我使用 silverlight IronPython 创建了刽子手游戏,并使用 postgresql 中的数据作为随机单词,但我不知道如何在 silverlight 中访问 postgresql 中的数据。 可以或应该怎样做?

谢谢!!

I create hangman game with silverlight ironpython and I use data in postgresql for random word but I don't know to access data in postgresql in silverlight.
how can or should it be done?

Thanks!!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

自此以后,行同陌路 2024-10-15 17:54:03

从 Silverlight 中,您无法直接访问数据库(请记住,它是一种实际上在客户端本地运行的 Web 技术,并且客户端无法直接通过 Internet 访问您的数据库)。

要从 Silverlight 与服务器通信,您必须使用 SOAP、WCF 或 RIA 服务等创建单独的 WebService。

该网络服务将在网络上公开您的数据。调用 WebService 方法从 Silverlight 程序获取数据。

该 WebService 层将成为您的中间层,它实际上在您的 postgresql 数据库和 Silverlight 应用程序之间架起桥梁。

From Silverlight you cannot access a database directly (remember it's a web technology that actually runs locally on the client and the client cannot access your database directly over the internet).

To communicate with the server from Silverlight, you must create a separated WebService either with SOAP, WCF or RIA Services for example.

That Webservice will expose your data on the web. Call the WebService method to get your data from your Silverlight program.

This WebService layer will be your middle tiers that actually makes the bridge between your postgresql database and your Silverlight application.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文