Sure, but why would you need to calculate the "exact" wind while flying?
All that matters when flying (for fuel endurance, ETA, etc) is the ground speed, and if you are expecting that to be significantly affected by the wind during your flight then the wind direction etc are also likely to be changing.