[英]How do you create a local database in visual studio
I am new to visual studio. 我是Visual Studio的新手。 I made an app using excel vba that converts words into code 128 and display them. 我使用excel vba制作了一个将单词转换为代码128并显示它们的应用程序。 I tried to recreate it, with visual studio, but I have no idea how to create a file that store data. 我试图用Visual Studio重新创建它,但是我不知道如何创建一个存储数据的文件。 For example, the barcode code 128 table should be accessible through code to convert a simple text into a barcode view. 例如,条形码代码128表应可通过代码访问,以将简单文本转换为条形码视图。 I know so far how to create service based database on sql, add column, and rows, but I need to know how to have (or create) a file with stored data to work with (like in excel, you create a sheet filled with data, and then, you can adress it using vba) 到目前为止,我知道如何在sql上创建基于服务的数据库,添加列和行,但是我需要知道如何拥有(或创建)一个具有存储数据的文件以供使用(例如在excel中,您创建一个包含数据,然后您可以使用vba进行处理)
You've a really good tutorial's on the internet who helps you building a local database on visual studio. 您在互联网上有一个非常不错的教程,可以帮助您在Visual Studio上构建本地数据库。
I'll give you a initial steps to build one: 我将为您提供构建步骤的初始步骤:
1st: After you create your project, Go to Project > Add New Item > And Choose Service-based Database 1st:创建项目后,转到“ 项目” >“ 添加新项” >,然后选择“ 基于服务的数据库”
2nd: Open your database located on Solution Explorer with the name: nameyouchoose.mdf 第二步:使用名称: nameyouchoose.mdf打开位于解决方案资源管理器上的数据库
3rd: It will open a DataSource on the Server Explorer where you can add your tables, records, etc... 第三:它将在服务器资源管理器中打开一个数据源,您可以在其中添加表,记录等。
Good tutorials: 好的教程:
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.