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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 13, 20262026-06-13T08:03:32+00:00 2026-06-13T08:03:32+00:00

This is what I am trying to do: ( @echo This is some code

  • 0

This is what I am trying to do:

(
@echo This is some code that is
@echo Important to echo exactly as-is
@echo Even if I use parenthesis
@echo for something (like this)
)|clip

So having that copied into clipboard. I have tried the following:

(
@echo This is some code that is
@echo Important to echo exactly as-is
@echo Even if I use parenthesis
@echo for something ^(like this^)
)|clip

But this seems to affect my WANTED parentheses as well because I receive an error. To test this, I simply done:

(
@echo This is some code that is
@echo Important to echo exactly as-is
@echo Even if I use parenthesis
@echo for something ^(like this^)
FFF
)|clip

Hey! This almost works, the text is copied all the way to the “s” in “this”. It does not copy the last parentheses, or obviously the F’s. Any ideas?

  • 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-06-13T08:03:33+00:00Added an answer on June 13, 2026 at 8:03 am

    It’s obvious that you need three carets there 🙂

    (
    @echo This is some code that is
    @echo Important to echo exactly as-is
    @echo Even if I use parenthesis
    @echo for something (like this^^^)
    )|clip
    

    Why? That is a bit tricky…

    First the parser parses the block and escapes the part this^^^) to this^), the parenthesis was escaped here the first time.

    But as you used a pipe, the complete block will be translated and transfered to a new cmd.exe instance.
    C:\Windows\system32\cmd.exe /S /D /c" ( @ echo This is some code is ... & @ echo for something (like this^) )"

    And in the new instance it is necessary again to escape the closing parenthesis.
    That’s all!

    And for more information you could read a similar question
    SO: why does delayed expansion fail when inside a piped block of code

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

Sidebar

Related Questions

I have some php code that was like this: $row = mysql_fetch_array ( mysql_query(SELECT
I have some code that creates a table like this: for($i=0; $i<$fields_num; $i++) {
I'm trying to echo the XML content at this URL but I'm having difficulty.
I have an element like this: <div id=foo_<?php echo $id;?> class=hidden></div> I'm trying if
I am trying to generate some xml with this php code here... I am
I have a PHP question. I am trying to alter some code that a
This is a wordpress question. I am trying to use a bit of code
I have a link that looks like this: <p class=half_text><?php echo $upvotes; ?> <strong>
I'm trying to replicate some C# code in PHP5 and am having some difficulties.
I'm having a bit of an issue trying to get some PHP code to

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.