Identifier 'methodname' is not defined

I am a newbie here, Just created a blank app and trying to add an action to a button. I am getting the following error – ‘Identifier ‘buttonClicked’ is not defined. The component declaration, template variable declarations, and element references do not contain such a member’. Please let me know what I am doing wrong here?

did you add the onClick() method in ?

1 Like

That’s a thing I missed . Added a method but in module.ts file.