AddIn command lost clicked state after one code line

Hi,

My addin have few toolbar buttons wich starts long lasting exports. I try async functions to run some independand data colectectors at same time. But here i got result which i cant explain and i didnt found it in web.

workflow:

I starting export by clicking toolbar button.

Button stays in this state and model window is blocked until pass this code line.

Dim resultDict As Dictionary(Of String, Double()) = Await subTask 'it is System.Threading.Tasks.Task (of TResult) type

Result after code line:

Command continues to do what it must do. Model window unblocked. Nothing happens if click same button again. After some time appears correct results.

By the workflow i need keep blocked model window an button state must represent command is still running.

SolidworksApi macros