SqlServerPdfStorageProviderCommandTimeout Property |
Namespace: RadPdf.Integration
Exception | Condition |
---|---|
ArgumentException | The property value assigned is less than 0. |
A value of 0 indicates no limit (an attempt to execute a command will wait indefinitely).
CommandTimeout has no effect when the command is executed against a context connection (a SqlConnection opened with "context connection=true" in the connection string).
This property controls the timeout per command executed. Internally, RAD PDF may execute several commands during a single procedure. This value simply sets the CommandTimeout used by each internal SqlCommand instance.
using System; using System.Web; using RadPdf.Integration; public class CustomPdfIntegrationProvider : PdfIntegrationProvider { public CustomPdfIntegrationProvider() : base() { // Set a 10 minute timeout instead of the default (30 seconds) ((SqlServerPdfStorageProvider)this.StorageProvider).CommandTimeout = 600; } }
<?xml version="1.0"?> <configuration> <appSettings> <add key="RadPdfLicenseKey" value="DEMO"/> <add key="RadPdfIntegrationProvider" value="CustomPdfIntegrationProvider,App_Code"/> </appSettings> <system.web> <httpHandlers> <add path="RadPdf.axd" verb="GET,POST" type="RadPdf.Web.HttpHandler.PdfHttpHandler"/> </httpHandlers> </system.web> <!-- The system.webServer element is for use with IIS 7 (and later) when Managed Pipeline Mode is set to "Integrated". It will be ignored in other versions of IIS. --> <system.webServer> <validation validateIntegratedModeConfiguration="false"/> <handlers> <add path="RadPdf.axd" verb="GET,POST" name="PdfHttpHandler" preCondition="integratedMode" type="RadPdf.Web.HttpHandler.PdfHttpHandler"/> </handlers> </system.webServer> </configuration>