ElegantNumberButton icon indicating copy to clipboard operation
ElegantNumberButton copied to clipboard

NullPointerException

Open ghost opened this issue 6 years ago • 1 comments

in RVAdapter,

public static ElegantNumberButton button;

in MainActivity,

SubMenuRVAdapter.button.setNumber("0");

When I click Send button, I want to set ElegantNumberButton number "0" as a default. This ElegantNumberButton, findViewById come from RVAdapter.

ghost avatar Apr 10 '18 03:04 ghost

The problem for you is in SubMenuRVAdapter. I don't exactly know what's happening unless I can see the Log or at least your code for SubMenuRv Adapter where you're calling ElegantNumberButton. I'd also advice you to not make the button as static. This doesn't initialize the object.

ashik94vc avatar Apr 22 '18 23:04 ashik94vc