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 3499840
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T12:39:38+00:00 2026-05-18T12:39:38+00:00

In app.config, I supply a cycle string value: Monday, Tuesday, …, Daily. From that

  • 0

In app.config, I supply a cycle string value: “Monday”, “Tuesday”, …, “Daily”. From that value I wanted to assign a <Flags()> enum. Simply using DayOfWeek does not give me the ability to flag a process as a daily routine. Is there an available .Net class that does provide the day of week as a flag?

In the meantime, I devised the following:

<Flags()> _
Public Enum enumExportCycle As Integer
    Monday = DayOfWeek.Monday
    Tuesday = DayOfWeek.Tuesday
    Wednesday = DayOfWeek.Wednesday + 1
    Thursday = DayOfWeek.Thursday + 4
    Friday = DayOfWeek.Friday + 11
    Saturday = DayOfWeek.Saturday + 26
    Sunday = DayOfWeek.Sunday + 64
    Daily = Monday Or Tuesday Or Wednesday Or Thursday Or Friday Or Saturday Or Sunday
End Enum

It feels somewhat hackish and I am looking for a better way.

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

    this will work, right?

    <Flags()> _
    Public Enum enumExportCycle As Integer
        Monday = 1
        Tuesday = 2
        Wednesday = 4
        Thursday = 8
        Friday = 16
        Saturday = 32
        Sunday = 64
        Daily = Monday Or Tuesday Or Wednesday Or Thursday Or Friday Or Saturday Or Sunday
    End Enum
    

    or this

    <Flags()> _
    Public Enum enumExportCycle As Integer
        Monday = 2 ^ DayOfWeek.Monday
        Tuesday = 2 ^ DayOfWeek.Tuesday
        Wednesday = 2 ^ DayOfWeek.Wednesday
        Thursday = 2 ^ DayOfWeek.Thursday
        Friday = 2 ^ DayOfWeek.Friday
        Saturday = 2 ^ DayOfWeek.Saturday
        Sunday = 2 ^ DayOfWeek.Sunday
        Daily = Monday Or Tuesday Or Wednesday Or Thursday Or Friday Or Saturday Or Sunday
    End Enum
    

    since DayOfWeek start from 0 (Sunday) to 6 (Saturday)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want my app.config (or my web.config for that matter) to read from an
This is my App.Config <?xml version=1.0 encoding=utf-8 ?> <configuration> <appSettings> <add key=lang value=English/> </appSettings>
I have an app.Config that was created on the dev machine running Windows 7.
A requirement for a 3rd party config is that i supply it with: 1.
I have an app.config file that looks like this: <?xml version=1.0 encoding=utf-8 ?> <configuration>
In the app.config file of a .NET application there is a <runtime> element that
I currently have an app.config with the following config value: <configuration> <runtime> <loadFromRemoteSources enabled=true
I have follwing in app.config file: <appSettings> <add key=Name value=Office/> ... <add key=Name value=HotSpot/>
I have a config Section in my app.config that looks like this <configSections> <section
I have an app.config section I want to define, as a simple IDictionary<string, IDictionary<string,

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.