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

  • SEARCH
  • Home
  • 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 7157981
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T12:59:04+00:00 2026-05-28T12:59:04+00:00

I have a project whereby a large number of technical specifications are currently ‘published’

  • 0

I have a project whereby a large number of technical specifications are currently ‘published’ as HTML files. The HTML files are not hosted on a web server, but zipped up and distributed to be access from a PC’s local file system.

I am exploring the idea of creating a “publishing” system where the publisher could amend the content of the HTML files based on custom tags within the HTML itself. I suppose this would be similar to using PHP or ASP if it were server based.

So for example I might add

<Publisher action="___" params="________" />

The publisher would detect the presence of the “tag” do the required processing and then inject the necessary HTML into the files replacing the tag.

Does anyone know a way of achieving this using .NET based technology, or another way to achieve the same thing.

  • 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-28T12:59:05+00:00Added an answer on May 28, 2026 at 12:59 pm

    OK, not sure if this is the most elegant solution, it works.

    1) Based on Cannot delete directory with Directory.Delete(path, true) I clear down the target where the published “site” is intended to go.

    2) I then copy all of the files using code based on the accepted solution to question Copy the entire contents of a directory in C#.

    3) I intercept all of the “HTM” or “HTML” files and use a regexp to see if any “processing” is required. This is based of code from the site here http://msdn.microsoft.com/en-us/library/system.text.regularexpressions.regex.replace(v=vs.71).aspx (shown below )

    using System.Text.RegularExpressions;
    
    class RegExSample 
    {
       static string CapText(Match m) 
       {
         // Get the matched string.
         string x = m.ToString();
         // If the first char is lower case...
         if (char.IsLower(x[0])) 
         {
            // Capitalize it.
           return char.ToUpper(x[0]) + x.Substring(1, x.Length-1);
         }
         return x;
       }
    
       static void Main() 
       {
         string text = "four score and seven years ago";
         System.Console.WriteLine("text=[" + text + "]");
         string result = Regex.Replace(text, @"\w+",
            new MatchEvaluator(RegExSample.CapText));
         System.Console.WriteLine("result=[" + result + "]");
       }
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have project asp.net with namespace test and I'm using resources (files Resource.resx and
i am currently working on a project where i have 'units' that will have
We have project with lot of precanned test files, so obviously the test-jar file
I have a project whereby I'm trying to create a distribution zip file, which
I have part of a project whereby I need to send 1 to up
I have project which is currently working and was developed long time back on
I am working on a project, whereby I have several groups, several permissions and
I have a Django project whereby every model inherits from a common Object model
I'm working on a project whereby I have a series of configuration classes in
Ok, so I have a Visual Studio project and all of the files, images

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.