Hello all,

I am have a text file with a list of windows services. Is there a way to check if the computer I'm working on has a specific service installed(Currently Win7 but needs to work for Vista and XP too? I want to do something like this:

bool found = false;
        while(!file.eof())
	{
		getline(file, serv);
		//if(Check if service(serv) is found){
                //      found = true;
                //      return 1;}
               //else
               //       found = false;

	}

Is this possible?
Thanks!

Recommended Answers

I think you will find all the installed services in the registry
HKEY_LOCAL_MACHINE/System/CurrentControlSet/Services

Jump to Post

All 3 Replies

I think you will find all the installed services in the registry
HKEY_LOCAL_MACHINE/System/CurrentControlSet/Services

Is that a file that I can open? I need the script I am creating to be as fast and simple as possible. Is there a way to access a text file full of the services? Or os there some kind of script to create this?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.