int MiscAction () 
{
    ProError status;
	ProFeature feature;
	ProElement elemtree;
    ProMdl model;
    ProMdlType model_type;
    ProPath output_file;
	wchar_t input[PRO_FILE_NAME_SIZE];
//----------------------------------------------------------------------	
	status = ProMdlCurrentGet (&model);
	if (status != PRO_TK_NO_ERROR)
	{
        ProMessageDisplay (msgfil,"Fehler bei ModelCurrentGet");               
		return PRO_TK_GENERAL_ERROR;
		//return (0);
    }
//-----------------------------------------------------------------------
	status = ProMdlTypeGet (model, &model_type);
	if (model_type != PRO_MDL_ASSEMBLY)
    {
       ProMessageDisplay (msgfil,"Projekt muss Assembly sein!");
       return PRO_TK_GENERAL_ERROR; 
       //return (0);
    }
//----------------------------------------------------------------------
    ProMessageDisplay (msgfil,"Select directory location for output XML file");
    status = ProDirectoryChoose (NULL, NULL, NULL, NULL, output_file);
    if (status != PRO_TK_NO_ERROR)
    {
       ProMessageDisplay (msgfil,"Fehler bei Pfadangabe");
       return (0);
    }
//----------------------------------------------------------------------
    ProMessageDisplay (msgfil,"Name der XML Datei angeben");
    
    if(ProMessageStringRead (PRO_FILE_NAME_SIZE, input) != PRO_TK_NO_ERROR)
    {
       ProMessageDisplay (msgfil,"Fehler bei Eingabe Name");
       return (0);
    }    
//----------------------------------------------------------------------
	status = ProFeatureElemtreeCreate(&feature, &elemtree);
    if (status == PRO_TK_NO_ERROR)
    {
//----------------------------------------------------------------------       
       status = ProElemtreeWrite(elemtree, PRO_ELEMTREE_XML, output_file);
       
       ProElementFree(&elemtree);
     }
//----------------------------------------------------------------------     
     else
     {
         ProMessageDisplay (msgfil,"Fehler bei ProFeatureElemtreeCreate");
         return (0);
    }
//----------------------------------------------------------------------
    return(PRO_TK_NO_ERROR);

}