Simulate submission of custom form as a webform
Here's how to create a Webform submission programmatically:

global $user;
$node = node_load(YOUR_NODE_ID);

// Prepare the data. Do note that the keys in this array must match the elements
// in your webform.
$data = array(
  1 =&gt; array('Field one value'),
  2 =&gt; array('Field two value'),
  3 =&gt; array('Field three value'),
);

// Create the submission object.
$submission = new stdClass();
$submission-&gt;uid = $user-&gt;uid;
$submission-&gt;nid = $node-&gt;nid;
$submission-&gt;submitted = REQUEST_TIME;
$submission-&gt;remote_addr = ip_address();
// This is necessary to mark the submission as complete.
$submission-&gt;is_draft = FALSE;
$submission-&gt;data = $data;

// Store the submission.
module_load_include('inc', 'webform', 'includes/webform.submissions');
webform_submission_insert($node, $submission);

// If necessary, invoke the email sending for this Webform.
webform_submission_send_mail($node, $submission);


Hope this helps.