Peter's Date Package Version 2.

0 Installation Guide
Copyright © 2002-2006, Peter L. Blum. All Rights Reserved

USE OF THIS SOFTWARE INDICATES ACCEPTANCE OF THE LICENSE AGREEMENT. PLEASE READ THE LICENSE AGREEMENT IN THE FILE "LICENSE AGREEMENT.HTML".

For technical support, please see the topic “Technical Support and Other Assistance”. Peter loves feedback. It’s the only way to improve the software and its documentation. If you have questions, ideas, enhancements or bugs, please email Contact@PeterBlum.com. Please visit http://www.PeterBlum.com for information on updates and other products. Each product’s main page identifies its update history and provides access to updates at the top of the page.

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Table of Contents
OVERVIEW WHAT'S INCLUDED FIRST TIME INSTALLATION INSTALLING PETER’S DATE PACKAGE INTO VISUAL STUDIO.NET INSTALLING PETER’S DATE PACKAGE INTO YOUR WEB APPLICATIONS USING ALTERNATIVE LOCATIONS FOR FOLDERS Scripts Folder (2_0_#) Appearance Folder Licenses Folder INSTALLING LICENSES Trial License Web Server Licenses Site License Redistribution License Application_Start vs Application_OnStart Troubleshooting Licenses DEPLOYING YOUR WEB APPLICATIONS INSTALLING A SERVICE RELEASE UPGRADING TO VERSION 2.0 Requirements Installation Steps CONVERTING FROM TRIAL VERSION TO PAID VERSION CONVERTING FROM ASP.NET 1.X TO ASP.NET 2.0 Installation Steps Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com 4 5 6 7 8 11 11 12 13 15 15 15 17 17 18 18 21 22 25 25 25 32 33 33 Page 2 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide INSTALLING INTO A PARTIAL TRUST ENVIRONMENT TROUBLESHOOTING Common Error Messages Visual Studio Problems TECHNICAL SUPPORT AND OTHER ASSISTANCE

Last Updated: 09/11/2006 Peter Blum 35 36 36 37 38

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 3 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Overview
Peter’s Date Package provides a suite of web controls for the ASP.NET platform. It provides separate assemblies for ASP.Net 1.x (Visual Studio.net 2002-3) and ASP.NET 2.0 (Visual Studio.net 2005) users. This guide provides detailed step-by-step instructions to setting up Peter’s Date Package in a variety of situations:

♦ Installing Peter’s Date Package for the first time. This adds the assembly into the Visual Studio.net toolbox and product
files into your web application. See “First Time Installation”.

♦ Installing Peter’s Date Package into a web application. Similar to above, except it does not have you add the controls into
the Visual Studio.net toolbox. See “Installing Peter’s Date Package Into Your Web Applications”. Installing a service release. See “Installing a Service Release”. Upgrading from Peter’s Date Package version 1.x. See “Upgrading to Version 2.0”. Installing a purchased product over the Trial Version. See “Converting from Trial Version To Paid Version”. Installing ASP.NET 2.0 into a web site that uses ASP.NET 1.1. See “Converting from ASP.NET 1.x to ASP.NET 2.0”. Setup your Licenses. See “Installing Licenses”. Deploying Peter’s Date Package to another server. See “Deploying Your Web Applications”. Installing into an ASP.NET web application that has partial trust security limitations. See “Installing Into A Partial Trust Environment”.

♦ ♦ ♦ ♦ ♦ ♦ ♦

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 4 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

What's Included
When you extracted Peter’s Date Package, it created a folder with a number of files and folders. Here is a description of each file or folder: • • • • • • License Agreement.html – The License Agreement. PLEASE READ IT. Installation Guide.pdf – This file. Users Guide.pdf – The main product documentation. Explains the usage of the controls. Assemblies\ASPNET 1_x – A folder containing the PetersDatePackage.dll and PeterBlum.PDPtoVAM.dll assemblies for ASP.NET 1.0 and ASP.NET 1.1 web sites. Assemblies\ASPNET 2_0 – A folder containing the PetersDatePackage.dll and PeterBlum.PDPtoVAM.dll assemblies for ASP.NET 2.0 web sites. Copy To Web App\PetersDatePackage – A folder containing three folders that, by default, belong in the /aspnet_client/ folder found in your domain root directory or the web application root directory. Note: You may locate its contents in other folders. The “2_0_” folder contains the JavaScript files. The “Appearance” folder contains default Cascading Style Sheet and images. The “Licenses” folder is initially empty and where you add the license file(s) issued to you. For Upgraders – Files to assist in the upgrade process from version 1.x. It includes the document Whats New In Version 2. VAM Style Validators.pdf – Documentation to setup validation using Professional Validation And More.

• •

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 5 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

First Time Installation
Note: If you are updating an existing Peter’s Date Package installation, see “Installing a Service Release” for directions. Only follow these steps on computers and web sites that do not have Peter’s Date Package installed. There are several steps to installing Peter’s Date Package. Here is a “big picture” of the installation process. • • • • Add the controls of Peter’s Date Package into the Visual Studio.Net toolbox. Copy the PetersDatePackage folder into your web application. Add the PetersDatePackage.dll assembly into your web application, either in the \bin folder or the Global Assembly Cache. Setup your Peter’s Date Package license(s).

Each of these actions is described in detail in the following sections. Note: Many custom controls are installed more quickly than Peter’s Date Package. That’s because you only have an assembly to put in the \bin folder and add to the Visual Studio.net Toolbox. Peter’s Date Package includes client-side scripts, images, and style sheets, which needs to be deployed into your web application. In addition, you must setup the product license, which includes one or more license files and a License Key. These steps ask you jump around the document using clicks on links. Adobe Reader offers a Previous View command to return to the link. Look for this in the Adobe Reader (shown v6.0):

Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. 1. Add the PetersDatePackage.dll to the Visual Studio.net toolbox. Suggestion: Create a new tab called “Peters Date Package”. • • Visual Studio.Net 2002/3 users will find PetersDatePackage.dll in [ProductFolder]\Assemblies\ASPNET 1_x. Visual Studio 2005 users will find PetersDatePackage.dll in [ProductFolder]\Assemblies\ASPNET 2_0.

If you need detailed steps, see “Installing Peter’s Date Package Into Visual Studio.net”. 2. Follow the steps in the section “Installing Peter’s Date Package Into Your Web Applications”.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 6 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Installing Peter’s Date Package Into Visual Studio.net
If you are using Visual Studio.net (all versions including Express), add the controls from the PetersDatePackage.dll assembly into the Visual Studio.net toolbox. It is recommended that you create a new tab in the toolbox called “Peter’s Date Package”. The steps follow: Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. 1. 2. 3. 4. Open the Toolbox view. (View; Toolbox) Right click in the Toolbox view and choose Add Tab. Name the tab “Peter’s Date Package”. Right click in the Toolbox view inside the new tab area. Then select the right command: • • • 5. 6. VS.net 2002 – Select Customize Toolbox VS.net 2003 – Select Add/Remove Toolbox Items VS2005 and Express editions – Choose Items

Select the .Net Framework Components tab. Click Browse and select the PetersDatePackage.dll. • • Visual Studio.Net 2002/3 users will find it in [ProductFolder]\Assemblies\ASPNET 1_x. Visual Studio 2005 users will find it in [ProductFolder]\Assemblies\ASPNET 2_0.

7.

Click OK. A large number of controls are added.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 7 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Installing Peter’s Date Package Into Your Web Applications
Since you already have access to this Installation Guide, you have successfully installed the files of this product onto your hard disk. However, they have not been added into any of your web application projects. These instructions are intended to add Peter’s Date Package for the first time to a web application. If you are updating an existing site, please go to “Installing a Service Release”, “Upgrading to Version 2.0”, “Converting from Trial Version To Paid Version”, or “Converting from ASP.NET 1.x to ASP.NET 2.0”. These steps ask you jump around the document using clicks on links. Adobe Reader offers a Previous View command to return to the link. Look for this in the Adobe Reader (shown v6.0):

Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. Abbreviated Instructions The abbreviated instructions are designed for the more experienced ASP.NET user who will use the default location for the image, style sheet, scripts, and license files. They omit available installation options and step-by-step guidance. See the Detailed Instructions below if you have any concerns. 1. Copy the [ProductFolder]\Copy to Web App\PetersDatePackage folder to your web application into the \aspnet_client folder (recommended for ASP.NET 1.x users) or the web application root folder (recommended for ASP.NET 2.0 users). See step 1 in the “Detailed Instructions”. Add the [ProductFolder]\Assemblies\PetersDatePackage.dll assembly into your web application. If you are using Visual Studio.net, add a reference to it in your web application project. See steps 2 (for Global Assembly Cache) or 3 (for \bin folder installation) in the “Detailed Instructions”. Setup the licenses. You will be adding license file(s) and a line of code called the License Key to your app. Always follow the instructions of “Installing Licenses”.

2.

3.

Detailed Instructions 1. Copy the PetersDatePackage folder, located in the [ProductFolder]\Copy To Web App folder, to your web application. There are several possible locations for the PetersDatePackage folder. • • • In the \aspnet_client folder. This is recommended for ASP.NET 1.x/Visual Studio.net 2002-2003 users. See “aspnet_client Folder: Recommended for ASP.NET 1.x Users”. In the web application’s root folder. This is recommended for ASP.NET 2.0/Visual Studio.net 2005 users. See “Web Application Root Folder: Recommended for ASP.NET 2.0 Users”. The PetersDatePackage folder or its subfolders can be located anywhere you like so long as the files are accessible to your web application and web server. For example, when you prefer putting all of the graphics and style sheets into a folder called Images. See “Put Folders in your Preferred Locations”.

aspnet_client Folder: Recommended for ASP.NET 1.x Users ALERT: Visual Studio.net 2005 users who run their web application inside the ASP.NET Development Server (instead of IIS) cannot use this solution. The ASP.NET Development Server does not support the domain root folder. The recommended location is the [domain root]\aspnet_client folder. [domain root] refers to the folder that contains the domain name of the site on your server. For example, the domain http://localhost is usually in C:\inetpub\wwwroot.

♦ If the aspnet_client folder does not exist in your domain, create it first. Note: ASP.NET 1.x users should have this
folder defined. If its not there, it also means your client-side validation and SmartNavigation scripts are not installed. See the first topic of this article to learn how to get those scripts installed: aspalliance.com/699. Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com Page 8 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide ♦ Copy the PetersDatePackage folder into the [domain root]\aspnet_client folder. This should result in these three paths:

Last Updated: 09/11/2006 Peter Blum

[domain root]\aspnet_client\PetersDatePackage\2_0_[uniqueversion] [domain root]\aspnet_client\PetersDatePackage\Appearance [domain root]\aspnet_client\PetersDatePackage\Licenses Web Application Root Folder: Recommended for ASP.NET 2.0 Users The [web application root] is the folder that contains the web application on your server. This is the same folder that contains the web.config file and the \bin folder. When using IIS, the domain http://localhost is usually refers to C:\inetpub\wwwroot. Web applications are usually in a subfolder. For example, the web app “MyWebApp” is in C:\inetpub\wwwroot\MyWebApp. When using Visual Studio.net 2005’s ASP.NET Development Server, it is usually [My Documents]\Visual Studio 2005\Websites\[MyWebApp]. For example, the web app “MyWebApp” could be in C:\documents and settings\user name\my documents\Visual Studio 2005 \Websites\MyWebApp. ALERT: ASP.NET 1.x users will not see the images of these controls in design mode when using this technique. The images will only be visible at runtime. ASP.NET 2.0 users will see the images both at design and runtime by using the ASP.NET 2.0 enhanced PetersDatePackage.dll assembly described in step 2.

♦ Copy the PetersDatePackage folder into the [web application root].
This should result in these three paths: [web application root]\PetersDatePackage\2_0_[uniqueversion] [web application root]\PetersDatePackage\Appearance [web application root]\PetersDatePackage\Licenses Put Folders in your Preferred Locations If your web application contains special folders for all of your scripts, images, and licenses, you can move some or all of the contents of the PetersDatePackage folder into those locations. You have to tell Peter’s Date Package where to locate them by entering lines to the <appSettings> section of your web.config file.

♦ See “Using Alternative Locations for Folders”.
2. If you prefer to use the Global Assembly Cache (GAC), add the PetersDatePackage.dll assembly to the GAC. Otherwise, skip to step 3. Note: It is not necessary to use the GAC. Each web application can include assemblies in its \bin folder. For ASP.NET 1.x users, PetersDatePackage.dll is located in the [ProductFolder]\Assemblies\ASPNET 1_x folder. For ASP.NET 2.0 users, PetersDatePackage.dll is located in the [ProductFolder]\Assemblies\ASPNET 2_0 folder. You can use the Windows Explorer to copy them into the C:\[Windows]\Assemblies folder or the gacutil.exe program supplied with the .net framework.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 9 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide 3. Add the PetersDatePackage.dll assembly to your web application.

Last Updated: 09/11/2006 Peter Blum

Visual Studio.Net 2002 and 2003 Users Use the Add Reference command on your web application project. Locate the PetersDatePackage.dll assembly in the [ProductFolder]\Assemblies\ASPNET 1_x folder. The Add Reference command will automatically copy the assembly into the web application’s \bin folder for you unless you are using the GAC. If you use the Global Assembly Cache, the Add Reference command recognizes an assembly that is already in the GAC and avoids copying it into the \bin folder. After setting up the reference, be sure the \bin folder does not contain these files. In addition, go to Solution Explorer, select the Reference, right click, and choose Properties. The property CopyLocal should be false. Visual Studio.Net 2005 Users (Including Express Editions) WARNING: These assemblies are compiled with the production release of Visual Studio 2005. Do not use them with prerelease versions of ASP.NET 2.0 or VS2005. Use the Add Reference command on your web application project. Locate the PetersDatePackage.dll assembly in the [ProductFolder]\Assemblies\ASPNET 2_0 folder. If you use the Global Assembly Cache, the Add Reference command recognizes an assembly that is already in the GAC and avoids copying it into the \bin folder. All Other Development Platforms If you are not using the Global Assembly Cache, copy the PetersDatePackage.dll assembly into your web application’s \bin folder. (When using the GAC, you do not have to do anything more.) For ASP.NET 1.x users, PetersDatePackage.dll is located in the [ProductFolder]\Assemblies\ASPNET 1_x folder. For ASP.NET 2.0 users, PetersDatePackage.dll is located in the [ProductFolder]\Assemblies\ASPNET 2_0 folder. 4. These controls do not operate without license files properly installed. Install them now.

♦ See “Installing Licenses”.
ALERT: In addition to adding the license file(s), you will be adding a line of code to your web application called the License Key. Please follow the instructions in the “Installing Licenses” section to do this correctly. 5. ASP.NET 2.0 assembly users can use the <controls> section of web.config to avoid typing in the <% @Register %> tag to an assembly. You can use this for Peter’s Date Package: <configuration> <system.web> <pages> <controls> <add tagPrefix="Date" namespace="PeterBlum.PetersDatePackage" assembly="PetersDatePackage" /> </controls> </pages> </system.web> </configuration> Note: The web.config file is case sensitive.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 10 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Using Alternative Locations for Folders
The PetersDatePackage folder contains these three subfolders: • • 2_0_# – A folder that contains the javascript files. The folder’s name is designed to match the product version number. See “Scripts Folder (2_0_#)”. Appearance – A folder containing the Cascading Style Sheet files and numerous graphic files. All of these are used by the default configurations of the Peter’s Date Package controls. You can edit them directly or copy them and reassign various properties on the controls to point to the relocated files. See “Appearance Folder”. WARNING: If you edit these files within the Appearance folder, do not copy over them as you get updates. Licenses – A folder where you place the license files. See “Licenses Folder”.

You can locate the folders or their contents anywhere you want. You can leave some in their default location, [domain root]\aspnet_client\petersdatepackage or [web application root]\petersdatepackage. Any that you put other locations must be identified in the <appSettings> section of the web.config file as described here.

Scripts Folder (2_0_#)
Always put the scripts in a folder that is a child of your web site so that a browser can retrieve it with a simple URL like “/Scripts/2_0_0/PDP_Globals.js”. A recommendation is to keep Peter’s Date Package scripts inside its 2_0_# folder, perhaps as a subfolder to where you keep your scripts. This will help you manage product updates. Here is the recommended path: [your scripts folder]\PetersDatePackage\2_0_# Once you copy the 2_0_# folder into your web application, set up the PDP_ScriptVirtualPath key in <appSettings> to supply the URL that the browser will use to locate these files. The URL should be to the folder containing the script files. <configuration> <appSettings > <add key="PDP_ScriptVirtualPath" value="[url]" /> </appSettings> </configuration> Note: The tag and attribute names of the web.config file are case sensitive. • You can start the URL with the special character “~” (tilde) to let ASP.NET determine the web application root folder. For example, if you put the scripts into the Scripts/PetersDatePackage folder which is just under the web application root: <add key="PDP_ScriptVirtualPath" value="~/Scripts/PetersDatePackage/" /> • If you want to preserve the version number folder under your scripts folder, place the token “{VERSION}” into the string like this: “~/Scripts/PetersDatePackage/{VERSION}”. When you omit the {VERSION} token, the scripts should be placed into the exact path you give. For example: <add key="PDP_ScriptVirtualPath" value="~/Scripts/PetersDatePackage/{VERSION}" /> Example: Using the Recommended Path Suppose your scripts are located in the Scripts folder, immediately under the web application root folder. The recommended path will use a URL as shown here: <configuration> <appSettings > <add key="PDP_ScriptVirtualPath" value="~/Scripts/PetersDatePackage/{VERSION}" /> </appSettings> </configuration>

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 11 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Appearance Folder
Always put the contents of the Appearance folder in a folder that is a child of your web site so that a browser can retrieve it with a simple URL like “/Images/PetersDatePackage/Calendar.jpg”. Note: The Appearance folder contains the style sheet files. ASP.NET 2.0 users will find that the automatic setup of <link> tags will continue to work so long as the style sheet files remain in the Appearance folder. Otherwise, setup the web.config keys described in “Moving the Style Sheet Files out of the Appearance folder” below. Here is the recommended path: [your images folder]\PetersDatePackage\ Once you copy the contents of the Appearance folder into your web application, set up the PDP_AppearanceVirtualPath key in <appSettings> to supply the URL that the browser will use to locate these files. <configuration> <appSettings > <add key="PDP_AppearanceVirtualPath" value="[url]" /> </appSettings> </configuration> Note: The tag and attribute names of the web.config file are case sensitive. Note: Visual Studio.net 2005 should be restarted to reflect web.config file changes in design mode. Note: Visual Studio.net 2002 and 2003 users will not see the affect of the web.config file settings in design mode. You should expect to see the symbol: . Visual Studio.net 2005 users should see images in design mode due to enhancements in VS.NET 2005 that allow reading the web.config file from design mode. • You can start the URL with the special character “~” (tilde) to let ASP.NET determine the web application root folder. For example, if you put the scripts into the Images/PetersDatePackage folder which is just under the web application root: <add key="PDP_AppearanceVirtualPath" value="~/Images/PetersDatePackage/" /> • URLs to images are all exposed in properties throughout these controls. For example, the property for the calendar icon on the DateTextBox is in DateTextBox.xPopupCalendar.xToggleImageUrl. Any property that contains a URL which starts with “\aspnet_client\petersdatepackage\appearance\” (case insensitive) will automatically have its string updated with the path you define in the PDP_AppearanceVirtualPath key.

Example: Using the Recommended Path Suppose your images are located in the Images folder, immediately under the web application root folder. The recommended path will use a URL as shown here: <configuration> <appSettings > <add key="PDP_AppearanceVirtualPath" value="~/Images/PetersDatePackage/" /> </appSettings> </configuration> Moving the Style Sheet Files out of the Appearance folder Peter’s Date Package uses style sheet files to provide formatting to its controls. The files default to the Appearance folder. You can move the files to another location. If you do, you will need to add the following keys into your <appSettings>.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 12 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide <configuration> <appSettings > <add key="PDP_StyleSheetDateTextBox" value="[url]/DateTextBox.css" /> <add key="PDP_StyleSheetTimeTextBox" value="[url]/TimeTextBox.css" /> <add key="PDP_StyleSheetCalendar" value="[url]/Calendar.css" /> <add key="PDP_StyleSheetMultiSelectionCalendar" value="[url]/MultiSelectionCalendar.css" /> <add key="PDP_StyleSheetSpecialDates" value="[url]/SpecialDates.css" /> <add key="PDP_StyleSheetMonthYearPicker" value="[url]/MonthYearPicker.css" /> <add key="PDP_StyleSheetTimePicker" value="[url]/TimePicker.css" /> <add key="PDP_StyleSheetContextMenu" value="[url]/ContextMenu.css” /> </appSettings> </configuration> The value of “[url]” must be replaced by the URL to the folder. Note: The tag and attribute names of the web.config file are case sensitive.

Last Updated: 09/11/2006 Peter Blum

Licenses Folder
If you keep product license files in a standard folder, do not mix license files from Peter’s Date Package with other products. Instead, create a sub folder called PetersDatePackage where its license files go. The ASP.NET server must be able to open the files contained in this folder. So give your Windows NT user account used by ASP.NET rights to the folder with the license files. Here is the recommended path: [your licenses folder]\PetersDatePackage\ Once you create a folder for licenses, set up either the PDP_LicenseVirtualPath or PDP_LicenseFilePath keys in <appSettings>. • PDP_LicenseVirtualPath – The value is the virtual path to the Licenses folder, which contains your license files. ASP.NET 2.0 users must use the tilde (~) notation, as described in the note below. This string cannot start with a lead slash. <configuration> <appSettings > <add key="PDP_LicenseVirtualPath" value="[url]" /> </appSettings> </configuration> You can start the URL with the special character “~” (tilde) to let ASP.NET determine the web application root folder. For example, if you put the licenses into the Licenses/PetersDatePackage folder which is just under the web application root:

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 13 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum <add key="PDP_LicenseVirtualPath" value="~/Licenses/PetersDatePackage/" /> • PDP_LicenseFilePath – This is an alternative to PDP_LicenseVirtualPath. It provides a real file path (C:\folder\folder2) to the Licenses folder. Be careful. When you deploy the web.config file to a new location, this file path may not match. So update it at deployment time. Remember that your web server Windows NT account must have network rights to read from the folder specified here. <configuration> <appSettings > <add key="PDP_LicenseFilePath" value="[url]" /> </appSettings> </configuration> Note: The tag and attribute names of the web.config file are case sensitive.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 14 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Installing Licenses
When you downloaded the product, you should have received one or more License Files. You also received a serial number if you purchased a license. (The Trial Version doesn’t issue a serial number.) There are two actions to get license files to work: • • Place the License Files into the \Licenses folder on each web server. Setup the License Key global variable in Application_Start() or Page_Load() methods. Trial version users do not take this action.

The following sections are instructions for each license type.
Click on your license type for instructions:

♦ ♦ ♦ ♦

Trial License Web Server Licenses Site License Redistribution License

Trial License
The Trial License gives you a 30 day time limit to evaluate Peter’s Date Package. 1. Place the license file PDP2 Trial expires on yyyy-mm-dd.lic into the Peter’s Date Package Licenses folder (default location is [domainroot]\aspnet_client\PetersDatePackage\Licenses or [web application root]\PetersDatePackage\Licenses). Recommended only for non-production servers (development, testing, and staging).You can put it on production (live) servers so long as you accept the limitations. That’s it.

2.

Runtime Limitations: Allows only the first 15 computers to access Peter’s Date Package controls; expires 30 days after you requested it.

Web Server Licenses
Web Server Licenses come with two types of files: PDP2 Development.lic and PDP2 SingleServer####.lic. You must have one PDP2 SingleServer####.lic for each production server. PDP2 Development.lic is used on unlimited nonproduction servers. If you have purchased more than one Web Server License, you will have several PDP2 SingleServer####.lic files. You will only have one PDP2 Development.lic. Note: Visual Studio 2005 users who intend to use the Publish Web Site command should see this troubleshooting topic first. 1. Place the license files PDP2 Development.lic and all PDP2 SingleServer####.lic into the Peter’s Date Package Licenses folder (default location is [domainroot]\aspnet_client\PetersDatePackage\Licenses or [web application root]\PetersDatePackage\Licenses). Gather the product serial numbers from the emails containing the PDP2 SingleServer####.lic files. You should have one for each Web Server License purchased. Gather the computer names of each production server. On Windows NT and XP, it is available on the System control panel under the “Computer Name” tab. If you are using a hosted server, email support@PeterBlum.com to request an easy way to get the computer name for the Web Server License. (While you wait, you can use a temporary name so that you can move forward. Your license will work on nonproduction servers.) Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com Page 15 of 38 For technical support and other assistance, see page 38

2. 3.

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum HINT: The most common error users make is to get the wrong computer name. Often they use a domain name or change the computer. Neither will match to the computer name. Note: If you do not know the name of the production server at this time, use a fake name. Perhaps one to remind you to fill it in later like “AssignToProductionServerName”. Remember to update this prior to deploying to production. 4. 5. Open your web application’s Global.asax file to its code view. (In Visual Studio.net, this is the code behind file: Global.asax.cs or Global.asax.vb) Locate the Application_Start()method. If your Global.asax file contains the method Application_OnStart(), see “Application_Start vs Application_OnStart”. If it is missing, add it like this: [C#] protected void Application_Start(Object sender, EventArgs e) { } [VB] Sub Application_Start(ByVal sender As Object, ByVal e As EventArgs) End Sub 6. Determine your License Key. It will be used in Application_Start() in the next step. • For one Web Server License, it is this format: serialnumber|computername A pipe character separates the two. For example, the serial number is 999-111222333 and computer name is “MarsServer”: 999-111222333|MarsServer • For two to four Web Server Licenses, it is this format: serialnumber|computername;serialnumber2|computername2;serialnumber3|comput ername3;serialnumber4|computername4 The delimiter after the serial number is a pipe (“|”). The delimiter after the computer name is a semi-colon (“;”) You can put serial numbers and computer names in any order so long as each serial number and computername is unique. For example, with 3 Web Server licenses: 999-1100000001|MarsServer;999-1100000002|JupiterServer; 9991100000003|SaturnServer • For five Web Server Licenses, you are granted a Site License. Your License Key is one serial number (no computer name either). You can pick any serial number of the 5.

Peter’s Date Package selects which of the license files will be active based on the License Key. It locates a serial number by matching the computer name to the names you’ve entered. With that serial number, it looks through your PDP2 SingleServer####.lic files to find a match. If there was no matching computer name, it uses PDP2 Development.lic. PDP2 Development.lic allows only the first 15 computers to access Peter’s Date Package controls as its designed for non-production computers. 7. Add a line to Application_Start() that assigns your License Key to PeterBlum.PetersDatePackage.Globals.LicenseKey. PeterBlum.PetersDatePackage.Globals.LicenseKey = "License Key" For example, the serial number is 999-111222333 and computer name is “MarsServer”: PeterBlum.PetersDatePackage.Globals.LicenseKey = "999-111222333|MarsServer" Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com Page 16 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide 8. Restart your web application so it reruns the Application_Start() method.

Last Updated: 09/11/2006 Peter Blum

Please see “Troubleshooting Licenses” if you receive licensing exception errors when you access a page that uses Peter’s Date Package controls.

Site License
The Site License provides a single license file with this name: PDP2 Site####.lic. It can be used on unlimited production and non-production servers as described in the License Agreement. Note: Visual Studio 2005 users who intend to use the Publish Web Site command should see this troubleshooting topic first. 1. Place the license file PDP2 Site####.lic into the Peter’s Date Package Licenses folder (default location is [domainroot]\aspnet_client\PetersDatePackage\Licenses or [web application root]\PetersDatePackage\Licenses). Gather the product serial number from the email containing the PDP2 Site####.lic file. Open your web application’s Global.asax file to its code view. (In Visual Studio.net, this is the code behind file: Global.asax.cs or Global.asax.vb) Locate the Application_Start()method. If your Global.asax file contains the method Application_OnStart(), see “Application_Start vs Application_OnStart”. If it is missing, add it like this: [C#] protected void Application_Start(Object sender, EventArgs e) { } [VB] Sub Application_Start(ByVal sender As Object, ByVal e As EventArgs) End Sub 5. Add a line to Application_Start() that assigns your serial number to PeterBlum.PetersDatePackage.Globals.LicenseKey. This is called the License Key. PeterBlum.PetersDatePackage.Globals.LicenseKey = "serialnumber" For example, the serial number is 999-111222333: PeterBlum.PetersDatePackage.Globals.LicenseKey = "999-111222333" 6. Restart your web application so it reruns the Application_Start() method.

2. 3. 4.

Please see “Troubleshooting Licenses” if you receive licensing exception errors when you access a page that uses Peter’s Date Package controls.

Redistribution License
The Redistribution License provides a single license file with this name: PDP2 R####.lic. It can be used on unlimited production and non-production servers as described in the License Agreement. Note: Visual Studio 2005 users who intend to use the Publish Web Site command should see this troubleshooting topic first. 1. Place the license file PDP2 R####.lic into the Peter’s Date Package Licenses folder (default location is [domainroot]\aspnet_client\PetersDatePackage\Licenses or [web application root]\PetersDatePackage\Licenses). Gather the product serial number from the email containing the PDP2 R####.lic file.

2.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 17 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum 3. Each web form or user control that uses Peter’s Date Package must add the License Key to the Page_Load() method. Add a line to Page_Load() that assigns your serial number to PeterBlum.PetersDatePackage.Globals.Page.LicenseKey. PeterBlum.PetersDatePackage.Globals.Page.LicenseKey = "serialnumber" For example, the serial number is 999-111222333: PeterBlum.PetersDatePackage.Globals.Page.LicenseKey = "999-111222333" Note: When adding Peter’s Date Package controls to a page for the first time, the steps to add a Peter’s Date Package control remind you to do this. 4. Restart your web application so it reruns the Application_Start() method.

Please see “Troubleshooting Licenses” if you receive licensing exception errors when you access a page that uses Peter’s Date Package controls.

Application_Start vs Application_OnStart
The .net framework defines two method names that can initialize your application within the Global.asax file: Application_Start() and Application_OnStart(). Your web application may be using either but cannot use both. This documentation will always refer to Application_Start(). You should substitute Application_OnStart if that is the method name you have defined in Global.asax.

Troubleshooting Licenses
If you run into errors when the page is rendered, the error message should direct you to the problem. See “Licensing Error Messages” for more. There are two steps to setting up the licenses correctly: 1. Add the license files to the Peter’s Date Package Licenses folder. • • • ASP.NET 1.x users usually use [domain root]\aspnet_client\PetersDatePackage\Licenses ASP.NET 2.0 users usually use [web application root]\PetersDatePackage\Licenses If you have overridden the location of where the licenses are, see the <appSettings> section of the web.config file as described in “Licenses Folder”. Omitting a license file. If you are missing a license file, visit http://www.peterblum.com/LicensedDownloads/RetrieveLicense.aspx to get a new copy. Placing the file in the wrong folder.

Common errors in this step include: • • 2.

Assign the License Key to the PeterBlum.PetersDatePackage.Globals.LicenseKey property. Common errors in this step include: • • With a Web Server license, using the computer name of a non-production server in the License Key. It must be the name of the production server. With a Web Server license, getting the wrong text for the computer name in the License Key. For example, the domain name. The software checks the computer name by checking the property System.Environment.MachineName. You may want to test this property yourself to get the string. Application_Start() is not being called when your application starts. Usually this is because the Global.asax file has not been deployed. ASP.NET depends on this file to be present before it runs any methods in the Global class (which includes Application_Start.) If this fails to solve the problem, tech support recommends this solution:

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 18 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum Copy the License Key code from Application_Start() into the Page_Load() of a page that is using Peter’s Date Package controls. Compile and test that page. If it works, Application_Start() is broken. Repeat copying the License Keys into all page’s Page_Load() methods that use Peter’s Date Package controls. ASP.NET 2.0 users sometimes have this problem because the code behind file (Global.asax.vb or Global.asax.cs) that was created in ASP.NET 1.x was moved into the App_Code folder during the upgrade to 2.0. Move that file into the [web application folder]. • • • • Leaving the PeterBlum.PetersDatePackage.Globals.LicenseKey property blank. (It should only be blank for the Trial version.) Forgetting to compile your web application (specifically the Global.asax file) so that changes are reflected in the web application. Forgetting to deploy the assembly containing your web application. Not restarting the web application. With a Redistribution license, forgetting to assign the License Key to PeterBlum.PetersDatePackage.Globals.Page.LicenseKey property in the Page_Load() method in each page that uses these controls or forgetting to compile. You added the Application_Start() method to your Global.asax file when it already includes the Application_OnStart() method. ASP.NET only runs Application_OnStart() when both are defined. So move the contents of Application_Start() into Application_OnStart().

Licensing Error Messages
Here are the error messages you may encounter and how to resolve them. If a problem is related to a licensing file, identify the server that generated the error first. Errors may be specific to a server. Don’t forget that after you change the contents of the Licenses folder, you must wait 1 minute (after an error message) for the cache to clear or restart the web application. Could not match the License Key [key] to the Peter's Date Package license files found in [path] The value of PeterBlum.PetersDatePackage.Globals.LicenseKey or PeterBlum.PetersDatePackage.Globals.Page.LicenseKey does not match to the license files found in the file path. See the two steps of “Troubleshooting Licenses”, above. Your Peter’s Date Package non-production server license [path] has reached its limit of 15 unique IP Addresses accessing it. The PeterBlum.PetersDatePackage.Globals.LicenseKey property matched to a Trial or Development license file. Both of these files impose a limit of 15 unique browser IP Addresses as they are intended for internal development and product evaluation. The first 15 IP addresses are cached. Your options are: • If you are using a Web Server license, the License Key string contains the wrong computer name. In Global.asax, locate Application_Start() and review the License Keys. Correct any that are not using a production server’s computer name. Recompile and deploy. If you are running the Trial version, do not run it on a server that has published your site.

When a page uses a Trial or Development license, it will add this text near the </form> tag: <!-- PDPLIC:TRIAL or DEVELOPMENT --> When determining if you fixed the problem, view the HTML source of the page to see this tag. If it is missing or the module with the error is not shown, the license has been corrected for use on production servers. Access to the path "filepath" is denied. While the license file may be completely accessible to your IIS Web Server, when Peter’s Date Package must read from the file, it must go through the Windows operating system to open the file. Windows has its own security restrictions on files and folders. Make sure the web application has Windows operating system rights to read files from the given filepath.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 19 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum The file path [filepath] could not be found You are missing the Licenses folder within the [domain root]\aspnet_client\PetersDatePackage\ folder, the [web application root]\PetersDatePackage\ folder, or the folder specified by the web.config file in the PDP_LicenseFilePath or PDP_LicenseVirtualPath keys of <AppSettings>. See “Using Alternative Locations for Folders”. The License Key string contains duplicate serial numbers. It must contain serial numbers. When you have multiple serial numbers in the PeterBlum.PetersDatePackage.Globals.LicenseKey property, if there are any duplicates, this error occurs. The serial number [serial number] matched to a Web Server license. A Web Server license requires the registration code to be followed by '|' and the computer name that runs the web server for this license. Please add it. The serial number is associated with a Web Server license. You have not provided the computer name in the LicenseKey property. Please see step 2 of “Troubleshooting Licenses”. The Peter's Date Package License expired on [date] Your Trial version license has expired. Please visit www.PeterBlum.com to order the product. More than one license file contains the same serial number. All license files must have unique serial numbers. One of the license files was copied and that copy is in the Licenses folder. For example, “Copy of Site###.lic”. Do not keep any copied license files in the Licenses folder.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 20 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Deploying Your Web Applications
Peter’s Date Package installs several files into your web application. The following is a checklist of the files that you must install when you deploy to another computer. Filename PetersDatePackage.dll Location Comments [web application root]\bin It can also be installed into the Global Assembly Cache. ALERT: If your destination server is using a Partial Trust Environment (with security restrictions such as on a hosted server), see “Installing Into A Partial Trust Environment”. [web application root]\bin Only when using Professional Validation And More validation. In the corresponding location on the other server. By default, it is in [domain root]\aspnet_client\ or the [web application root]. Copy the entire folder. It contains the JavaScript code, Appearance folder with images and style sheets, and License folder with your existing licenses. If you have moved individual subfolders out from under the PetersDatePackage folder, relocate them to their corresponding location. For details, see “Using Alternative Locations for Folders”. Your license files should already be established in the Licenses folder. Your development efforts should have already tested them. If you have a Web Server license, the software will now switch from using the PDP2 Development.lic file to the PDP2 SingleServer###.lic files. Often users find they have not entered the correct License Key with an error in the serial number or computer name. So review the License Key in the Application_Start() method of Global.asax. See “Installing Licenses”. If there are license errors, please see “Troubleshooting Licenses”. Note: Visual Studio 2005 users who intend to use the Publish Web Site command should see this troubleshooting topic first. This file contains the Application_Start() method that you modified for Web Server and Site Licenses. Application_Start() does not run unless the Global.asax file is present.

PeterBlum.PDPtoVAM.dll PetersDatePackage folder

Licenses

Global.asax

In addition, URLs and file paths may change between servers. Please consider these potential issues: • You may have set some parameters in the web.config file that point to files and URLs within Peter’s Date Package. Be sure they are correctly transferred into the web.config file in the new computer. See “Using Alternative Locations for Folders”. If your web pages have a <link> tag to the style sheet file(s) containing Peter’s Date Package styles, confirm that the href parameter is correct for the new server. Note: ASP.NET 2.0 users may have overridden this to setup <link> tags automatically.

If you are having problems, please see the “Troubleshooting” section.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 21 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Installing a Service Release
Use these instructions if you are installing a service releases (v2.0.x → 2.0.y). Warning: If you are using Professional Validation And More with Peter’s Date Package, this service release requires Professional Validation And More v3.0.4 or higher. Please be sure the you have VAM 3.0.4 installed and working prior to installing this service release. You can get it from http://www.peterblum.com/vam/home.aspx. Click “Get This Update” and follow the directions. Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. The term [domain root] refers to the folder that contains the domain name of the site on your server. For example, the domain http://localhost is usually in C:\inetpub\wwwroot. The term [web application root] refers to the folder that contains the web application on your server. It contains the \bin folder and web.config file. Abbreviated Instructions The abbreviated instructions are designed for the more experienced ASP.NET user. They omit available installation options and step-by-step guidance. See the Detailed Instructions below if you have any concerns. 1. Copy the [ProductFolder]\Copy to Web App\PetersDatePackage\2_0_0 folder to your web application into the \aspnet_client\PetersDatePackage folder (recommended for ASP.NET 1.x users) or the [web application root]\PetersDatePackage folder (recommended for ASP.NET 2.0 users). See step 1 in the “Detailed Instructions”. Replace the PetersDatePackage.dll assembly in your web application. The new assembly is in [ProductFolder]\Assemblies\ASPNET [version]. If you are using Visual Studio.net, remove the old reference first. Then Add a reference to it in your web application project. See step 2 in the “Detailed Instructions”. If you are using Professional Validation And More to validate Peter’s Date Package controls, replace the PeterBlum.PDPtoVAM.dll in your web application. The new assembly is in [ProductFolder]\Assemblies\ASPNET [version]. If you are using Visual Studio.net, remove the old reference first. Then Add a reference to it in your web application project. See step 3 in the “Detailed Instructions”.

2.

3.

Detailed Instructions 1. Copy the new scripts folder into your web application: a. b. In Windows Explorer, open the [ProductFolder]\aspnet_client\PetersDatePackage folder. Copy the folder starting with 2_0_0 into the PetersDatePackage folder found in one of these locations: • [domain root]\aspnet_client\PetersDatePackage\ (Typically used by ASP.NET 1.x users) For example: c:\inetpub\wwwroot\aspnet_client\PetersDatePackage\2_0_0 • [web application root]\PetersDatePackage\ (Typically used by ASP.NET 2.0 users) An example when using IIS: c:\inetpub\wwwroot\MyWebApp\PetersDatePackage\2_0_0 An example when using the ASP.NET Development Server: C:\documents and settings\user name\my documents\Visual Studio 2005 \Websites\MyWebApp\PetersDatePackage\2_0_0 • If you have not used one of the previous locations, see the <appSettings> section of the web.config file for a key that looks like this: Page 22 of 38 For technical support and other assistance, see page 38

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Peter's Date Package v2.0 Installation Guide <add key="PDP_ScriptVirtualPath" value="URL" /> Use that Url to locate the correct folder.

Last Updated: 09/11/2006 Peter Blum

Suggestion: If the PDP_ScriptVirtualPath key is listed with a version number shown, change the version number to the text “{VERSION}”. For example, here is the original text for v2.0.1: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/2.0.1" /> Here is the updated key: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/{VERSION}" /> Note: There may be other folders that start with 1_1 or 2_0 from earlier releases. You can delete the older folders later or leave them alone as they do not interfere with this new release. 2. Install the PetersDatePackage.dll assembly either into the web application’s \bin folder or the Global Assembly Cache (GAC). ASP.NET 1.x users will find assemblies in [ProductFolder]\Assemblies\ASPNET 1_x ASP.NET 2.0 users will find assemblies in [ProductFolder]\Assemblies\ASPNET 2_0 WARNING: The ASP.NET 2.0 assemblies are compiled with the production release of Visual Studio 2005. Do not use them with any prerelease version of ASP.NET 2.0 or Visual Studio 2005. Using the \bin folder Directions depend on your development platform:

♦ Visual Studio.Net 2002/2003:
a. b. c. a. b. c. d. • Open your project. Remove your existing project Reference to PetersDatePackage.dll. Add a new Reference to PetersDatePackage.dll. Open your project. In Solution Explorer, right click on the web application project heading and choose Property Pages. Use the dialog box to remove your existing reference to PetersDatePackage.dll. Add a new reference to this version’s PetersDatePackage.dll. Copy PetersDatePackage.dll into the web application’s \bin folder.

♦ Visual Studio 2005:

♦ Not using Visual Studio:
Using the Global Assembly Cache a. Remove the existing PetersDatePackage.dll file from the GAC. b. c. 3. Add the new PetersDatePackage.dll file into the GAC. If your web.config or machine.config file contains an <add assembly> tag to the PetersDatePackage.dll, update the version number to 2.0.1.5000.

If you are using Professional Validation And More with Peter’s Date Package: a. b. Confirm that you have Professional Validation And More v3.0.4 or higher. It cannot be used with an older version. Copy the file PeterBlum.PDPToVAM.dll to your web application’s \bin folder. ASP.NET 1.x users will find assemblies in [ProductFolder]\Assemblies\ASPNET 1_x ASP.NET 2.0 users will find assemblies in [ProductFolder]\Assemblies\ASPNET 2_0

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 23 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide c. If you are using Visual Studio.net, update your project reference to this new assembly.

Last Updated: 09/11/2006 Peter Blum

IMPORTANT: You may have set up your web.config file to include an <assemblyBinding> tag for PeterBlum.VAM.dll. If so, confirm that the <assemblyBinding> tag exactly matches the version of VAM that you are using. VAM includes a file called “Assembly Version Info for the config file.txt” that documents the exact version information. d. e. In a text editor, locate and open custom.VAM.config. It defaults to the [web application root]\VAM folder. Locate the string “PeterBlum.PDPToVAM”. Note: If this string is not found, it indicates that you have not setup Peter’s Date Package to use VAM. You can do that at a later time by following the directions in the VAM Style Validators.pdf supplied with Peter’s Date Package. f. If it reflects a specific version of the assembly, change that version to 2.0.1.5000. <DataType name="PDP:DateTextBox" type="PeterBlum.PDPToVAM.DateTextBoxVAMTypeConverter" assembly="PeterBlum.PDPToVAM, Version=2.0.1.5000, Culture=neutral, PublicKeyToken=7d7808ccfd0d4f9b" /> g. 4. Repeat until all versions have been updated. There are 6 cases.

Recompile your web application and test it. If using Visual Studio.net, use Rebuild Solution.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 24 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Upgrading to Version 2.0
Use these instructions to install an upgrade on a web application currently using Peter’s Date Package version 1.x. For descriptions of the new features in version 2, see [ProductFolder]\For Upgraders\Whats new in Version 2.pdf. Here are the actions involved in an upgrade of a web application.

♦ ♦ ♦ ♦ ♦ ♦ ♦

Setup the new license(s) Add the newest scripts folder Replace the product assemblies Update obsolete properties Change your style sheets Add and update image files Compile and test

Requirements
• This product supports all three ASP.NET versions: 1.0, 1.1, 2.0. It will not support prerelease versions of those platforms. This requirement has not changed from Peter’s Date Package v1.1. It continues to supply separate assemblies for ASP.NET 1.x and 2.0. • This product supports the same browsers it did in v1.1. The details are in the User’s Guide in the “Platform and Browser Support” section. • If you are also using Professional Validation And More, this version is compiled to use the minimum of VAM 3.0.4. This requirement has changed since v1.1, which allowed VAM 2.0.3 for ASP.NET 1.x assemblies. If you are a VAM 3 user, you can retrieve it here: http://www.peterblum.com/vam/home.aspx. Click Get This Update. If you are a VAM 1 or 2 user, visit http://www.peterblum.com/VAM/VAM2Home.aspx to order the upgrade.

Installation Steps
These steps ask you jump around the document using clicks on links. Adobe Reader offers a Previous View command to return to the link. Look for this in the Adobe Reader (shown v6.0):

Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. The term [domain root] refers to the folder that contains the domain name of the site on your server. For example, the domain http://localhost is usually in C:\inetpub\wwwroot. The term [web application root] refers to the folder that contains the web application on your server. It contains the \bin folder and web.config file. 1. Remove license files from the prior version by removing or deleting them from the PetersDatePackage\Licenses folder associated with your web application. You are issued new license files for version 2. Your Licenses folder should only contain a single text file “Add licenses here.txt” or be completely empty. Install the license files and update the License Keys. See “Installing Licenses”. IMPORTANT: Your Application_Start() and Page_Load() methods should no longer contain the properties PeterBlum.PetersDatePackage.Globals.Licensing and PeterBlum.PetersDatePackage.Globals.Page.Licensing. They are replaced by new global properties in PDP 2.0. If you prefer, you can comment them out or delete the code. Application_Start() is located in Global.asax. If you do not, you will receive compiler errors.

2.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 25 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide 3. Copy the new scripts folder into your web application. a. b.

Last Updated: 09/11/2006 Peter Blum

In Windows Explorer, open the [ProductFolder]\Copy To Web App\PetersDatePackage folder. Copy the folder starting with 2_0_0 into the PetersDatePackage folder already installed in one of these locations: • [domain root]\aspnet_client\PetersDatePackage\ (Typically used by ASP.NET 1.x users) For example: c:\inetpub\wwwroot\aspnet_client\PetersDatePackage\2_0_0 • [web application root]\PetersDatePackage\ (Typically used by ASP.NET 2.0 users) An example when using IIS: c:\inetpub\wwwroot\MyWebApp\PetersDatePackage\2_0_0 An example when using the ASP.NET Development Server: C:\documents and settings\user name\my documents\Visual Studio 2005 \Websites\MyWebApp\PetersDatePackage\2_0_0 • If you have not used one of the previous locations, see the <appSettings> section of the web.config file for a key that looks like this: <add key="PDP_ScriptVirtualPath" value="URL" /> Use that URL to locate the correct folder. Suggestion: If the PDP_ScriptVirtualPath key is listed with a version number shown, change the version number to the text “{VERSION}”. For example, here is the original text for v2.0.1: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/2.0.1" /> Here is the updated key: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/{VERSION}" />

Note: There may be other folders that start with 1_1 or 2_0 from earlier releases. You can delete the older folders later or leave them alone as they do not interfere with this new release. 4. Install the PetersDatePackage.dll assembly either into the web application’s \bin folder or the Global Assembly Cache (GAC). ASP.NET 1.x users will find assemblies in [ProductFolder]\Assemblies\ASPNET 1_x ASP.NET 2.0 users will find assemblies in [ProductFolder]\Assemblies\ASPNET 2_0 Using the \bin folder Directions depend on your development platform. ♦ Visual Studio.Net 2002/2003: a. Open your project. b. c. d. e. f. ♦ Remove your existing project Reference to PetersDatePackage.dll. Add a new Reference to PetersDatePackage.dll. Right click on the project node in Solution Explorer and select Properties from the context menu. Select the References Path item. Review the paths shown. If a path is shown that points to the version 1.x assembly folder, delete that line. The list of paths should not refer to a folder that contains version 1.x assemblies.

Visual Studio 2005: a. Open your project. Page 26 of 38 For technical support and other assistance, see page 38

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum b. In Solution Explorer, right click on the web application project heading and choose Property Pages. c. d. ♦ • Use the dialog box to remove your existing reference to PetersDatePackage.dll. Add a new reference to this version’s PetersDatePackage.dll. Copy PetersDatePackage.dll into the web application’s \bin folder. Allow it to replace an existing file of the same name.

Not using Visual Studio:

Using the Global Assembly Cache a. Remove the existing PetersDatePackage.dll file from the GAC. b. c. 5. Add the new PetersDatePackage.dll file into the GAC. If your web.config or machine.config file contains an <add assembly> tag to the PetersDatePackage.dll, update the version number to 2.0.1.5000.

If you are using Professional Validation And More to validate Peter’s Date Package controls: a. b. Confirm that you have Professional Validation And More v3.0.4 or higher. It cannot be used with an older version. Copy the file PeterBlum.PDPToVAM.dll to your web application’s \bin folder. ASP.NET 1.x users will find assemblies in [ProductFolder]\Assemblies\ASPNET 1_x ASP.NET 2.0 users will find assemblies in [ProductFolder]\Assemblies\ASPNET 2_0 c. If you are using Visual Studio.net, update your project reference to this new assembly. IMPORTANT: You may have set up your web.config file to include an <assemblyBinding> tag for PeterBlum.VAM.dll. If so, confirm that the <assemblyBinding> tag exactly matches the version of VAM that you are using. VAM includes a file called “Assembly Version Info for the config file.txt” that documents the exact version information. d. e. In a text editor, locate and open custom.VAM.config. It defaults to the [web application root]\VAM folder. Locate the string “PeterBlum.PDPToVAM”. Note: If this string is not found, it indicates that you have not setup Peter’s Date Package to use VAM. You can do that at a later time by following the directions in the VAM Style Validators.pdf supplied with Peter’s Date Package. f. If it reflects a specific version of the assembly, change that version to 2.0.1.5000. <DataType name="PDP:DateTextBox" type="PeterBlum.PDPToVAM.DateTextBoxVAMTypeConverter" assembly="PeterBlum.PDPToVAM, Version=2.0.1.5000, Culture=neutral, PublicKeyToken=7d7808ccfd0d4f9b" /> g. Repeat until all versions have been updated. There are 6 cases.

6.

Recompile your web application. If using Visual Studio.net, use Rebuild Solution. This step will report some warnings. for obsolete properties that you are currently using. Most of these obsolete properties can be left unchanged because they setup their replacement properties automatically. In addition, your ASP.NET Declarations of these controls in Web Forms (aspx files) and User Controls (ascx files) may be using these properties. You will have to review the ASP.NET Declarations manually. To get rid of those warnings, follow these directions. a. YOU SHOULD FIX THESE PROPERTIES The shared calendar properties on DateTextBox.xPopupCalendar are obsolete. They are xAutoSharedCalendarB, xSharedCalendarDateTextBoxID, and xSharedCalendarDateTextBox. They have been replaced by xSharedGroup on DateTextBox.xPopupCalendar.xCalendar. Page 27 of 38 For technical support and other assistance, see page 38

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum Version 2 shares popups automatically, eliminating the need to setup any of these properties. The only time you will use DateTextBox.xPopupCalendar.xSharedGroup is if there are multiple calendars on one page that have different appearance settings. Here is how to convert these properties: o o If all use a calendar with the same appearance, remove the obsolete properties. You do not need to assign anything to xSharedGroup. If any calendar needs a different appearance, remove the obsolete the properties. Then add the DateTextBox.xPopupCalendar.xSharedGroup property with a name to identify its appearance. Multiple calendars can use the same shared group name when they have the same appearance.

b. c.

CS_Calendar.xOnSelectionChanged has been replaced by xOnSelectionChangedScript. MonthYearPicker.xOnSelectionChanged has been replaced by xOnSelectionChangedScript. The ContextMenu control had its namespace changed from PeterBlum.CS_MenuControls to PeterBlum.PetersDatePackage. Switch the namespaces in your code and change the <tagprefix:class> in the ASP.NET definition to use the same tagprefix of other Peter’s Date Package controls. For example: <cs:ContextMenu> is changed to <date:ContextMenu>. All of these classes are affected: ContextMenu, ClickItem, ClickList, MenuCommandItem, MenuCommandList, and MenuCommandSeparator. DateTextBox.xReadOnlyAllowsPopupCalendarB has been replaced by xReadOnlyAllowsEditsB. xAutoAbsPositionModeB has been replaced by xContainerMode on all of the textboxes. When xAutoAbsPositionModeB is true, set xContainerMode to PeterBlum.PetersDatePackage.ContextMenu.Auto. When xAutoAbsPositionModeB is false, set xContainerMode to PeterBlum.PetersDatePackage.ContextMenu.Manual.

d. e.

7.

Version 2 shares the HTML of all types popup controls to reduce the page size and initialization time. (In v1.x, it only shared the popup calendar.) This sharing is enabled by default. Review each page to see if there are multiple controls of the same type for which you created different popups. For context menus, this would be differences in the menu items. For popup Calendars and popup MonthYearPickers, this would be differences in their appearance and features. When differences are found, set the xSharedGroup name to a unique value for each case. For example, when you have two DateTextBoxes with differences in their context menu or popup calendar’s appearance. For more, see the topic “Shared Popups” in the What’s New in Version 2 document.

8.

New style sheet files come with version 2. Most class names and style settings have not been changed. Even with the changes made, your existing style sheets probably will continue to give you a decent appearance. So you have the choices to maintain your existing style sheets or switch to the new ones. Version 2 provides separate style sheet files by the type of control. This provides a smaller page footprint and makes it easier to track down styles when you want to edit them. It is easiest to switch to this approach when you have done very little editing of the existing style sheets because the process is to use the new files and apply any changes to them. If you continue with existing style sheet files, you need to add the newest style sheet classes to your existing files, modify some of your existing style sheet classes, and add one line to the <appSettings> section of your web.config file. Directions for both approaches follow. Using new style sheet files Peter’s Date Package provides these new style sheet files, to separate style sheet classes by the controls that use them: DateTextBox.css, TimeTextBox.css, Calendar.css, MultiSelectionCalendar.css, SpecialDates.css, MonthYearPicker.css, and TimePicker.css.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 28 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum a. Determine the location of your current style sheet files. The new ones will go in the same location. Here are some common locations: • [domain root]\aspnet_client\petersdatepackage\appearance • [web app]\petersdatepackage\appearance • Search your site for the file name “StyleSheet1.css”. • You also may have copied the classes into your own style sheet files. If this is the case, you should either continue using your existing setup or remove those classes from the current file. b. c. Copy the new style sheet files from the [Product Folder]\For Upgraders\New Style Sheets folder into the folder containing the current style sheet files. Apply any changes to the new style sheet files. Look through your original style sheet files to see what changed. Note: No style sheet classes have been removed from those that came with version 1.x. Only .CSCCalendar has been edited to remove the filter style. There are many new classes. d. If the style sheet file is not in the PetersDatePackage\Appearance folder, open the web.config file and add these keys, where “[url]” is replaced by the URL to the folder: <configuration> <appSettings > <add key="PDP_StyleSheetDateTextBox" value="[url]/DateTextBox.css" /> <add key="PDP_StyleSheetTimeTextBox" value="[url]/TimeTextBox.css" /> <add key="PDP_StyleSheetCalendar" value="[url]/Calendar.css" /> <add key="PDP_StyleSheetMultiSelectionCalendar" value="[url]/MultiSelectionCalendar.css" /> <add key="PDP_StyleSheetSpecialDates" value="[url]/SpecialDates.css" /> <add key="PDP_StyleSheetMonthYearPicker" value="[url]/MonthYearPicker.css" /> <add key="PDP_StyleSheetTimePicker" value="[url]/TimePicker.css" /> <add key="PDP_StyleSheetContextMenu" value="[url]/ContextMenu.css” /> </appSettings> </configuration> e. In each web form that contains Peter’s Date Package controls, replace the current <link> tag to the Peter’s Date Package style sheet with this line:
<%= PeterBlum.PetersDatePackage.CommonFunctions.GetStyleSheetLinkTags(Page) %>

If your form does not have the <link> tag to a Peter’s Date Package style sheet, nothing needs to be done. That page is probably setup to let ASP.NET 2 insert the <link> tags automatically. The above line is used when the automatic link tag feature is not available. Use your existing files This will continue to use the style sheet files you setup in version 1.x, even if the classes were moved into another style sheet file. Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com Page 29 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide If you setup the <link> tag in each page like this in version 1.x, it will continue to work:

Last Updated: 09/11/2006 Peter Blum

<link href="<%= PeterBlum.PetersDatePackage.CommonFunctions.GetStyleSheetUrl(Page) %>" type="text/css" rel="stylesheet" >

a. b. c. d.

Open the file [Product Folder]\For Upgraders\New Style Sheets\NewFor2.css in a text editor. Copy the entire file’s contents and paste them into your existing style sheet files. Note: Don’t forget to update NS7StyleSheet1.css and OperaStyleSheet1.css if you were using them. Open the file [Product Folder]\For Upgraders\Updated StyleSheets.css in a text editor. Go through the document to apply the changes it offers. Most are optional and can be omitted if you like your current style. Comments are offered to help you make the best decision. Where it says recommended, you are encouraged to apply the change. There are only three recommended changes, associated with these classes: .CSCCalendar .CSCDayHeader .CSCDayHeader TR

e.

Open the web.config file and add the PDP_UseVersion1StyleSheet key as shown below. <configuration> <appSettings > <add key="PDP_UseVersion1StyleSheet" value="url" /> </appSettings> </configuration> Note: The tag and attribute names of the web.config file are case sensitive. Note: If your <appSettings> contains the following keys, they should remain: PDP_StyleSheetDefault, PDP_StyleSheetNetscape70, and PDP_StyleSheetOpera1_7.

9.

There are several new image files and several of the existing image files have been modified to support transparency. You do not have to replace any images that you may have modified. Only replace those that offer the best appearance for you. a. Determine the location of your Peter’s Date Package image files. The new ones will go in the same location. Here are some common locations: • [domain root]\aspnet_client\petersdatepackage\appearance • [web app]\petersdatepackage\appearance • Search your site for the file name “Calendar.jpg”. b. c. Copy the new image files from the [Product Folder]\For Upgraders\New Images folder into the folder containing the current image files. Copy only the updated image files that you want to use from the [Product Folder]\For Upgraders\Modified Images folder into the folder containing the current image files. Since this will overwrite existing image files, evaluate the images before overwriting anything. Most of the updated GIF images were given transparent pixels so they work on different backgrounds than white. The default image files for the month and year navigation buttons on CS_Calendar and MonthYearPicker have changed. They used to default to LeftCmdBlue.PNG, LeftCmd2Blue.PNG, RightCmdBlue.PNG, and RightCmd2Blue.PNG. Now they are LeftCmd_3DBlue.GIF, LeftCmd2_3DBlue.GIF, RightCmd_3DBlue.GIF, and RightCmd2_3DBlue.GIF. This change will only affect you if you have edited the original graphic image files. To continue using your edited graphic image files, edit the URL in these properties to reflect the old filename: In CS_Calendar, PopupCalendar and DateTextBox.xPopupCalendar.xCalendar: xNextMonthButtonImageUrl (RightCmdBlue.PNG), xPrevMonthButtonImageUrl (LeftCmdBlue.PNG), xJumpForwardButtonImageUrl (RightCmd2Blue.PNG), xJumpBackButtonImageUrl (LeftCmd2Blue.PNG).

d.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 30 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum In MonthYearPicker and PopupMonthYearPicker: xNextYearButtonImageUrl (RightCmdBlue.PNG), xPrevYearButtonImageUrl (LeftCmdBlue.PNG) 10. Test your web application. Any of these steps could have errors. Return to a step if you find a related error. 11. Update your Visual Studio.net toolbox. Either remove the existing Peter’s Date Package 1.x controls from the toolbox or add a new tab called Peter’s Date Package v2 to the toolbox. See “Installing Peter’s Date Package Into Visual Studio.net” for directions for adding controls and a tab.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 31 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Converting from Trial Version To Paid Version
This process can be very simple. It is often a matter of updating the license files. 1. 2. Update the License Files and License Key. See “Installing Licenses”. Your web application already has Peter’s Date Package installed. Compare the version of the production you downloaded with your purchase to the version already installed. • • 3. The version of the product just installed is in the folder name in C:\program files\Peter's Date Package v2.0.1. The version in your web application is available by checking the PetersDatePackage.dll assembly in the \bin folder or the Global Assembly Cache.

If the versions are different, you have a service release. Use “Installing a Service Release”.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 32 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Converting from ASP.NET 1.x to ASP.NET 2.0
Use this section when you are converting your web site from ASP.NET 1.x to ASP.NET 2.0. It will replace the ASP.NET 1.x version of Peter’s Date Package with the ASP.NET 2.0 version, which has an extended featureset. If you have a newer service release, these instructions will update to that release at the same time. WARNING: The ASP.NET 2.0 assemblies are compiled with the production release of Visual Studio 2005. Do not use these assemblies with any prerelease version of ASP.NET 2.0 or Visual Studio 2005. Note: ASP.NET 2.0 users are not required to use the ASP.NET 2.0 version of Peter’s Date Package. The ASP.NET 1.x version is compatible. However, it lacks features built around ASP.NET 2.0. If your web application is complete and you plan no further development, consider leaving your site using the ASP.NET 1.x version of Peter’s Date Package. Terminology The term [ProductFolder] refers to the folder where you installed Peter’s Date Package. For example, C:\Program Files\Peter's Date Package v2.0.1. The term [domain root] refers to the folder that contains the domain name of the site on your server. For example, the domain http://localhost is usually in C:\inetpub\wwwroot. The term [web application root] refers to the folder that contains the web application on your server. It contains the \bin folder and web.config file.

Installation Steps
1. 2. Convert your site fully to ASP.NET 2.0 while keeping the existing Peter’s Date Package in place. Confirm that it works. If you are installing a new version number (2.0.x → 2.0.y), copy the new scripts folder into your web application: a. b. In Windows Explorer, open the [ProductFolder]\Copy To Web App\PetersDatePackage folder. Copy the 2_0_# folder into the PetersDatePackage folder. The folder may be in one of these locations: • [domain root]\aspnet_client\PetersDatePackage\ For example: c:\inetpub\wwwroot\aspnet_client\PetersDatePackage\2_0_# • [web application root]\PetersDatePackage\ An example when using IIS: c:\inetpub\wwwroot\MyWebApp\PetersDatePackage\2_0_# An example when using the ASP.NET Development Server: C:\documents and settings\user name\my documents\Visual Studio 2005 \Websites\MyWebApp\PetersDatePackage\2_0_# • If you have not used one of the previous locations, see the <appSettings> section of the web.config file for a key that looks like this: <add key="PDP_ScriptVirtualPath" value="URL" /> Use that Url to locate the correct folder. Suggestion: If the PDP_ScriptVirtualPath key is listed with a version number shown, change the version number to the text “{VERSION}”. For example, here is the original text for v2.0.1: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/2_0_0" /> Here is the updated key: <add key="PDP_ScriptVirtualPath" value="~/PetersDatePackage/{VERSION}" /> Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com Page 33 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum This will create a new folder. There may be other folders that start with 1_1 and 2_0 from earlier releases. They can be ignored or deleted after you are satisified with this installation. 3. Install the PetersDatePackage.dll assembly either into your \bin folder or the Global Assembly Cache (GAC). All assemblies are located in [ProductFolder]\Assemblies\ASPNET 2_0. Using the \bin folder

♦ Visual Studio 2005 users
a. b. c. d. • Open your project. In Solution Explorer, right click on the web application project heading and choose Property Pages. Use the dialog box to remove your existing reference to PetersDatePackage.dll. Add a new reference to this version’s PetersDatePackage.dll. Copy the PetersDatePackage.dll assembly into the web application’s \bin folder.

♦ Not using Visual Studio 2005
Using the Global Assembly Cache a. Remove the existing PetersDatePackage.dll file from the GAC. b. c. 4. Add the new PetersDatePackage.dll file into the GAC. If your web.config or machine.config file contains an <add assembly> tag to the PetersDatePackage.dll, update the version number to 2.0.1.5000.

If you are using Professional Validation And More with Peter’s Date Package: a. b. c. Confirm that you have Professional Validation And More v3.0.4 or higher. It cannot be used with an older version. Copy the file PeterBlum.PDPToVAM.dll from [ProductFolder]\Assemblies\ASPNET 2_0 into your web application’s \bin folder. If you are using Visual Studio 2005, update your project reference to this new assembly. IMPORTANT: You may have set up your web.config file to include an <assemblyBinding> tag for PeterBlum.VAM.dll. If so, confirm that the <assemblyBinding> tag exactly matches the version of VAM that you are using. VAM includes a file called “Assembly Version Info for the config file.txt” that documents the exact version information. d. e. f. In a text editor, locate and open custom.VAM.config. It defaults to the [web application root]\VAM folder. Locate the string “PeterBlum.PDPToVAM”. If it reflects a specific version of the assembly, change that version to 2.0.1.5000. <DataType name="PDP:DateTextBox" type="PeterBlum.PDPToVAM.DateTextBoxVAMTypeConverter" assembly="PeterBlum.PDPToVAM, Version=2.0.1.5000, Culture=neutral, PublicKeyToken=7d7808ccfd0d4f9b" /> g. Repeat until all versions have been updated. There are 6 cases.

5.

Recompile your web application and test it. If using Visual Studio 2005, use Rebuild Solution.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 34 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Installing Into A Partial Trust Environment
Note: PeterBlum.com tech support cannot offer assistance in working with a partial trust environment beyond the technical details given here. The .net framework provides extensive security to prevent rogue assemblies from using resources that should be off limits. In .net v1.1 and higher, the web server can be set to impose security protections upon the web applications. This is called establishing “partial trust”. Extensive details on security in an ASP.NET environment can be found in this online book: “Improving Web Application Security: Threats and Countermeasures” by J.D. Meier, Alex Mackman, Michael Dunner, Srinath Vasireddy, Ray Escamilla and Anandha Murukan of Microsoft Corporation. In particular, see Chapter 9, “Using Code Access Security with ASP.NET”. There are two parts to security: settings within the assembly and permissions within the ASP.NET environment. This is how to use Peter’s Date Package within a partial trust environment. Assemblies In a partial trust environment, assemblies must have the AllowPartiallyTrustedCallersAttribute established. In addition, they must be “strong named” (compatible with the Global Assembly Cache by having a publickeytoken.) PetersDatePackage.dll and PeterBlum.PDPtoVAM.dll support AllowPartiallyTrustedCallersAttribute and strong names. Minimum Recommended Trust Level The default trust levels supplied with ASP.NET are Full, High, Medium, Low, and Minimal. Peter’s Date Package will work with these trust levels when set to their defaults: Full, High and Medium. If a customized trust level is used, you must have the conditions described here. Your machine.config file identifies another config file that lists all of the permissions an ASP.NET application has. In this config file, you must have the following permissions for Peter’s Date Package to work. FileIOPermission File access is only used to read the license files. The software never creates, deletes or writes to files. Here is the definition for the minimum for FileIOPermission: <IPermission class="FileIOPermission" version="1" Read="$AppDir$" PathDiscovery="$AppDir$" /> This definition assumes that the licenses are located in the [web application] folder or one of its subfolders. If you have it in the /aspnet_client folder and that folder is outside of the [web application] folder, relocate it into the web application. SecurityPermission It must have the Flags Execute and ControlThread. ControlThread is not defined by default in trust level=Low. ControlThread allows you to assign a CultureInfo object to the current thread, which is important when dealing with dates and times. Here is the definition for the minimum for SecurityPermission: <IPermission class="SecurityPermission" version="1" Flags="Execution, ControlThread" />

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 35 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Troubleshooting
Here are some issues that you may run into. Remember that technical support is available from support@PeterBlum.com. We encourage you to use this knowledge base first. Also see the “Troubleshooting” section of each User’s Guide.

Common Error Messages
Design Mode shows “Error Creating Control” instead of the control When you view the control in design mode, the control is replaced by a template indicating an error. Here are several causes of this: incorrectly installed software, incorrect property names or values, and bad ASP.NET text. If you point to the , VS.Net will show you the error in a tooltip. The page or design mode generates this error “The located assembly's manifest definition with name [assembly name] does not match the assembly reference.” This means that the assembly identified as [assembly name] was compiled to use another assembly that has a particular version. While the assembly was found, the version does not match the version that [assembly name] was compiled with. • • If you created the assembly, recompile it with the same PetersDatePackage.dll that is in use in your web application. ASP.NET 2.0 users only: View the web.config file. If the <configuration> tag has an xlnms= attribute, remove that attribute. This was only used in prerelease versions of ASP.NET 2.0.

The page generates this error: “Access is denied: PetersDatePackage.dll'.” Also “Access is denied. 'PeterBlum.PDPtoVAM.dll' or any assembly identified in this error message. The error message is identified as a “Configuration Error” and identifies the “Source Error” as <add assembly="*"/> in the source file machine.config. This is a very common error in ASP.NET and can happen with almost any third party control that you include in your application. It's usually due to the Indexing Service or a virus scanner that is scanning the [windows]\microsoft.net\framework\[version]\temporary asp.net files folder although other applications can be its source. Use this Microsoft Knowledge Base article to better understand it: http://support.microsoft.com/default.aspx?scid=kb;en-us;329065 Your task is to prevent the conflicting software from accessing files in the temporary asp.net files folder. The page generates this error: “Security Exception: The application attempted to perform an operation not allowed by the security policy.” You are running in a Partial Trust Environment. Please see “Installing Into A Partial Trust Environment”. The page generates this error: “Metadata file '[windows]\microsoft.net\framework\[version]\temporary asp.net files\[more path info]\PetersDatePackagedll' could not be found” This is a strange and poorly documented behavior of ASP.NET. ASP.NET copies assemblies from the \bin folder into the specified folder as the assembly is used by your web site. This error indicates that ASP.NET fails to actually copy the file or the file is deleted out from under ASP.NET. The cause has yet to be determined, but it can happen on any assembly found in the \bin folder. Customers who encountered this error have found these solutions worked for them: The following should be removed from the web.config file: <identity impersonate="true" />

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 36 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Last Updated: 09/11/2006 Installation Guide Peter Blum Install the PetersDatePackage.dll assembly in the Global Assembly Cache. Remove it from the \bin folder. Assemblies in the GAC are not copied into the Temporary ASP.NET files folder. A quick checklist to correctly install into the GAC is on step 2 of “Installing Peter’s Date Package Into Your Web Applications”. The page generates this error: “Request for the permission of type 'System.Web.AspNetHostingPermission, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' failed. [filepath]” Only in ASP.NET 2.0. This indicates that the filepath specified is not correctly configured to run ASP.NET applications from this computer. It usually happens when the filepath is a URL (like http://otherserver/file) or a shared filepath (like \\computername\sharedname\folder). • • • Go to the Microsoft .net Framework 2.0 Configuration program Expand its tree to this path: \MyComputer\Runtime Security Policy\Machine\Code Groups\All Code\LocalInternet Zone Add a new node that defines the URL or UNC path to use “FullTrust” permission.

Visual Studio generates this error: Warning: The dependency 'PetersDatePackage, Version=2.0.x.5000' cannot be copied to the run directory because it would overwrite the reference ''PetersDatePackage, Version=2.0.y.5000"' This warning message is harmless. It tells you that Visual Studio still knows about the location of an older version of PetersDatePackage.dll and wanted to copy it into your \bin folder. Since you have the latest version in the \bin folder, nothing was changed. Sometimes you can remove this warning with these steps: 1. 2. 3. 4. 5. Open the Solution Explorer Right click on the web application project node. Choose Properties from the context menu. Switch to the Reference Paths view. If you see a file path to the older version of Peter’s Date Package, remove it.

Visual Studio Problems
Visual Studio 2005’s Publish Web Site command does not copy the license files Visual Studio 2005 users who use the Publish Web Site command will find that it ignores the .lic files of your web application. You can use the <buildProviders> section of web.config to resolve this: <configuration> <system.web> <compilation> <buildProviders> <remove extension=".lic"/> <add extension=".lic" type="System.Web.Compilation.ForceCopyBuildProvider"/> </buildProviders> </compilation> </system.web> </configuration> Note: The web.config file is case sensitive. If this does not work, change the file extenstion of the license files from the .lic to .licx.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 37 of 38 For technical support and other assistance, see page 38

Peter's Date Package v2.0 Installation Guide

Last Updated: 09/11/2006 Peter Blum

Technical Support and Other Assistance
PeterBlum.com offers free technical support. This is just one of the ways to solve problems. This section provides all of your options and explains how technical support is setup.

Installation and User’s Guides
These guides are large because they are loaded with content. In many cases, the answers are in them.Both guides include Troubleshooting sections at the end. This information will often save you time.

PeterBlum.Com MessageBoard
Use the message board at http://groups.yahoo.com/groups/peterblum to discuss issues and ideas with other users.

Getting Product Updates
As minor versions are released (2.0.1 to 2.0.2 is a minor version release), you can get them for free. Go to http://www.PeterBlum.com/DateControls/Home.aspx. It will identify the current version at the top of the page. You can read about all changes in the release by clicking “Release History”. Click “Get This Update” to get the update. You will need the serial number and email address used to register for the license. As upgrades are offered (v2.0 to v2.1 or v3.0), PeterBlum.com will determine if there is an upgrade fee at the time. You will be notified of upgrades and how to retrieve them through email. PeterBlum.com often adds new functionality into minor version releases.

Technical Support
You can contact Technical Support at this email address: Support@PeterBlum.com. I (Peter Blum) make every effort to respond quickly with useful information and in a pleasant manner. As the only person at PeterBlum.com, it is easy to imagine that customer support questions will take up all of my time and prevent me from delivering to you updates and cool new features. As a result, I request the following of you: • • • • Please review the Users or Installation Guides, including their Troubleshooting section, first. Please try to include as much information about your web form or the problem as possible. I need to fully understand what you are seeing and how you have set things up. If you have written code that interacts with my controls or classes, please be sure you have run it through a debugger to determine that it is working in your code or the exact point of failure and error it reports. I cannot offer general ASP.NET mentoring. If your problem is due to your lack of knowledge in ASP.NET, I will give you some initial help and then ask you to find assistance from the many tools available to the .Net community. They include: o o o o o o Books www.asp.net forums and tutorials Microsoft’s usenet newsgroups such as microsoft.public.dotnet.framework.aspnet. See http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&group=microsoft.public.dotnet Google searches. (I virtually live in Google as I try to figure things out with ASP.NET.) http://www.Google.com. Don’t forget to search the “Groups” section of Google! http://aspnet.4guysfromrolla.com/, http://www.dotnetjunkies.com, http://www.aspalliance.com/ http://www.GotDotNet.com - for training and many samples on using ASP.NET

As customers identify issues and shortcomings with the software and its documentation, I will consider updating these areas.

Copyright © 2002-2006 Peter L. Blum. All Rights Reserved Information: http://www.PeterBlum.com

Page 38 of 38 For technical support and other assistance, see page 38