Showing posts with label How can we connect SQL server with visual studio. Show all posts
Showing posts with label How can we connect SQL server with visual studio. Show all posts

Wednesday, December 28, 2016

ASP.NET Web Forms Site

              Creating The new ASP.NET Web Forms Site in VS 2018 in This template enables you to set up a basic ASP.NET website. It contains a number of files and folders to jump-start the development of your site. The different file types are all discussed later in this chapter. The special App_Data folder and the functionality of the pages in the Account folder are discussed later in this book. This template uses an external framework called Bootstrap, a front-end framework that helps you to build websites that look great on multiple devices such as desktops, tables and phones. Unfortunately, a number of the controls that ship with ASP.NET (such as the Menu control you’ll see later) don’t render properly when using Bootstrap. That’s why I decided not to use this framework in this book, but instead to focus on all the functionality that ships with ASP.NET. For your own projects, you could use this Visual Studio template with Bootstrap, but you’ll need to implement alternatives for controls like the Menu. You can learn more about Bootstrap at http://getbootstrap.com.

ASP.NET Web Site (Razor v2 / Razor v3  

      You use these templates to create sites using Microsoft’s Web Pages framework.

ASP.NET Empty Web Site

                  The ASP.NET Empty Web Site template gives you nothing but two configuration files (Web.config and Web.Debug.config). The ASP.NET Empty Web Site template is useful if you have a bunch of existing files you want to use to create a new website or when you want to create your site from scratch. You use this template as the basis for the sample website you build in the book and add files and folders as you progress through the book.

ASP.NET Dynamic Data Entities Web Site

                  This template enables you to create a flexible yet powerful website to manage data in a database without a lot of manual code. This template is not discussed in this book, but you learn more about the Microsoft ADO.NET Entity Framework that is used by the template in later section. WCF Service This template enables you to create a website containing one or more Windows Communication Foundation (WCF) Services. A WCF Service is somewhat similar to a web service in that it enables you to create methods that are callable over a network. However, WCF Services go much further than simple web services and offer you a lot more flexibility. You see how to create and consume a web service from a browser in Chapter 10.Although it seems you have to make a clear choice up front for the right website template, this isn’t really the case. Because an ASP.NET website in VS is essentially just a reference to a folder, it’s easy to add types from one template to another. For example, it’s perfectly acceptable (and very common) to add a WCF service file to a standard ASP.NET Web Forms Site or an ASP.NET Empty Web Site, as you see in later.

Creating and Opening a New Website

You have a number of different ways to create new and open existing websites. The choices you have here are largely influenced by the way you access the website (either on your local machine with Visual Studio on it or on a remote machine), and whether you want to use IIS Express (the built-in web server that ships with VS) or the full version of IIS — the web server that comes with Windows. All the examples in this book assume that you open sites from your local hard drive and that you use IIS Express, a trimmed down version of IIS, because it’s very convenient to develop sites with it.
However, later I will shows you how to use and configure the full version of Internet Information Services, or IIS for short. This advanced web server comes with most editions of Windows and is mostly used for production hosting of your websites on the server editions of Windows, because it’s capable of serving web pages in high-traffic scenarios.

Creating New Websites

The next Try It Out section guides you through creating the Planet Wrox website, which is the project you work on in this book. All exercises in the remainder of the book assume you have this website open in VS, except where stated otherwise. The exercise instructs you to store your website
in a folder called C:\BegASPNET\Site. Take note of this folder name, because it’s used throughout this articles. If you decide to use a different folder, be sure to use your own location whenever you see this folder name in the book. Make sure you don’t use special characters like the hash (#) or insert a space in the folder name because you’ll run into trouble when developing your site. Finally, make sure you don’t create this folder under your Windows Documents folder (typically at C:\Users\ UserName\Documents), because you’ll run into problems later when accounts other than your own need access to your site this was the answer of ASP.NET Web Forms Site.


Creating a New ASP.NET 4.5.1 Website


Tuesday, December 27, 2016

Customizing Keyboard Shortcuts in vs


                 Another setting many developers like to change is keyboard shortcuts.and today we will Customizing Keyboard Shortcuts in vs Keyboard shortcuts are a great way to save time because they enable you to perform a task with a simple keyboard command instead of reaching for the mouse and selecting the appropriate item from the menu. To change the keyboard shortcuts, choose Tools ➪ Options, expand Environment, and click Keyboard.
                    Alternatively, press Ctrl+Q, type keyboard, and hit enter. Locate the command for which you want to change the shortcut in the list of commands. Because this list contains many items, you can
filter the list by typing a few letters from the command. For example, typing print in the Show Commands Containing field gives you a list of all print-related commands. Next, in the Press Shortcut Keys field, type a new shortcut and click Assign. Visual Studio enables you to enter a double shortcut key for a single command. For example, you can bind the command Close All Documents to the command Ctrl+K, Ctrl+O. To perform this command, you need to press
both key combinations in rapid succession. Although a double shortcut key may seem like overkill, it greatly increases the number of available shortcut keys.

Resetting Your Changes

                 Don’t worry if you feel that you have messed up Visual Studio by trying out the numerous customization options. You have many ways to restore Visual Studio to its previous state.

 Resetting the Window Layout 

             The command Reset Window Layout, accessible from the Window menu, resets all windows to the position they were in when you first started Visual Studio. This command is useful if you misplaced too many windows and ended up with a cluttered IDE.

   Resetting the Toolbox                               

                 If you removed an item from the Toolbox by mistake or even deleted an entire tab, you can reset the Toolbox to its original state by right-clicking the Toolbox and choosing Reset Toolbox. You need to think twice before you use this command because it also deletes all your custom code snippets.

Resetting All Settings

                 If you followed along with the previous Try It Out exercises, and then started experimenting with the customization possibilities, your IDE is now probably in one of two states: It either looks exactly the way you want it, or it looks like a complete mess. In the latter case, it’s good to know that it is easy to clean up the chaos. To completely revert all Visual Studio settings to the way they were right after installation, choose Tools ➪ Settings ➪ Import and Export Settings or Tools ➪ Import and Export Settings, depending on the version of VS you’re using. Then choose the Reset All Settings option and click Next. If you want, you can create a backup of the existing settings; otherwise, choose No, Just Reset Settings.
                 You get another screen that enables you to choose among a number of settings collections. Choose Expert Settings or Web Development because these options give you access to all the features you need to follow along with this articles. Finally, click Finish. This action causes all settings to be reset to their defaults, including the window layout, Toolbox and Toolbox customizations, shortcut keys, and everything you may have changed in the Visual Studio Options dialog box. So, use this command only when you’re really sure you want a fresh, new setup of Visual Studio.
                   With some basic knowledge about ASP.NET pages and Visual Studio, it’s time for some real action. In the next chapter, you see how to create ASP.NET websites and web pages in much more detail. You learn how to organize your site in a logical and structured way, how to add the many different types of files to your site and how to use them, and how to connect the pages in your site. However, before you proceed to the next chapter, there is one more important topic you need to look at: the sample application that comes with the next section.

The Sample Application in ASP.NET

Monday, October 17, 2016

How can we connect SQL server with visual studio

How can we connect SQL server with visual studio





Make connection from SQL server to the visual studio in this article we will make connection with visual studio from SQL server so one thing in this all course we will use SQL server 2012 and visual studio 2012.
And in this article we connect SQL server with visual studio through design and on after this article in another step we will connect SQL server with visual studio through code and we will use GridView formview listview.




To complete this we will use step for example in step one we open visual studio
1. Step one go to start menu>all program>visual studio and open it.
2. Step two create new website from left top corner in file menu new website.
3. Step three in solution explorer right click on website add new item and add new webform.
4. Step four Open toolbox in this expand data and drag and drop gridview in to design or in html.
5. Step five click on the right top corner of Gridview a little expand arrow chose new datasource from there and follow the instruction to make a connetion.
6. Step six click on next some times when connection come then select new connection.
7. Step seven give your server name its mean your computer name/SQL username for example <jhon-pc\cina> and then select the SQL authentication give your username and password and chose a database from SQL server and then press connect button and then next it some more time from there and finsh.
8. And in the last step go to standard toolbar and press the run and your data will be list on gridview.
For more information watch the video Bellow:

Popular Posts

Contact Form

Name

Email *

Message *