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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T06:42:46+00:00 2026-05-25T06:42:46+00:00

When working with NuGet, I’m attempting to use a powershell script to change a

  • 0

When working with NuGet, I’m attempting to use a powershell script to change a file to an embedded resource. I’m using a small powershell script recommended on the forums here. However, my script only works when the file isn’t in a folder.

param($installPath, $toolsPath, $package, $project)

$item = $project.ProjectItems.Item("Folder\ReleaseNotes.txt")
$item.Properties.Item("BuildAction").Value = [int]3

How can I adjust this line to find a file even if it is in a folder:

$item = $project.ProjectItems.Item("ReleaseNotes.txt")
  • 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-25T06:42:47+00:00Added an answer on May 25, 2026 at 6:42 am

    Well, I found it.

    ProjectItems is a comprehensive list that contains both files and folders. In order to access folder/ReleaseNotes.txt you have to go down the nav tree. This is the solution

    param($installPath, $toolsPath, $package, $project)
    $item = $project.ProjectItems.Item("Folder").ProjectItems.Item("ReleaseNotes.txt")
    $item.Properties.Item("BuildAction").Value = [int]3
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Working in Eclipse on a Dynamic Web Project (using Tomcat (v5.5) as the app
Working with an Oracle 9i database from an ASP.NET 2.0 (VB) application using OLEDB.
Working with printf in a bash script, adding no spaces after \n does not
Working in WPF, writing a custom user control. I am trying to change the
Working on a simple helper function in PowerShell that takes a couple of parameters
Trying to figure out the best way to use Nuget in a development environment
I'm working on a page using ASP.NET MVC3, Razor and Entity Framework. I used
Everything was working fine until I updated with NuGet the references for CastleWinsor and
So I would like to use NuGet to manage the various projects I use
I have basically loaded Elmah assemblies and installed the package using the NuGet plug-in.

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.