Show/Hide Toolbars

XSharp

Use of unassigned out parameter 'parameter'

 

The compiler could not verify that the out parameter was assigned a value before it was used; its value may be undefined when assigned. Be sure to assign a value to out parameters in the called method before accessing the value. If you need to use the value of the variable passed in, use a ref parameter instead. For more information, see Passing Parameters.

Example

 

The following sample generates XS0269:

 

 

// XS0269.prg  
 

Example

 

This could also occur if the initialization of a variable occurs in a try block, which the compiler is unable to verify will execute successfully:

 

 

// XS0269b.prg