How to set pragmatically Minimum order subtotal limit in Ubercart Drupal? I am using the Ubercart module for my site. And I need to set Minimum order subtotal pragmatically not for admin panel. I am going to create a custom module to apply this condition but not getting any hook.

Any suggestions?
If you would like to validate minimum subtotal directly in the cart, you could use hook_form_alter.

function mymodule_form_alter(&amp;$form, &amp;$form_state, $form_id){
  switch ($form_id) {
    case 'uc_cart_view_form':
      //add own validate function
      $form['#validate'] = array('mymodule_subtotal_validate');
    break;
  }
}


Then define the content of the validation function:

function mymodule_subtotal_validate($form, &amp;$form_state){
  //validate only if we are going to submit the cart form 
  //there are others possibilites, when the validate handler is called,
  //such as quantity change, etc..)
  if(isset($_POST['op']) &amp;&amp; $_POST['op'] == t('Checkout')){
    //access cart items and their quantity
    $sum = 0;
    foreach($form_state['values']['items'] as $key =&gt; $item){
      $product = node_load($item['nid']);
      $qty = $item['qty'];
      $sum += $product-&gt;price * $qty;
    }

    if($sum &lt; YOUR_SUM){
      form_set_error(null, 'Your items subtotal is less than minimal subtotal.');
    }
  }
}