自动将Sql数据库连接到C#应用程序? [英] Automatically Connecting Sql Databases to C# Application?

查看:79
本文介绍了自动将Sql数据库连接到C#应用程序?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

嘿那里

我想知道是否有人可以向我提供有关SQL数据库和C#应用程序的信息.基本上,我正在从事一个项目,在该项目中,我希望能够使用C#应用程序自动创建,导入,导出和删除SQL数据库.我的意思是,不必在程序中提供位置,例如一个配置文件,我将能够添加某种例程,该例程将在用户选择的目录中创建一个文件夹.我还希望能够允许程序检查以确保在每次运行时都与数据库建立连接.到目前为止,我已经在任何地方搜索了解决方案,但没有发现任何问题,因此任何信息都将非常有用.谢谢!

Martyn

Hey there

I was wondering if anyone could provide me with information about SQL databases and C# Applications. Basically I''m working on a project in which I would like to be able to Create, Import, Export and Delete SQL Databases using a C# Application automatically. By this I mean that instead of having to provide a location in the program, e.g. A config file, I would to be able to add in some kind of routine that would create a folder in a directory selected by the user. I would also like to be able to allow the program to check to make sure there is a connection to the database during every runtime. So far I''ve searched every where for a solution and have come across nothing so any information would be great. Thank you!

Martyn

推荐答案

您可以看一下这篇文章
用于从DataBase和使用反射将DataTable保存到数据库中 [
You can take a look at this article
General purpose class to fill DataTable(s) from DataBase and to save DataTable(s) to DataBase using reflection[^]

It may be helpful to you.


这篇关于自动将Sql数据库连接到C#应用程序?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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