- Home /
 
               Question by 
               Ozigma · Feb 04, 2020 at 12:48 PM · 
                c#applicationscreenshotcommandprocessing  
              
 
              How to send Printer the screenshot from unity to print. (without closing or opening another application)
I am trying to print the screenshort captured from unity. My question is there any way i can send printer that job directly. I've found a code on unity forum that opens up the other application to print the image but i want to directly print the image without opening another application. here is the code:
 using UnityEngine;
 using System.Collections;
 using.System.Drawing;
 using.System.Drawing.Printing;
 
 public class ImageOpen : MonoBehaviour 
 {
 
     int count=0;
 
     void Update () 
     {
         if(Input.GetKeyDown(KeyCode.Space))
         {
             count++;
             Application.CaptureScreenshot(Application.dataPath+"/Screenshot"+count+".png");
         }
     }
     public void PrintScreen()
     {
         System.Diagnostics.Process.Start("mspaint.exe",Application.dataPath+"\\Screenshot"+(count)+".png");
     }
 }
               Comment
              
 
               
              Your answer
 
 
             Follow this Question
Related Questions
Multiple Cars not working 1 Answer
Distribute terrain in zones 3 Answers
SyncListString not changing in a Command 0 Answers
Can I use Rpc Calls and Commands on the same object? 0 Answers
 koobas.hobune.stream
koobas.hobune.stream 
                       
                
                       
			     
			 
                