How generate SQL script in SQL Server Management Studio to create database from SQL Server?

In SQL Server Management Studio is opportunity to generate script with SQL query creating all objects from any database.

First step to do it is select node your database to create script for it. Right click on it and choose Task->Generate Scripts.

cc1The wizard window appear.

cc2Click the Next button. If You want to select some objects from database You may choose Select specific databse objects radio button.

cc3Click the Next button. In this step You may choose any place for your script file or files, if You choose Single file per object.

cc4Click theĀ Next button.

cc5Click the Next button.

cc6Click the Finish button. The content of script file is ready.