Show/Hide Toolbars

XSharp

Cannot locate WITH block for member access expression without left hand side. This will be resolved into a late bound call at runtime and may cause an exception when no active WITH block is found.

 

You will only see this warning when compiling in the FoxPro dialect and when the "Late Binding" option is enabled.

For all other dialects the missing left hand side of the expression will generate a compilation error XS9082

 

Example

 

FUNCTION Foo()
LOCAL oError as Error
oError = Error{}
WITH oError
  .Description = "SomeDescription"
  Bar()
ENDWITH
 
 
PROCEDURE Bar()
IF .Description == "SomeDescription"     // Warning XS9108
  .Description = "SomeOtherDescription"   // Warning XS9108
ENDIF
RETURN