File Upload Only PDF Files:
----------------------------
Using RegularExpressionValidator
================================
<asp:FileUpload ID="FileUpload1"
runat="server"
class="textb"
Width="220px"
/>
<asp:RegularExpressionValidator ID="RegularExpressionValidator1"
runat="server" Text="Only PfFiles are allowed." ErrorMessage="Only PDF
Files are allowed."
ValidationExpression="^(([a-zA-Z]:)|(\\{2}\w+)\$?)(\\(\w[\w].*))+(.pdf)$" ControlToValidate="FileUpload1"></asp:RegularExpressionValidator>
If you want to create an open pdf file from a blank document, you need to open it as an ODF file using a compatible reader. Open PDF readers are available both online and offline.
ReplyDelete