Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6839943
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T23:46:49+00:00 2026-05-26T23:46:49+00:00

I am trying to enumerate the file system, checking for apache versions installed in

  • 0

I am trying to enumerate the file system, checking for apache versions installed in wamp. The apache folder usually has the version numbers in the name.

My goal is first to look for this folder in each drive

2.2.19
2.2.18
2.2.1
2.2.0

so the file path can look like c:\wamp\bin\apache\apache2.2.20 or c:\wamp\bin\apache\apache2.2.1

How do I check if this folder exists and also get the version from the folder name?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T23:46:50+00:00Added an answer on May 26, 2026 at 11:46 pm

    You can use Directory.GetDirectories() to get all directories.

    Something like this should work for you:

    var directory = @"C:\wamp\bin\apache\";
    foreach(var dir in Directory.GetDirectories(directory)) {
        var version = dir.Replace(directory, "")
                         .Replace("Apache", "");
    
        Console.WriteLine("{0} is installed", version);
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to find version of .NET installed on a list of servers.
I am trying to enumerate a number of failure cases for a system I
I've got a curious item, I'm trying to enumerate through an xml file with
I have an application with a file and folder list control which supports Drag&Drop
So I'm dealing with a csv file that has missing values. What I want
I am trying to enumerate and build the following fiddle with Mustache.js: $(function ()
I'm trying to enumerate all hosts in an XML document, create a db entry
I'm trying to enumerate through all the Controls of a Page, but all I
Today I have seen this weird magic NTFS system supports: each file can have
So I'm trying to comprehend the source file for csv2rec in matplotlib.mlab. It is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.