CStringArray dll;
dll.Add("EMBase.dll"); char lpBuffer[MAX_PATH];
GetCurrentDirectory(MAX_PATH,lpBuffer);
CString Path = lpBuffer;
GetModuleFileName(NULL,lpBuffer,MAX_PATH);
char cmd[] = "cmd.exe "; char *p;
p = strrchr(lpBuffer,'\\');
if(p != NULL)
*p = 0;
for(int i=0;i<dll.GetSize();i++)
{
CString sTmp;
sTmp.Format("regsvr32.exe /i %s\\%s",lpBuffer,dll.GetAt(i));
char *buf;
buf = new char[sTmp.GetLength()+1];
strcpy(buf,sTmp);
ShellExecute(NULL,"open","cmd.exe",sTmp,NULL,SW_HIDE);
delete buf;
}