title: How to pass optional arguments to object method using PowerShell?
body: <p>I would like to call the method of an object. This method has many optional parameters but I would like to use only one. How can I do that in PowerShell ?</p>
  
  <p>Example:
  Object <code>Workbooks</code> has method <code>OpenText</code> (<a href="https://docs.microsoft.com/en-us/office/vba/api/excel.workbooks.opentext" rel="nofollow noreferrer">link</a>) which has many optional parameters but I would like to pass only the value for parameter <code>DecimalSeparator</code>, all others I don't want to specify.</p>
  
  <p>In other languages I would do something like this:</p>
  
  <pre><code>$App.Workbooks.OpenText($path, DecimalSeparator=$decSeparator)
  </code></pre>
  
  <p>Please, tell me how to do that in PowerShell ?</p>