Displaying users who click the button I have 2 user roles in my Drupal 7 site 'A' and 'B' respectively: 


users of role 'A' can create and publish content. 
users of role 'A' can see content they created on their profile page. (For this purpose I created a block to display content and put it on user's page.)
users of role 'B' can not create content but they can view all published content. 


Content in my case is an invitation to some event (ie "Who wants to play football on Friday?")

Each content has 'Participate' button which users of role 'B' can submit.


How can I display in 'A' users pages the names of 'B' users who want to participate in their event?
How can an 'A' user confirm participation of some 'B' users and dismiss the rest?
This is quite a complex task your planning – and it's hard to answer in just a few lines of text. I can basically just recommend you have a closer look at the mighty Rules module in combination with the Flag and the Entity reference module. 

Here's just a vague suggestion / outline of how this could probably be done by combining the above modules:


Put a flag 'participate' on content type event users of role 'B' can use 
Define a new content type 'participation' with checkbox/flag 'confirmed / dismissed' and reference the event and the user to it, editable by 'A' users
Make a rule that generates a new node of content type 'participation' and alerts users of role 'A' of a new request
Extend your profile pages' view with the referenced items of content type 'participation'


There is probably different ways to do this – most likely also easier ways than the one described above. And then there is also a more specific module 'Rules link event' that might fit your demands.