Learn How To Export Data from DataGridView to Excel using C# on Microsoft Windows 10 with an easy procedure.
Solutions -------
Implementing few lines of code to copy data from DataGridView to the Excel sheet having a formatted text using Windows clipboard
Note --------
1. Despit the easys procedure of exporting data, the lenght of the video is extended due to the following reasons:
a. User interface (UI) design steps are included
b. SQL Server connection procedure for live data from database
c. Connection string and transaction procedure
d. Data export
2. Long text of PasteSpecial command:
PasteSpecial(xlr, Type.Missing, Type.Missing, Type.Missing, Type.Missing, Type.Missing, true);
3. Additional Infromation on some the concept of "Missing value"
a. Microsoft offical site
https://docs.microsoft.com/en-us/dotn...
b. Stackoverflow forum
https://stackoverflow.com/questions/1...
Related Or Similar Videos --------
Fully uninstall SQL Server 2014 from Windows 10
-- • How to Fully Uninstall Microsoft SQL Serve... --
Youtube Call To Action -------
Don't forget to Like and Share my content and also Subscribe to my channel for more tips and tricks. This will help me grow
-- https://bit.ly/3Pakd48 --
C# Development Episode 3 Chapters -------
00:00 - EXPORT DATAGRIDVIEW to EXCEL file with C#
00:11 - How to create Windows Form app (.NET Framework) project
00:44 - Usage of anchors in design
02:11 - ATTENTION ! Skip recommended
02:24 - Adding Datasource to Datagridview using Data Source Configuration wizard
03:11 - How to get the connection string using Data Source Configuration wizard
03:31 - Adding additional libraries
03:46 - Connecting and getting data from SQL Server
05:37 - Using statement and its benefits
06:52 - First Run and Check
07:10 - Export DATA NOW - How to get Microsoft.Office.Interop.Excel DLL From NuGet
08:00 - How to add data from datagridview to clipboard
10:19 - Excel Application instance making
10:59 - Excel Range explained
11:40 - Adding workbook and worksheet to the Excel instance
14:18 - Try Catch statement added
14:53 - Bonus Tip - Autofit columns & Paste before Excel gets open
15:18 - Final Run
15:38 - Final presentation
15:57 - End Screen
Learn More in About Section -------
About Microsoft Excel:
Microsoft Excel is a spreadsheet developed by Microsoft for Windows, macOS, Android, iOS and iPadOS. It features calculation or computation capabilities, graphing tools, pivot tables, and a macro programming language called Visual Basic for Applications. Excel forms part of the Microsoft 365 suite of software
About Microsoft Visual Studio:
Visual Studio is an integrated development environment from Microsoft. It is used to develop computer programs including websites, web apps, web services and mobile apps
About C#:
C# is a general-purpose high-level programming language supporting multiple paradigms. C# encompasses static typing, strong typing, lexically scoped, imperative, declarative, functional, generic, object-oriented, and component-oriented programming disciplines.
About Microsoft SQL Server:
Microsoft SQL Server is a relational database management system developed by Microsoft. As a database server, it is a software product with the primary function of storing and retrieving data as requested by other software applications—which may run either on the same computer or on another computer across a network
About SQL:
Structured Query Language, abbreviated as SQL, is a domain-specific language used in programming and designed for managing data held in a relational database management system, or for stream processing in a relational data stream management system
About Stack Overflow:
Stack Overflow is a question and answer website for programmers. It is the flagship site of the Stack Exchange Network. It was created in 2008 by Jeff Atwood and Joel Spolsky. It features questions and answers on certain computer programming topics.