You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Now, I have another contract deployed, called - Bank and it has a function execute. What I need is that I want to call Bank's function execute by voting.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey Richard.
@ricmoo
I deploy one of the contracts
Voting
fromFactory
contract and emitVoting
address. I catch the event and get theVoting
contract such as :Now, I have another contract deployed, called -
Bank
and it has a functionexecute
. What I need is that I want to callBank
's functionexecute
byvoting
.I tried:
Problem is that
voting.provider
somehow still ends up to be thesigners[0]
- the same account that just deploys stuff by default.Now, with this, I get an error: unknown account 0xf433c50017d963b6082043445bcd0a54716ddc1d and here, the address is trully voting's address.
How should I solve this ? I am running stuff in hardhat's network for testing.
Beta Was this translation helpful? Give feedback.
All reactions