我们如何让RT应用程序注册Print
PrintManager.ShowPrintUIAsync();
这将指示初始化打印小饰物,但我需要检查该应用程序是否注册了打印。
任何想法?
protected void RegisterForPrinting()
{
PrintManager printMan = PrintManager.GetForCurrentView();
if(printMan == null)
return;
// Create the PrintDocument.
printDocument = new PrintDocument();
// Save the DocumentSource.
printDocumentSource = printDocument.DocumentSource;
// Add an event handler which creates preview pages.
printDocument.Paginate += CreatePrintPreviewPages;
// Add an event handler which provides a specified preview page.
printDocument.GetPreviewPage += GetPrintPreviewPage;
// Add an event handler which provides all final print pages.
printDocument.AddPages += AddPrintPages;
// Create a PrintManager and add a handler for printing initialization.
printMan.PrintTaskRequested += PrintTaskRequested;
// Initialize print content for this scenario
//PreparePrintContent();
}