-
Book Overview & Buying
-
Table Of Contents
Microsoft SQL Azure Enterprise Application Development
By :
You will now use the SMO object model (SQL Server API) to connect to an SQL Azure database. Use SQL Server API to create a table in the database and add columns with chosen data types to the table and then create the table. While writing the code, wait for the intellisense to provide you with a drop-down list.
In the following steps, you will be creating database objects using the server API:
1. Create a Windows Application project using the Windows Forms Application template and give it a name of your own (herein, it is SmoCreate).
2. Right-click the project and choose Add Reference.
3. In the Add Reference window select and add the following references:
Microsoft.SqlServer.ConnectionInfo Microsoft.SqlServer.Management.sdk.Sfc Microsoft.SqlServer.Management.Smo
4. Drag-and-drop a button on to the Form1.vb.
5. Add the following code to the code page of Form1.vb:
Imports Microsoft.SqlServer.Management.Smo Public Class Form1 Private Sub Button1_Click...
Change the font size
Change margin width
Change background colour