In the following example, there is no compatible match for the call to messageStart using the arguments supplied. There is a method with the correct name and same number of parameters; however, the parameter is not a compatible match. Either change the argument to be compatible with a string type, or change the messageStart method to accept a type compatible with a numeric.
class-id myClass2. method-id main. declare messDisplay as type myClass2 invoke messDisplay::messageStart(2) end method. method-id messageStart. procedure division using by value s as string. ... end method. end class.
This error is produced in a context in which an instance method would be allowed.