Is it possible to limit the number of copies while printing in Silverlight 4? Perhaps the "number of copies" textbox in the Print dialog c开发者_运维知识库an be disabled somehow?
As far as I know, there is no way to control the number of copies when printing from Silverlight. But at the following URL you'll find a way to achieve a "controlled" printing operation from Silverlight, that is: a way to execute a printing operation from Silverlight having the user not allowed to interact with the "Print" dialog box, that will be "auto-confirmed". In that way, the printing operation is forced to happen to the default printer only and in one (and only one) printed copy; in order to print further copies, the user will need to invoke again the print feature (and the application will be able to log properly the fact).
http://www.codeproject.com/KB/silverlight/SilverlightSilentPrinting.aspx
Please note: it's a solution suitable only in specific scenarios (line of business applications, with control over the target client machine).
精彩评论