SlideShare a Scribd company logo
1 of 26
Packaging and Deploying .NET Applications


Pre-Assessment Questions
    •    User defined exceptions are derived from the __________ class.
         a.   System.Exception
         b.   System.ApplicationException
         c.   System.SystemException
         d.   System.CustomException




 ©NIIT            Enhancing and Distributing Applications   Lesson 2A / Slide 1 of 26
Packaging and Deploying .NET Applications


Pre-Assessment Questions (Contd.)
    •    Which of the following involves end user participation?
         a.  Unit Testing.
         b.  Acceptance Testing.
         c.  Regression Testing.
         d.  Integration Testing.




 ©NIIT            Enhancing and Distributing Applications    Lesson 2A / Slide 2 of 26
Packaging and Deploying .NET Applications


Pre-Assessment Questions (Contd.)
    •    Which of the following is not true about test cases?
         a.  Test cases should test every line of code.
         b.  Test cases should include data values outside the range of valid data
             values.
         c.  Test cases should include all possible allowed data values.
         d.  Test cases should include invalid data values.




 ©NIIT            Enhancing and Distributing Applications   Lesson 2A / Slide 3 of 26
Packaging and Deploying .NET Applications


Pre-Assessment Questions (Contd.)
    •    Which of the following is used to locate and fix known bugs in a program?
         a.  Tracing
         b.  Testing
         c.  Exception Handling
         d.  Debugging

    •    The   On Error GoTo 0 statement is used to:
         •     Disable any exception handlers
         •     Pass the control to the first line of code
         •     Pass the control to the last line of code
         •     Pass the control to the next line of code




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 4 of 26
Packaging and Deploying .NET Applications


Solutions to Pre-Assessment
Questions
    1.   b.
    2.   b.
    3.   c.
    4.   d.
    5.   a.




 ©NIIT        Enhancing and Distributing Applications   Lesson 2A / Slide 5 of 26
Packaging and Deploying .NET Applications


Objectives
    In this lesson, you will learn to:
         • Create assemblies and place them in the Global Assembly Cache
         • Identify the version information stored in an assembly
         • Implement different deployment strategies
         • Identify different types of deployment projects
         • Create a deployment project
         • Use various editors in a deployment project
         • Deploy an application




 ©NIIT           Enhancing and Distributing Applications   Lesson 2A / Slide 6 of 26
Packaging and Deploying .NET Applications


Working with Assemblies
    •    An assembly is the collection of all information required by the Common
         Language Runtime (CLR) to execute an application.


    •    An assembly is self-descriptive and consists of three things:
          • Manifest
          • Microsoft Intermediate Language Code( MSIL)
          • Required Resources

    •    There are two types of assemblies:
          • Single-File
          • Multi-Fie




 ©NIIT              Enhancing and Distributing Applications    Lesson 2A / Slide 7 of 26
Packaging and Deploying .NET Applications


Working with Assemblies (Contd.)

    •    An assembly that groups all elements in a single file is called a single-file
         assembly


    •    An assembly that groups its elements in multiple files is called a multi-file
         assembly.


    •    Assemblies can also be classified as:
           • Private assemblies
           • Shared assemblies

    •    For assemblies to be shared they must be added to the Global Assembly Cache
         (GAC).



 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 8 of 26
Packaging and Deploying .NET Applications


Working with Assemblies (Contd.)
    •    Sharing an assembly and installing it to the GAC requires your assembly to be
         signed with a strong name.


    •    A strong name uniquely identifies an assembly.


    •    To create a strong named assembly, you need to:
           • Create a strong named key pair using sn.exe utility:
                     sn –k myKey.snk


          •   In the AssemblyInfo file, add attributes that describe the assembly:
                 <Assembly: AssemblyKeyFile (“myKey.snk”)>
                 <Assembly: AssemblyVersion (“1.0.1.2”)>




 ©NIIT               Enhancing and Distributing Applications   Lesson 2A / Slide 9 of 26
Packaging and Deploying .NET Applications


Working with Assemblies (Contd.)
    •    An assembly can be added to the GAC by using the following methods:
          • Using the Windows installer
          • Using the Gacutil.exe that is the Global Assembly Cache tool.
          • Using the Windows drag and drop feature.

    •    The version number of the assembly is divided into four parts. They are:
           • Major version number
           • Minor version number
           • Build number
           • Revision number

    •    The ILDisassembler utility can be used to view information about an assembly.
                    ildasm <assembly name>

 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 10 of 26
Packaging and Deploying .NET Applications


Getting Started with Deploying .NET
Applications
    •    The different deployment strategies are:


          •   XCOPY Deployment
          •   Visual Studio .NET Deployment Tools




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 11 of 26
Packaging and Deploying .NET Applications


XCOPY Deployment
    •    XCOPY deployment uses the MS-DOS XCOPY command to copy the contents of
         a directory and subdirectories to a target computer


    •    Limitations of XCOPY Deployment:


          •   Requires that all files needed by the application are located in the
              application directory.
          •   Requires that the .NET Framework be installed on the target machines.
          •   For applications that requires databases and shared components, the
              required resources must be available on each client machine.




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 12 of 26
Packaging and Deploying .NET Applications


Visual Studio .NET Deployment Tools
    •    Visual Studio .NET Deployment Tools allow you to create setup programs for
         deploying applications.


    •    To create a setup program for an application, Visual Studio.NET provides a
         special project type called Setup and Deployment Projects.


    •    The Setup and Deployment Projects type provides various templates for
         deploying different types of applications:


          •   Setup Project
          •   Web Setup Project
          •   Merge Module Project
          •   Cab Project




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 13 of 26
Packaging and Deploying .NET Applications


Visual Studio .NET Deployment Tools
(Contd.)
    •    In addition to the templates, Visual Studio .NET provides Setup Wizard that
         simplifies the task of creating a deployment project.


    •    You use the Setup Project template to package all application files and create
         a Windows Installer (.msi) file.


    •    A Web Setup project is similar to a Setup project but is used to install a
         Web-based application on a Web server.


    •    A Merge Module Project template should be used to deploy a component
         that is shared by a number of applications.




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 14 of 26
Packaging and Deploying .NET Applications


Visual Studio .NET Deployment Tools
(Contd.)
    •    When you build a merge module project, a .msm file is created. The .msm file
         cannot be executed independently and must be merged with another
         deployment project that creates a .msi file.


    •    You use the Cab Project template to package components that can be
         downloaded from a Web server to a Web browser


    •    The Setup Wizard guides you through a number of steps for creating a basic
         deployment project.


    •    You can use deployment project editors to specify details like files to be
         included and registry entries to be made at the time of installation.



 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 15 of 26
Packaging and Deploying .NET Applications


Deployment Project Editors
    •    Visual Studio.NET provides the following six editors in deployment projects:


          •    File System
          •    Registry
          •    File Types
          •    User Interface
          •    Custom Actions
          •    Launch Conditions




 ©NIIT            Enhancing and Distributing Applications   Lesson 2A / Slide 16 of 26
Packaging and Deploying .NET Applications


Deployment Project Editors (Contd.)
    •    The File System editor allows you to perform the following functions:


          •   Add a special folder
          •   Adding a custom folder
          •   Add a subfolder
          •   Delete a folder
          •   Add and remove project outputs
          •   Add and remove files
          •   Add and remove shortcuts




 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 17 of 26
Packaging and Deploying .NET Applications


Deployment Project Editors (Contd.)
    •    The Registry editor allows you to perform the following functions:
           • Add and remove registry keys
           • Add and remove registry key values
           • Importing an existing registry file in the registry editor

    •    The File Types editor allows you to perform the following functions:
           • Add and remove file types
           • Add and remove actions

    •    The User Interface editor allows you to perform the following functions:
           • Add and remove dialog boxes
           • Customize installation dialog boxes



 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 18 of 26
Packaging and Deploying .NET Applications


Deployment Project Editors (Contd.)
    •    The Custom Actions editor allows you to add and remove custom actions.


    •    The Launch Conditions editor allows you to perform the following
         functions:


          •   Add   a file launch condition
          •   Add   a registry launch condition
          •   Add   a windows installer launch condition
          •   Add   the .NET Framework launch condition
          •   Add   the Internet Information Services launch condition




 ©NIIT           Enhancing and Distributing Applications   Lesson 2A / Slide 19 of 26
Packaging and Deploying .NET Applications


Deployment Via Distributable Media
and Networks
    •    For deployment via distributable media, the .msi files created using Visual
         Studio .NET deployment tools can be copied to a floppy disk or other media.


    •    To deploy to a network location:
          • Create a Web Setup project.
          • Use the File System Editor to add the project output group for the
               application to the Web Setup project.
          • After building the installer, copy it to the server computer, from
               where it can be downloaded over the network.




 ©NIIT           Enhancing and Distributing Applications   Lesson 2A / Slide 20 of 26
Packaging and Deploying .NET Applications




                  Practice
         Deploying a Windows Based
                 Application




 ©NIIT      Enhancing and Distributing Applications   Lesson 2A / Slide 21 of 26
Packaging and Deploying .NET Applications


Problem Statement
    •    The development of the application for a stockbroker’s office is complete.
         The application now needs to be shipped to the client so that it can be
         installed on user computers. The installation process should perform the
         following tasks:
         • Copy all application files to a user computer.
         • Create a shortcut on the desktop of a computer to start the application.

    •    When a user begins installation, a license agreement should be displayed to
         the user. The process of installation should proceed only when a user accepts
         the license agreement.




 ©NIIT            Enhancing and Distributing Applications   Lesson 2A / Slide 22 of 26
Packaging and Deploying .NET Applications


Solution
    To solve the preceding problem, the following steps need to be performed:

         1.   Create a Deployment Project
         2.   Add the application files to the deployment project
         3.   Create a shortcut of the application
         4.   Add a dialog box to the deployment project
         5.   Build the solution and execute the installer




 ©NIIT            Enhancing and Distributing Applications   Lesson 2A / Slide 23 of 26
Packaging and Deploying .NET Applications


Summary
In this lesson, you learned that:


     •    An assembly is a collection of all information required by the Common
          Language Runtime (CLR) to execute your application.
     •    Deployment is the process of distributing the files that constitute an
          application.
     •    An assembly that groups all files in a single file is called a single-file
          assembly.
     •    An assembly made up of multiple files is called a multi-file assembly.
     •    Assemblies can be private or shared.
     •    For sharing an assembly it needs to be installed in the Global Assembly
          Cache.
     •    After creating an assembly for a component, you can create a deployment
          project to deploy the component.


 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 24 of 26
Packaging and Deploying .NET Applications


Summary (Contd.)
In this lesson, you learned that:


     •    There are two common deployment strategies available with .NET. They are:
          • XCOPY Deployment
          • Setup and Deployment projects

     •    To help you create a setup program for your application, Visual Studio.NET
          provides a special project type called Setup and Deployment Projects.


     •    The Setup and Deployment Project type provides a number of templates for
          deploying different types of applications. These are:
          • Setup Project
          • Merge Module Project
          • Web Setup Project
          • Cab Project
 ©NIIT              Enhancing and Distributing Applications   Lesson 2A / Slide 25 of 26
Packaging and Deploying .NET Applications


Summary (Contd.)
In this lesson, you learned that:
     • Visual Studio .NET provides the following six editors in deployment projects:
           • File System
           • Registry
           • File Types
           • User Interface
           • Custom Actions
           • Launch Conditions




 ©NIIT             Enhancing and Distributing Applications   Lesson 2A / Slide 26 of 26

More Related Content

Similar to Vb.net session 13

Vb.net session 14
Vb.net session 14Vb.net session 14
Vb.net session 14Niit Care
 
Vb net xp_16
Vb net xp_16Vb net xp_16
Vb net xp_16Niit Care
 
Vb.net session 09
Vb.net session 09Vb.net session 09
Vb.net session 09Niit Care
 
Vb.net session 01
Vb.net session 01Vb.net session 01
Vb.net session 01Niit Care
 
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...Ambassador Labs
 
(WPF + WinForms) * .NET Core = Modern Desktop
(WPF + WinForms) * .NET Core = Modern Desktop(WPF + WinForms) * .NET Core = Modern Desktop
(WPF + WinForms) * .NET Core = Modern DesktopOren Novotny
 
V mware thin app 4.5 what_s new presentation
V mware thin app 4.5 what_s new presentationV mware thin app 4.5 what_s new presentation
V mware thin app 4.5 what_s new presentationsolarisyourep
 
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptx
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptxDeploy and Update Jakarta EE & MicroProfile applications with Paketo.pptx
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptxJamie Coleman
 
Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?LOGINPHP360
 
Building reference images with mdt compress - MCT EU Summit - Portugal 2015
Building reference images with mdt compress - MCT EU Summit - Portugal 2015Building reference images with mdt compress - MCT EU Summit - Portugal 2015
Building reference images with mdt compress - MCT EU Summit - Portugal 2015Herman Arnedo
 
Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?LOGINPHP360
 
6294 a planning and managing windows 7 desktop deployments and environments
6294 a planning and managing windows 7 desktop deployments and environments6294 a planning and managing windows 7 desktop deployments and environments
6294 a planning and managing windows 7 desktop deployments and environmentsbestip
 
Establish reliable builds and deployments with Magento
Establish reliable builds and deployments with MagentoEstablish reliable builds and deployments with Magento
Establish reliable builds and deployments with MagentoUnic
 
VMworld 2013: ThinApp 101 and What's New in ThinApp Next Version
VMworld 2013: ThinApp 101 and What's New in ThinApp Next VersionVMworld 2013: ThinApp 101 and What's New in ThinApp Next Version
VMworld 2013: ThinApp 101 and What's New in ThinApp Next VersionVMworld
 

Similar to Vb.net session 13 (20)

Vb.net session 14
Vb.net session 14Vb.net session 14
Vb.net session 14
 
Vb net xp_16
Vb net xp_16Vb net xp_16
Vb net xp_16
 
Vb.net session 09
Vb.net session 09Vb.net session 09
Vb.net session 09
 
Vb.net session 01
Vb.net session 01Vb.net session 01
Vb.net session 01
 
Application slides
Application slidesApplication slides
Application slides
 
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...
Montreal Kubernetes Meetup: Developer-first workflows (for microservices) on ...
 
About .net
About .net About .net
About .net
 
(WPF + WinForms) * .NET Core = Modern Desktop
(WPF + WinForms) * .NET Core = Modern Desktop(WPF + WinForms) * .NET Core = Modern Desktop
(WPF + WinForms) * .NET Core = Modern Desktop
 
Ajs 1 c
Ajs 1 cAjs 1 c
Ajs 1 c
 
V mware thin app 4.5 what_s new presentation
V mware thin app 4.5 what_s new presentationV mware thin app 4.5 what_s new presentation
V mware thin app 4.5 what_s new presentation
 
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptx
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptxDeploy and Update Jakarta EE & MicroProfile applications with Paketo.pptx
Deploy and Update Jakarta EE & MicroProfile applications with Paketo.pptx
 
Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?
 
Training
TrainingTraining
Training
 
Developing NuGet
Developing NuGetDeveloping NuGet
Developing NuGet
 
Building reference images with mdt compress - MCT EU Summit - Portugal 2015
Building reference images with mdt compress - MCT EU Summit - Portugal 2015Building reference images with mdt compress - MCT EU Summit - Portugal 2015
Building reference images with mdt compress - MCT EU Summit - Portugal 2015
 
Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?Why is .Net Technology Recognised for Software Development?
Why is .Net Technology Recognised for Software Development?
 
6294 a planning and managing windows 7 desktop deployments and environments
6294 a planning and managing windows 7 desktop deployments and environments6294 a planning and managing windows 7 desktop deployments and environments
6294 a planning and managing windows 7 desktop deployments and environments
 
Assemblies
AssembliesAssemblies
Assemblies
 
Establish reliable builds and deployments with Magento
Establish reliable builds and deployments with MagentoEstablish reliable builds and deployments with Magento
Establish reliable builds and deployments with Magento
 
VMworld 2013: ThinApp 101 and What's New in ThinApp Next Version
VMworld 2013: ThinApp 101 and What's New in ThinApp Next VersionVMworld 2013: ThinApp 101 and What's New in ThinApp Next Version
VMworld 2013: ThinApp 101 and What's New in ThinApp Next Version
 

More from Niit Care (20)

Ajs 1 b
Ajs 1 bAjs 1 b
Ajs 1 b
 
Ajs 4 b
Ajs 4 bAjs 4 b
Ajs 4 b
 
Ajs 4 a
Ajs 4 aAjs 4 a
Ajs 4 a
 
Ajs 4 c
Ajs 4 cAjs 4 c
Ajs 4 c
 
Ajs 3 b
Ajs 3 bAjs 3 b
Ajs 3 b
 
Ajs 3 a
Ajs 3 aAjs 3 a
Ajs 3 a
 
Ajs 3 c
Ajs 3 cAjs 3 c
Ajs 3 c
 
Ajs 2 b
Ajs 2 bAjs 2 b
Ajs 2 b
 
Ajs 2 a
Ajs 2 aAjs 2 a
Ajs 2 a
 
Ajs 2 c
Ajs 2 cAjs 2 c
Ajs 2 c
 
Ajs 1 a
Ajs 1 aAjs 1 a
Ajs 1 a
 
Dacj 4 2-c
Dacj 4 2-cDacj 4 2-c
Dacj 4 2-c
 
Dacj 4 2-b
Dacj 4 2-bDacj 4 2-b
Dacj 4 2-b
 
Dacj 4 2-a
Dacj 4 2-aDacj 4 2-a
Dacj 4 2-a
 
Dacj 4 1-c
Dacj 4 1-cDacj 4 1-c
Dacj 4 1-c
 
Dacj 4 1-b
Dacj 4 1-bDacj 4 1-b
Dacj 4 1-b
 
Dacj 4 1-a
Dacj 4 1-aDacj 4 1-a
Dacj 4 1-a
 
Dacj 1-2 b
Dacj 1-2 bDacj 1-2 b
Dacj 1-2 b
 
Dacj 1-3 c
Dacj 1-3 cDacj 1-3 c
Dacj 1-3 c
 
Dacj 1-3 b
Dacj 1-3 bDacj 1-3 b
Dacj 1-3 b
 

Recently uploaded

WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Mark Simos
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embeddingZilliz
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfMounikaPolabathina
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rick Flair
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 

Recently uploaded (20)

WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
Tampa BSides - Chef's Tour of Microsoft Security Adoption Framework (SAF)
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Training state-of-the-art general text embedding
Training state-of-the-art general text embeddingTraining state-of-the-art general text embedding
Training state-of-the-art general text embedding
 
What is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdfWhat is DBT - The Ultimate Data Build Tool.pdf
What is DBT - The Ultimate Data Build Tool.pdf
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...Rise of the Machines: Known As Drones...
Rise of the Machines: Known As Drones...
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 

Vb.net session 13

  • 1. Packaging and Deploying .NET Applications Pre-Assessment Questions • User defined exceptions are derived from the __________ class. a. System.Exception b. System.ApplicationException c. System.SystemException d. System.CustomException ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 1 of 26
  • 2. Packaging and Deploying .NET Applications Pre-Assessment Questions (Contd.) • Which of the following involves end user participation? a. Unit Testing. b. Acceptance Testing. c. Regression Testing. d. Integration Testing. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 2 of 26
  • 3. Packaging and Deploying .NET Applications Pre-Assessment Questions (Contd.) • Which of the following is not true about test cases? a. Test cases should test every line of code. b. Test cases should include data values outside the range of valid data values. c. Test cases should include all possible allowed data values. d. Test cases should include invalid data values. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 3 of 26
  • 4. Packaging and Deploying .NET Applications Pre-Assessment Questions (Contd.) • Which of the following is used to locate and fix known bugs in a program? a. Tracing b. Testing c. Exception Handling d. Debugging • The On Error GoTo 0 statement is used to: • Disable any exception handlers • Pass the control to the first line of code • Pass the control to the last line of code • Pass the control to the next line of code ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 4 of 26
  • 5. Packaging and Deploying .NET Applications Solutions to Pre-Assessment Questions 1. b. 2. b. 3. c. 4. d. 5. a. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 5 of 26
  • 6. Packaging and Deploying .NET Applications Objectives In this lesson, you will learn to: • Create assemblies and place them in the Global Assembly Cache • Identify the version information stored in an assembly • Implement different deployment strategies • Identify different types of deployment projects • Create a deployment project • Use various editors in a deployment project • Deploy an application ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 6 of 26
  • 7. Packaging and Deploying .NET Applications Working with Assemblies • An assembly is the collection of all information required by the Common Language Runtime (CLR) to execute an application. • An assembly is self-descriptive and consists of three things: • Manifest • Microsoft Intermediate Language Code( MSIL) • Required Resources • There are two types of assemblies: • Single-File • Multi-Fie ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 7 of 26
  • 8. Packaging and Deploying .NET Applications Working with Assemblies (Contd.) • An assembly that groups all elements in a single file is called a single-file assembly • An assembly that groups its elements in multiple files is called a multi-file assembly. • Assemblies can also be classified as: • Private assemblies • Shared assemblies • For assemblies to be shared they must be added to the Global Assembly Cache (GAC). ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 8 of 26
  • 9. Packaging and Deploying .NET Applications Working with Assemblies (Contd.) • Sharing an assembly and installing it to the GAC requires your assembly to be signed with a strong name. • A strong name uniquely identifies an assembly. • To create a strong named assembly, you need to: • Create a strong named key pair using sn.exe utility: sn –k myKey.snk • In the AssemblyInfo file, add attributes that describe the assembly: <Assembly: AssemblyKeyFile (“myKey.snk”)> <Assembly: AssemblyVersion (“1.0.1.2”)> ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 9 of 26
  • 10. Packaging and Deploying .NET Applications Working with Assemblies (Contd.) • An assembly can be added to the GAC by using the following methods: • Using the Windows installer • Using the Gacutil.exe that is the Global Assembly Cache tool. • Using the Windows drag and drop feature. • The version number of the assembly is divided into four parts. They are: • Major version number • Minor version number • Build number • Revision number • The ILDisassembler utility can be used to view information about an assembly. ildasm <assembly name> ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 10 of 26
  • 11. Packaging and Deploying .NET Applications Getting Started with Deploying .NET Applications • The different deployment strategies are: • XCOPY Deployment • Visual Studio .NET Deployment Tools ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 11 of 26
  • 12. Packaging and Deploying .NET Applications XCOPY Deployment • XCOPY deployment uses the MS-DOS XCOPY command to copy the contents of a directory and subdirectories to a target computer • Limitations of XCOPY Deployment: • Requires that all files needed by the application are located in the application directory. • Requires that the .NET Framework be installed on the target machines. • For applications that requires databases and shared components, the required resources must be available on each client machine. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 12 of 26
  • 13. Packaging and Deploying .NET Applications Visual Studio .NET Deployment Tools • Visual Studio .NET Deployment Tools allow you to create setup programs for deploying applications. • To create a setup program for an application, Visual Studio.NET provides a special project type called Setup and Deployment Projects. • The Setup and Deployment Projects type provides various templates for deploying different types of applications: • Setup Project • Web Setup Project • Merge Module Project • Cab Project ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 13 of 26
  • 14. Packaging and Deploying .NET Applications Visual Studio .NET Deployment Tools (Contd.) • In addition to the templates, Visual Studio .NET provides Setup Wizard that simplifies the task of creating a deployment project. • You use the Setup Project template to package all application files and create a Windows Installer (.msi) file. • A Web Setup project is similar to a Setup project but is used to install a Web-based application on a Web server. • A Merge Module Project template should be used to deploy a component that is shared by a number of applications. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 14 of 26
  • 15. Packaging and Deploying .NET Applications Visual Studio .NET Deployment Tools (Contd.) • When you build a merge module project, a .msm file is created. The .msm file cannot be executed independently and must be merged with another deployment project that creates a .msi file. • You use the Cab Project template to package components that can be downloaded from a Web server to a Web browser • The Setup Wizard guides you through a number of steps for creating a basic deployment project. • You can use deployment project editors to specify details like files to be included and registry entries to be made at the time of installation. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 15 of 26
  • 16. Packaging and Deploying .NET Applications Deployment Project Editors • Visual Studio.NET provides the following six editors in deployment projects: • File System • Registry • File Types • User Interface • Custom Actions • Launch Conditions ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 16 of 26
  • 17. Packaging and Deploying .NET Applications Deployment Project Editors (Contd.) • The File System editor allows you to perform the following functions: • Add a special folder • Adding a custom folder • Add a subfolder • Delete a folder • Add and remove project outputs • Add and remove files • Add and remove shortcuts ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 17 of 26
  • 18. Packaging and Deploying .NET Applications Deployment Project Editors (Contd.) • The Registry editor allows you to perform the following functions: • Add and remove registry keys • Add and remove registry key values • Importing an existing registry file in the registry editor • The File Types editor allows you to perform the following functions: • Add and remove file types • Add and remove actions • The User Interface editor allows you to perform the following functions: • Add and remove dialog boxes • Customize installation dialog boxes ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 18 of 26
  • 19. Packaging and Deploying .NET Applications Deployment Project Editors (Contd.) • The Custom Actions editor allows you to add and remove custom actions. • The Launch Conditions editor allows you to perform the following functions: • Add a file launch condition • Add a registry launch condition • Add a windows installer launch condition • Add the .NET Framework launch condition • Add the Internet Information Services launch condition ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 19 of 26
  • 20. Packaging and Deploying .NET Applications Deployment Via Distributable Media and Networks • For deployment via distributable media, the .msi files created using Visual Studio .NET deployment tools can be copied to a floppy disk or other media. • To deploy to a network location: • Create a Web Setup project. • Use the File System Editor to add the project output group for the application to the Web Setup project. • After building the installer, copy it to the server computer, from where it can be downloaded over the network. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 20 of 26
  • 21. Packaging and Deploying .NET Applications Practice Deploying a Windows Based Application ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 21 of 26
  • 22. Packaging and Deploying .NET Applications Problem Statement • The development of the application for a stockbroker’s office is complete. The application now needs to be shipped to the client so that it can be installed on user computers. The installation process should perform the following tasks: • Copy all application files to a user computer. • Create a shortcut on the desktop of a computer to start the application. • When a user begins installation, a license agreement should be displayed to the user. The process of installation should proceed only when a user accepts the license agreement. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 22 of 26
  • 23. Packaging and Deploying .NET Applications Solution To solve the preceding problem, the following steps need to be performed: 1. Create a Deployment Project 2. Add the application files to the deployment project 3. Create a shortcut of the application 4. Add a dialog box to the deployment project 5. Build the solution and execute the installer ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 23 of 26
  • 24. Packaging and Deploying .NET Applications Summary In this lesson, you learned that: • An assembly is a collection of all information required by the Common Language Runtime (CLR) to execute your application. • Deployment is the process of distributing the files that constitute an application. • An assembly that groups all files in a single file is called a single-file assembly. • An assembly made up of multiple files is called a multi-file assembly. • Assemblies can be private or shared. • For sharing an assembly it needs to be installed in the Global Assembly Cache. • After creating an assembly for a component, you can create a deployment project to deploy the component. ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 24 of 26
  • 25. Packaging and Deploying .NET Applications Summary (Contd.) In this lesson, you learned that: • There are two common deployment strategies available with .NET. They are: • XCOPY Deployment • Setup and Deployment projects • To help you create a setup program for your application, Visual Studio.NET provides a special project type called Setup and Deployment Projects. • The Setup and Deployment Project type provides a number of templates for deploying different types of applications. These are: • Setup Project • Merge Module Project • Web Setup Project • Cab Project ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 25 of 26
  • 26. Packaging and Deploying .NET Applications Summary (Contd.) In this lesson, you learned that: • Visual Studio .NET provides the following six editors in deployment projects: • File System • Registry • File Types • User Interface • Custom Actions • Launch Conditions ©NIIT Enhancing and Distributing Applications Lesson 2A / Slide 26 of 26