I would highly suggest your read the manual and do some examples (open c2, new, and look down that list.) pick one and actually try to redo it, thereby learning.
To answer your question:
Add Event
Click system
Scroll down and find every x seconds (choose your desired seconds in your case it is "1")
Now create a global variable called counter
Now add an action
Same thing hit system, now find Add Too
select counter variable and make it 1
So every second will add 1 to global variable "counter"
To dispaly in text file.
Add action
Go to text file and set to variable "counter"
And the button. Create a sprite, call it button. Add touch to project
Add event. Touch ... on object "button"
Add action. Add too... you get the drift