<?phpfunction mymodule_enable() { // Get the files content $filename = drupal_get_path('module','mymodule') . "/mymodule.cck"; $content = implode ('', file ($filename)); // Build form state $form_state = array( 'values' => array( 'type_name' => '<create>', 'macro' => $content, ), ); // Put it in there drupal_execute("content_copy_import_form", $form_state);}?>