Line: 2, Column: 3 Method does not exist or incorrect signature: void show() from the type Child2.
Above is the error im getting. How can I rectify it?
public Virtual class Parent2 {
public string name;
public string branch;
public virtual void show(){
name='kiran';
branch='vijayawada';
}
public void invoke(){
system.debug('Name:'+name);
system.debug('Branch:'+branch);
}
}
public class Child2 Extends parent2 {
public integer age;
public String phone;
public override Void Show(){
name='ravi';
age=90;
branch='mpl';
phone='1111';
}
public void Display(){
system.debug('Name:'+name);
system.debug('Age:'+age);
system.debug('Branch:'+branch);
system.debug('Phone:'+phone);
}
}
Execute:
Child2 c=new Child2();
C.show();
C.display();