title: Gracefully Close application With Yes Response
body: <p>We have application and when we close it, it ask to change the status to offline. When we hit Yes, application get closed and its status changed. I tried to close the application with powershell using below code.</p>
  
  <p>Get-Process 'Application' |? { $_.CloseMainWindow() | Out-Null } </p>
  
  <p>But it prompt for status change diaolog box to hit yes to close. I want to pass this yes to close directly without any prompt for response.</p>
  
  <p>Please help.</p>