Once you have got your PIDL pointer from SHGetSpecialFolderLocation(), use SHGetPathFromIDList() to get the full path of the directory that the Start menu mirrors (it should be a path under your Profiles entry.

This path is just like any directory - you can create new subdirectories (= cascading menus) and then create files or shortcuts in the subdirectories (= items in the cascading menu).

Like this:

---// Add a menu or two to the start menu.
pWndMain = AfxGetMainWnd();
if (pWndMain != NULL)
hWnd = pWndMain->GetSafeHwnd();

if (::SHGetSpecialFolderLocation(hWnd, CSIDL_STARTMENU, &pPIDL) != NOERROR)
AfxMessageBox("Failed to get Start menu folder!");
else
{
bGotPath = ::SHGetPathFromIDList(pPIDL,(LPSTR)strPath.GetBuffer(_MAX_PATH) );
strPath.ReleaseBuffer();
if (bGotPath && strPath != "")
{
_chdrive(strPath[0]);
_chdir( (const char *)strPath);
if (_mkdir("My Start Menu Extension") != 0)
AfxMessageBox("Couldn't create subfolder!");
if (_chdir("My Start Menu Extension") != 0)
AfxMessageBox("Couldn't set directory to subfolder!");

// Now you can create files or shortcuts to go in this directory / menu level.
}
else
AfxMessageBox("Couldn't get path!");

// Retrieve a pointer to the shell's IMalloc interface.
if (SUCCEEDED(SHGetMalloc(&pMalloc) ) )
{
// Free the PIDL.
pMalloc->Free(pPIDL);
// Release the shell's IMalloc interface.
pMalloc->Release();
}
}




---

Does this help?