Logo
programming4us
programming4us
programming4us
programming4us
Home
programming4us
XP
programming4us
Windows Vista
programming4us
Windows 7
programming4us
Windows Azure
programming4us
Windows Server
programming4us
Windows Phone
 
Windows Server

BizTalk 2009 : WCF LOB Adapter SDK (part 2) - UI Logical Grouping

- Free product key for windows 10
- Free Product Key for Microsoft office 365
- Malwarebytes Premium 3.7.1 Serial Keys (LifeTime) 2019
6/26/2011 4:33:16 PM

2. Step 2: UI Logical Grouping

In this step, you will modify the HotelAdapterBindingElement and HotelAdapterUri classes to logically group the binding and connection properties that you created in step 1. You will create three categories and arrange the properties within these categories, as shown in Table 8.

Table 8. Adapter Property Categories
Property NameCategory
EnableConnectionPoolingMisc
ApplicationConnection
EnableAuthenticationConnection
HostConnection
PollingPeriodInbound

When you complete this step and build the project, the binding and connection properties will be grouped and presented in the Add Adapter Service Reference plug-in and Consume Adapter Service add-in, as shown in Figures 8 and 9.

Figure 8. Categorized connection properties

Although categorizing properties is optional, we recommend that you don't ignore this step. The reasoning is simple—categorizing improves user experience, since in many if not most cases adapter consumers will configure adapters using the UI tools.

Figure 9. Categorized binding properties

As you can guess, the implementation is fairly straightforward and doesn't require more than applying the System.ComponentModel.Category attribute to the custom properties. Let's start with the HotelAdapterBindingElement class:

  1. In Visual Studio, open the HotelAdapterBindingElement.cs file.

  2. To assign the Misc category to the EnableConnectionPooling property, place the [System.ComponentModel.Category("")] line of code at the beginning of the EnableConnectionPooling implementation, as shown here:

    [System.Configuration.ConfigurationProperty("enableConnectionPooling",
    DefaultValue = true)]

    public bool EnableConnectionPooling
    {
    get
    {
    return ((bool)(base["EnableConnectionPooling"]));
    }
    set

    {
    base["EnableConnectionPooling"] = value;
    }
    }

  3. Specify the Inbound category for the PollingPeriod property by placing the [System.ComponentModel.Category("Inbound")] line of code at the beginning of the PollingPeriod property, as shown in the following code snippet:

    [System.ComponentModel.Category("Inbound")]
    [System.Configuration.ConfigurationProperty("pollingPeriod",
    DefaultValue = 10)]

    public int PollingPeriod
    {
    get
    {
    return ((string)(base["pollingPeriod"]));
    }
    set
    {
    base["pollingPeriod"] = value;
    }
    }

Follow a similar procedure for the HotelAdapterConnectionUri class:

  1. In Visual Studio, open the HotelAdapterConnectionUri.cs file.

  2. Expand the Custom Generated Properties region, and apply the [System.ComponentMode.Category("Connection")] attribute to each of the properties in the region. When you finish, the Custom Generated Properties region should match the following code snippet:

    #region Custom Generated Properties

    [System.ComponentModel.Category("Connection")]
    public string Application
    {
    get
    {
    return this.application;
    }
    set
    {
    this.application = value;
    }
    }


    [System.ComponentModel.Category("Connection")]
    public bool EnableAuthentication
    {
    get
    {
    return this.enableAuthentication;
    }
    set
    {
    this.enableAuthentication = value;
    }
    }

    [System.ComponentModel.Category("Connection")]
    public string Host
    {
    get
    {
    return this.host;
    }
    set
    {
    this.host = value;
    }
    }

    #endregion Custom Generated Properties


  3. Save and build the project.

In the next step, you will work with the classes and interfaces responsible for establishing and managing connection to the LOB systems.

Other -----------------
- SQL Server 2008 : Configuring the Instance (part 3)
- SQL Server 2008 : Configuring the Instance (part 2) - Specifying the Backup Compression Default & Enabling Login Failure Auditing
- SQL Server 2008 : Configuring the Instance (part 1) - Viewing Configuration Settings & Specifying Maximum and Minimum Server Memory
- Microsoft PowerPoint 2010 : Expanding PowerPoint Functionality - Loading and Unloading Add-ins
- Microsoft PowerPoint 2010 : Expanding PowerPoint Functionality - Viewing and Managing Add-ins
- Microsoft Dynamics CRM 2011 : Sending and Tracking Email Messages in Microsoft Dynamics CRM for Outlook
- Microsoft Dynamics CRM 2011 : Using Microsoft Dynamics CRM for Outlook - Using the Add Contacts Wizard
- Microsoft Dynamics CRM 2011 : Using Microsoft Dynamics CRM for Outlook - Creating and Tracking Contacts
- Windows Server 2008 R2 : Managing Disks and Disk Storage - Understand the Basics (part 2) - Work with Partitions & Use DiskPart
- Windows Server 2008 R2 : Managing Disks and Disk Storage - Understand the Basics (part 1) - Work with Your Storage
 
 
Top 10
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 2) - Wireframes,Legends
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Finding containers and lists in Visio (part 1) - Swimlanes
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Formatting and sizing lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Adding shapes to lists
- Microsoft Visio 2013 : Adding Structure to Your Diagrams - Sizing containers
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 3) - The Other Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 2) - The Data Properties of a Control
- Microsoft Access 2010 : Control Properties and Why to Use Them (part 1) - The Format Properties of a Control
- Microsoft Access 2010 : Form Properties and Why Should You Use Them - Working with the Properties Window
- Microsoft Visio 2013 : Using the Organization Chart Wizard with new data
 
programming4us
Windows Vista
programming4us
Windows 7
programming4us
Windows Azure
programming4us
Windows Server