Session values are getting populated only when the page is refreshed I have a webform. I provide default values to these webform using session token variables. These session variables are set using hook_form_alter(). The problem is that when users log in, and see the form, it is not populated. When they refresh the form, only the values get populated. 

How can I solve this issue?

/** updates **/

I have custom module like 

webform_options_form_alter(&amp;$form, &amp;$form_state, $form_id){
//here i set some values for session variables like.
$_SESSION['name']  = 'pradeep';
}


so in webform default value i put like %session['name']. This takes the value when page is refreshed. 

I have the login form as block on the same page of the webform. As soon as the user logs in the webform should be filled with user data. This is not happening. When he refreshes the page after login only he sees his data.
It sounds like your problem is how/when the session variables are set (they are not available on the initial form load). You don't mention how this is done.

Some code example and greater details in your question will allow for a more detailed answer.