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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 21, 20262026-05-21T17:09:57+00:00 2026-05-21T17:09:57+00:00

Do i miss something or is it not possible to get my formatting in

  • 0

Do i miss something or is it not possible to get my formatting in a Write-Debug statement?

"Date: {0:d}" -f (Get-Date) #Works as expected

Write-Debug "Date: {0:d}" -f (Get-Date) #Does not work
  • 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-21T17:09:58+00:00Added an answer on May 21, 2026 at 5:09 pm

    Try changing $DebugPreference to “continue” and add some parens:

    $DebugPreference = “Continue”

    Write-Debug (“Date: {0:d}” -f (Get-Date))

    The default for $DebugPreference is “SilentlyContinue” so Write-Debug won’t display anything.

    Write-Host will just work if you enclose your message in the parens.

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

Sidebar

Related Questions

Is this possible? Or would I miss something? (Fixtures,..?) Because: When I use autotest
There is something not clear to me about domain-driven-design and unit of work pattern.
When writing views and nesting views within deeper views I sometimes miss something and
I seem to miss something here: I want a TabControl with rounded Corners at
Possible Duplicate: Why does gcc have “â” in all its error messages? New to
I've been trying to get this arrow toggle script work on my page. I
I can't seem to find the debugdraw for Box2djs. Did I miss something or
probalby quite a dummy question, but that is not the area I work with
Today I faced a problem and I'm not able to get weather I understand
I miss it so much (used it a lot in C#). can you do

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.