The directory name is invalid

Problem

You get this error when using the PDF Report feature in your application:

Server Error in '/XXX’ Application.

The directory name is invalid.

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.IO.IOException: The directory name is invalid.

The error occurs when the ‘Anonymous’ property of your application’s virtual directory is enabled.  Iron Speed Designer sets the ‘Anonymous’ property of virtual directories to ‘Disabled’ by default.  When the ‘Anonymous’ property is enabled, you must properly set your user account permissions in order to enable access.

Solution

You can enable or disable authentication for your application and then selecting "Authentication" option under the Features view in Microsoft IIS.  Change "Anonymous Authentication" to ‘Disabled’ and re-run the application.

See these topics for details on setting the user account permissions to access data:

Allow Anonymous Access (Recommended for Production Environment)

No Anonymous Access (Recommended for Development Environment)

Manually register your application with Microsoft IIS

In some cases, you may need to manually register your application with Microsoft IIS.

Try to register your web manually in the IIS.

Step 1:  Remove your web application from Microsoft IIS.  Its name is same as the Iron Speed Designer project name.

Step 2:  Add your application manually in Microsoft IIS as new web application.

See Also

Application Runs But No Data is Displayed

Part VII:  Troubleshooting Applications

Application Will Not Run

Application Runs But No Data is Displayed

Application Error Messages