DOCUMENT:Q192116 02-SEP-1998 [vbwin] TITLE :HOWTO: Configure Posting Acceptor To Work With the PDW PRODUCT :Microsoft Visual Basic for Windows PROD/VER:WINDOWS:6.0 OPER/SYS:WINDOWS KEYWORDS: ====================================================================== --------------------------------------------------------------------- The information in this article applies to: - Microsoft Visual Basic Learning, Professional, and Enterprise Editions for Windows, version 6.0 --------------------------------------------------------------------- SUMMARY ======= The Visual Basic Package and Deployment Wizard uses a technology called the Posting Acceptor to manage the transfer of your Visual Basic applications to a Web server. Posting Acceptor is a component located on the IIS Web server that enables the posting of content to the server. Before you can successfully post your applications, you must install Posting Acceptor and configure the Web server correctly. This article walks you through the basic configuration and presents troubleshooting information for some of the more common problems you may encounter when posting Visual Basic applications to the Web. MORE INFORMATION ================ Steps in the Web Deployment Process ----------------------------------- When you post a Visual Basic application to a Web server using the Package and Deployment Wizard, you first use the packaging portion of the wizard to package your applications into one or more .cab files, then you use the deployment portion of the wizard to transfer your files to the appropriate location. IMPORTANT: Make should you have admin-level rights to the Web server to which you are posting content. The Web server goes through these steps during deployment: 1. It extracts the .cab file into a temporary directory. 2. It locates the .inf file for the .cab file. 3. Based on the contents of the .inf file, it installs application files (based on the RInstallApplicationFiles section of the .inf file), system files (based on the RIinstallSystemFiles section), and shared files (based on the RInstallSharedFiles section). In the process, the server registers any necessary files. NOTE: The DefaultInstall section of the .inf file is not run because the instructions it contains often require user input. The Posting process also does not create a virtual directory for your application if one is required; directories must be set up in advance. Installing Posting Acceptor --------------------------- You must install Posting Acceptor on any server to which you want to post applications using Visual Basic's Package and Deployment Wizard. There are multiple versions of Posting Acceptor. You must make sure you install the correct version based on your server's configuration: - Posting Acceptor 2.0 Windows NT 4.0 with SP3 IIS 4.0 Posting Acceptor 2.0 supports both content posting and the unpacking of cabinet (.cab) files on the server. - Posting Acceptor 1.0 Windows NT 4.0 with SP3 IIS 3.0 You cannot unpack .cab files with this version of posting acceptor. Use this for content posting only. You can move your files to the server and then manually register any necessary files that would have been registered by the .cab process. NOTE: Posting Acceptor does not work on any platforms that are using Personal Web Server or Peer Web Server. You must use IIS. To install Posting Acceptor 1.0: - Run the installation program from the Microsoft Web site at: http://www.microsoft.com/Windows/software/webpost/post_accept.htm To install Posting Acceptor 2.0: 1. Launch Visual Studio or Visual Basic setup from your installation CDs. 2. When prompted to choose options to install, click Install Server Applications and Tools, and then click Next. 3. Click Launch the BackOffice Installation Wizard, and then click Install. 4. Now select the radio button for Custom, and then click Next. 5. You will see the options to install and their sizes. Click Next. 6. Select Microsoft Posting Acceptor 2.0. NOTE: If you want to install Posting Acceptor 2.0 on a computer that already has the Windows NT Option Pack, you should first check to see if version 1.0 of the Posting Acceptor is already installed. If so, remove it before installing version 2.0. To determine if 1.0 is installed: 1. Open the Windows Control Panel. 2. Click Add/Remove Programs. 3. On the Install\Uninstall panel, select the NT Option Pack. 4. Click Add/Remove, then look for Posting Acceptor 1.0 among the components listed. You may find it under Microsoft Site Server. If it is installed, remove it. Configuring the Server ---------------------- You must perform the following steps on the Web server to which you want to deploy your packaged Visual Basic applications. To configure your IIS server: 1. Install Microsoft Internet Information Server (IIS) from the NT Option Pack. 2. Install Posting Acceptor 2.0 as described in the previous procedure. 3. On the Start menu, select Programs \ Windows NT 4.0 Options Pack \ Microsoft Internet Information Server \ Internet Service Manager. 4. In the left panel of the manager, make sure the Console Root folder is expanded, then expand the Internet Information Server folder. Your IIS server(s) are listed below this folder. 5. Expand the IIS server that you want to configure. You will see a number of nodes, including one called Default Web Site. 6. Right-click on Default Web Site, then click Properties. 7. In the Default Web Site Properties dialog box, click the Home Directory tab, then make sure that the Write option is selected. 8. Click Apply. The Inheritance Overrides dialog box may appear, containing a list of folders to which the setting you just made should apply. Select only those folders to which you want users to be able to deploy packages, then click OK until you return to the manager. NOTE: Allowing write access to a virtual directory is a SECURITY RISK. Make sure you only allow write access to virtual directories you know are secure. 9. In the left panel, right-click the folder called SCRIPTS that appears beneath the Default Web Site folder, and then click Properties. 10. Click the Virtual Directory tab, ensure that the Execute (including script) button is selected, and click OK. Configuring the Client Machine ------------------------------ Visual Studio installs and configures all the components you need to deploy applications from your development machine. However, if you are running Visual Studio on a computer that is on an intranet and you connect through a proxy server, you must configure Internet Explorer 4.0 to bypass the proxy server for local addresses. To configure your development machine: 1. On your Windows desktop, right-click the Internet Explorer icon and click Properties. 2. In the Properties dialog box, click the Connection tab. 3. In the Proxy Server section, ensure that Bypass proxy server for local (Intranet) addresses is selected if Access the Internet using a proxy server is selected. Click OK. Troubleshooting Web Deployment from Visual Basic ------------------------------------------------- The following sections list some of the more common problems you may encounter while trying to post applications to the server using the Package and Deployment Wizard. General Tips: - You should have admin-level rights to the Web server to which you are posting content. - If you receive an error that files are busy during the posting process, you should reboot your server rather than just stopping and restarting the service. After you reboot, you can attempt to post again. In general, it is a good idea to reboot the server as part of your troubleshooting process. Problem: Your Server Does Not Have Visual Basic Installed If your Web server does not have a copy of the Visual Basic 6.0 run-time DLL installed and other system files such as: MSVBVM60.DLL OLEAUT32.DLL OLEPRO32.DLL ASYCFILT.DLL STDOLE2.TLB COMCAT.DLL MSWCRUN.DLL is needed for IIS Applications (WebClass Designer run-time). MSHTMPGR.DLL is needed for DHTML Applications (DHTML Page Designer run- time). You may run into problems the first time you try to post an application to it. In this case, the server may not be able to correctly install necessary system files. There are several things you can do about this: - Install a copy of Visual Basic on the server, then post your application again, using the wizard. - Create a standard setup package with the Package and Deployment Wizard, rather than an Internet package. You can then move the setup.exe to the server and install the program on the server. This will install the necessary system files. After the installation process, reboot your server. - The cab files for the above-needed system files can be downloaded from the Microsoft site. You need to install and register these files on the server. You may need to reboot the server after this process. NOTE: This procedure only applies to the first installation of a Visual Basic application on such a server; all subsequent installations can be posted with the Web deployment feature of the wizard. Problem: Cab File is Copied to Web Server but Not Unpacked If the .cab file you are deploying is copied to the server but not unpacked, make sure that: - You included the .cab file on the wizard's Items to Deploy screen. - You used HTTP Post as the protocol on the wizard's Web Publishing Site screen. - You selected the Unpack and Install Server-Side Cab check box on the wizard's Web Publishing Site screen. If you did not, try re-deploying your package with this option selected. NOTE: Cab unpacking is supported only by Posting Acceptor 2.0 running on IIS 4.0. If you are running version 1.0, you cannot unpack the file during deployment. Problem: Web Server Does Not Support the Selected Service Provider There are several things you can do to try to fix this problem: - If you are using the HTTP Post protocol, make sure that Posting Acceptor is installed on your Web server. - Ensure that your URL is correct. If you are using HTTP Post, ensure that your URL begins with http://. If you are using FTP, ensure that your URL begins with ftp://. - If you are uploading to a server that has Posting Acceptor 1.0 installed, you cannot select the option to unpack and install your cabinet files when you deploy your package using the wizard. In this case, deploy your cab again, making sure to deselect the Unpack and Install Server-Side Cab option. Problem: Need Write Access to the Web Server If you use the HTTP Post protocol and receive an error that you do not have write access for the Web server, you must change the access permissions for your Web server. To set Write access: 1. From the Start menu, open the Internet Service Manager on the server computer. 2. Click Console Root, click Internet Information Server, and then click the name of your Web server machine. 3. Right-click the Default Web Site node, and then choose Properties. 4. Select the Home Directory tab, and then select the Write check box. NOTE: Allowing write access to a virtual directory is a SECURITY RISK. Make sure you only allow write access to virtual directories you know are secure. Problem: Error c0042116, or Processing Has Stopped If your files are read-only when you try to post, you will receive an error C0042116 announcing that processing has stopped. Use File Explorer to change your file attributes, then continue with your posting process. Problem: FTP Protocol Problems The Package and Deployment Wizard allows you to post content using either the HTTP or the FTP protocol. If you use FTP, you may encounter the following issues: - If receive an error that access is denied, perform these steps: 1. From the Start menu, open the Internet Service Manager on the server computer. 2. Click Console Root, then click Internet Information Server, then click the name of your Web server machine. 3. Right-click the Default Web Site node, then choose Properties. 4. Select the Home Directory tab, and select the Write check box. NOTE: Allowing write access to a virtual directory is a SECURITY RISK. Make sure you only allow write access to virtual directories you know are secure. - If you use the FTP protocol and receive additional errors besides the one described in the previous bullet, make sure that you have properly configured your FTP service on the Web server. To do so, start the Microsoft Management Console (MMC), then follow these steps: 1. Right-click the Default FTP Site and choose New Virtual Directory. 2. Enter an alias to be used to access the virtual directory, then click Next. 3. Enter the physical path of the directory to which to map the virtual directory. For example, c:\inetpub\ftproot, and then click Next. 4. Select the appropriate access permissions, making sure to allow write access so that your deployments can proceed without errors, then click Finish. 5. Right-click the Default FTP Site and choose Stop. 6. Right-click the Default FTP Site and choose Start. When you deploy to the FTP server using the Package and Deployment Wizard, use the site FTP://servername/alias where alias is the alias you assigned in step 2. Use the username "anonymous" and the password "me@somewhere" for anonymous login. Problem: Incorrect Parameter If you receive an error that says a parameter is incorrect, you may need to take one of the following actions: - Check to make sure that you have typed a valid URL to the Web server you have chosen to use. - On the Web server, search for files named default.asp and default.htm, in the \inetpub\wwwroot directory. Open both files and make sure that they have the following code at the top of the file: REFERENCES ========== Please see the following Microsoft Knowledge Base article for more information on the Package and Deployment Wizard: ARTICLE ID: Q190046 TITLE : INFO: VB 6.0 Readme – Part 6: Wizard Issues Additional query words: kbdsi kbDSupport kbVBp kbVBp600 kbWizard kbAppSetup ====================================================================== Version : WINDOWS:6.0 Platform : WINDOWS Issue type : kbhowto ============================================================================= THE INFORMATION PROVIDED IN THE MICROSOFT KNOWLEDGE BASE IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. MICROSOFT DISCLAIMS ALL WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING THE WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL MICROSOFT CORPORATION OR ITS SUPPLIERS BE LIABLE FOR ANY DAMAGES WHATSOEVER INCLUDING DIRECT, INDIRECT, INCIDENTAL, CONSEQUENTIAL, LOSS OF BUSINESS PROFITS OR SPECIAL DAMAGES, EVEN IF MICROSOFT CORPORATION OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. SOME STATES DO NOT ALLOW THE EXCLUSION OR LIMITATION OF LIABILITY FOR CONSEQUENTIAL OR INCIDENTAL DAMAGES SO THE FOREGOING LIMITATION MAY NOT APPLY. Copyright Microsoft Corporation 1998.