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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T12:53:09+00:00 2026-05-15T12:53:09+00:00

I’m new to programming in VBA, but what I’m trying to do right now

  • 0

I’m new to programming in VBA, but what I’m trying to do right now is have a PowerPoint slide that updates every day. It’s a weather forecast slide that is displayed in our lobby, and currently I manually update the seven day forecast each day I come in. This means that until I come in, it shows the current day as yesterday’s date, and the seven day forecast is still showing yesterday’s date in the forecast. Ultimately I’d like to have it pull in the weather data automatically as well, but for the scope of this question, I’m just trying to figure out how to display the dates in a textbox for the seven days of the week.

Basically, there’s a header along the top with: (e.g. Wednesday, June 30, 2010)

Then the seven days set up in columns with: (e.g. June 30 July 1 July 2 …)

I would like to set the header to the current date as shown, and then the seven textboxes below to the current day, then tomorrow, then the next day… and so on until the seventh day.

How would I increment the DateTime? Thanks!

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

    If you want to go forward in 1-day steps, you can increment DateTime variables by adding to them:

    Dim d As DateTime
    d = Now()
    
    d = d + 1 ''# => tomorrow
    

    This works because internally, a DateTime is represented as a floating point number with whole days before the comma and fractions of days after the comma. (Consequently, adding 0.5 would effectively add 12 hours, though I would not recommend doing that.)

    For more complex operations like adding months or hours, there is DateAdd() (see MSDN).

    d = DateAdd("h", 12, d)  ''#=> 12 hours
    

    You can “add” negative values with DateAdd(), too.

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

Sidebar

Related Questions

this is what i have right now Drawing an RSS feed into the php,
I have a French site that I want to parse, but am running into
I have a jquery bug and I've been looking for hours now, I can't
I have a small JavaScript validation script that validates inputs based on Regex. I
I'm parsing an RSS feed that has an ’ in it. SimpleXML turns this
This could be a duplicate question, but I have no idea what search terms
I'm trying to convert HTML to plain text. I get many &\#8217; &\#8220; etc.
I'm trying to create an if statement in PHP that prevents a single post
I am trying to loop through a bunch of documents I have to put
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function

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.