Hello - I am TRULY a fledgling at using C# - (writing a couple of memory management programs for music performace purposes).
OK - I wrote a C# program that ran under XP that displays service info from the registry as part of functionality for dynamic management of memory using profiles. All was well until I upgraded to Windows 7. The program runs fine, but under Win7 service description and some other info now may contain MUI strings and I need to adjust my C# program to call RegLoadMUIString in a C++ program to retrieve the needed info.
So what I would like someone to help me with is a complete set of example code in C# that calls a C++ program that performs the RegLoadMUIString function to retrieve the translated string and pass it back to the calling C# program.
As an example, my C# program already gets all of the list of services running on my machine. As it is populating a display screen with the service information, I need to take each service and - for those that use redirected strings (MUI), I need to call a C++ routine to take the redirected string information and use the RegLoadMUIString function (available only in C++) to retrieve the actual value (for service description for example) and return that value to the C# program for inclusion in the populated information for the services running on the machine. DisplayName can also be valued as a redirected string - so I have to be able to retrieve one or more of these per service, depending on how many redirected string values are present for a given service in the list I am processing for display in my C# program.
Here is a for instance of what the issue is - for service 'Application Layer Gateway Service' the value stored for Description is: "@%SystemRoot%\system32\Alg.exe,-113" which if you looked at it using Services.MSC would show up translated to a value of "Provides support for 3rd party protocol plug-ins for Internet Connection Sharing". I need to mimic what Services.msc does behind the scenes to retrieve the expanded Service Description value.
Thank you SOOOOO much