I am writing a C# application that build on the Visio ActiveX Control. The program works fine so far. What I now need to realize is a "File" menu in the menu bar similar to Visio 2003: a) the "New >" submenu should expand and show all templates of drawings available in Visio b) the "Shapes >" submenu should expand and show all Shapes available in Visio, including the ones in the "My Shapes" subfolder -> Where do I find the information in the Windows registry about the items to display in a) and b), respectively? I know how to find out about the "My Shapes" folder though the registry, but the rest does not seem obvious as I see skipping through the registry. Can anyone help or point out to where to find detailed information? Cheers, Peter
Hi there! It seems like that there is no direct information about templates and shapes in the Windows registry. - Visio is installed at a certain location - That location provides a subdirectory according to the installation locale (location identifier = LCID), e.g. "1033" (English) or "1031" (German) - In here there are all shapes (*.VSS) and templates (*.VST) What I still need to know: How do I find out Visio's correct LCID? There is a general LCID for Windows, but this is probably not necessarily the same as of the Visio installation: HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Controls Folder: "Presentation LCID" Any ideas? Peter "Peter Bittner" wrote: > I am writing a C# application that build on the Visio ActiveX Control. The > program works fine so far. > > What I now need to realize is a "File" menu in the menu bar similar to Visio > 2003: > > a) the "New >" submenu should expand and show all templates of drawings > available in Visio > > b) the "Shapes >" submenu should expand and show all Shapes available in > Visio, including the ones in the "My Shapes" subfolder > > -> Where do I find the information in the Windows registry about the items > to display in a) and b), respectively? > > I know how to find out about the "My Shapes" folder though the registry, but > the rest does not seem obvious as I see skipping through the registry. > > Can anyone help or point out to where to find detailed information? > > Cheers, Peter
Hi, Have you try to use the Application.EnumDirectories(Application.StencilPaths) method. "Peter Bittner" a crit dans le message de news: CCA4EEC6-3059-4262-BF76-A3025E61A87A@microsoft.com... > Hi there! > > It seems like that there is no direct information about templates and > shapes > in the Windows registry. > > - Visio is installed at a certain location > - That location provides a subdirectory according to the installation > locale > (location identifier = LCID), e.g. "1033" (English) or "1031" (German) > - In here there are all shapes (*.VSS) and templates (*.VST) > > What I still need to know: How do I find out Visio's correct LCID? > > There is a general LCID for Windows, but this is probably not necessarily > the same as of the Visio installation: > > HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Controls > Folder: > "Presentation LCID" > > Any ideas? > Peter > > > "Peter Bittner" wrote: > >> I am writing a C# application that build on the Visio ActiveX Control. >> The >> program works fine so far. >> >> What I now need to realize is a "File" menu in the menu bar similar to >> Visio >> 2003: >> >> a) the "New >" submenu should expand and show all templates of >> drawings >> available in Visio >> >> b) the "Shapes >" submenu should expand and show all Shapes available >> in >> Visio, including the ones in the "My Shapes" subfolder >> >> -> Where do I find the information in the Windows registry about the >> items >> to display in a) and b), respectively? >> >> I know how to find out about the "My Shapes" folder though the registry, >> but >> the rest does not seem obvious as I see skipping through the registry. >> >> Can anyone help or point out to where to find detailed information? >> >> Cheers, Peter