I am fairly new to Construct 2 but I can't see why your idea shouldn't work? I guess that you are making top down RPG game?
I would change the code like something below to easier reuse the code if you are going to have another quest later on, like GetTheKeysAgain. Then you just have to change how many keys you are going to collect (IntComplete) and then change the Quest string.
When picking up a key:
if Quest_GetTheKeys_Count = Quest_GetTheKeys_IntComplete
Quest_GetTheKeys_Count = 0 (Reset)
When you hand it in:
Add 1000000 coins + 500000000 xp