<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="https://www.w3.org/2005/Atom" xmlns:sy="https://purl.org/rss/1.0/modules/syndication/" xmlns:dc="https://purl.org/dc/elements/1.1/" xmlns:content="https://purl.org/rss/1.0/modules/content/" xmlns:wfw="https://wellformedweb.org/CommentAPI/" xmlns:slash="https://purl.org/rss/1.0/modules/slash/"
  version="2.0">
  <channel>
    <title>MiguelNunez</title>
    <atom:link
      href="https://docs.microsoft.com/archive/blogs/miguelnunez/feed.xml"
      rel="self"
      type="application/rss+xml" />
    <link>https://docs.microsoft.com/archive/blogs/miguelnunez/feed.xml</link>
    <description />
    <lastBuildDate>Wed, 17 Apr 2019 03:25:22 GMT</lastBuildDate>
    <language>en-US</language>
    <sy:updatePeriod>hourly</sy:updatePeriod>
    <sy:updateFrequency>1</sy:updateFrequency>
    <item>
      <title>PowerShell, Executing Internet Explorer as Network Service</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/powershell-executing-internet-explorer-as-network-service</link>
      <pubDate>Tue, 31 Mar 2015 11:03:09 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2015/03/31/powershell-executing-internet-explorer-as-network-service/</guid>
      <description><![CDATA[Sometimes as part of troubleshooting things will work when you try them as an administrator, but...]]></description>
      <content:encoded><![CDATA[<p>Sometimes as part of troubleshooting things will work when you try them as an administrator, but they will not work when executed as Network Service, here is a PowerShell script that will open Internet Explorer in the context of the Network Service:</p>
<p>(of course you could use the same script to run any program with any other user)</p>
<pre class="scroll"><code class="csharp">psexec -u "nt authority\network service" -i "c:\program files\internet explorer\iexplore.exe"<br /> </code></pre>]]></content:encoded>
    </item>
    <item>
      <title>Powershell for Changing AppSettings in Application Configuration File</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/powershell-for-changing-appsettings-in-application-configuration-file</link>
      <pubDate>Tue, 03 Feb 2015 10:28:11 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2015/02/03/powershell-for-changing-appsettings-in-application-configuration-file/</guid>
      <description><![CDATA[Here is a PowerShell Function that I created with the objective of changing an application...]]></description>
      <content:encoded><![CDATA[<p>Here is a PowerShell Function that I created with the objective of changing an application configuration file and then, if we want, restart a service</p>
<p>&nbsp;</p>
<pre class="scroll"><code class="cplusplus">Function Set-ApplicationSettingConfigProperty<br /> {<br /> param (<br /> [parameter(Mandatory = $true)][ValidateScript ({Test-Path $_})][string] $PathToConfigFile,<br /> [parameter(Mandatory = $true)][string] $PropertyName,<br /> [parameter(Mandatory = $true)][string] $PropertyValue,<br /> [Parameter(Mandatory = $false)][Validatescript ({(Get-Service $_) -ne $null})][string] $NameOfServiceToRestart = $null)<br /> <br /> $configurationAppSettingXmlPath = "//configuration/appSettings"<br /> <br /> [xml] $configurationDocument = Get-Content $PathToConfigFile<br /> $appSettingsNode = $configurationDocument.SelectSingleNode($configurationAppSettingXmlPath)<br /> <br /> if($appSettingsNode -eq $null)<br /> {<br /> $(throw "App Settings Does not Exists! Invalid Configuration File.")<br /> }<br /> <br /> $nodeToUpdate = $configurationDocument.SelectSingleNode($configurationAppSettingXmlPath+"/add[@key='$PropertyName']")<br /> if($nodeToUpdate -ne $null)<br /> {<br /> Write-Host "[$PropertyName] Already exists, Removing it to re-set its value."<br /> $removedElement = $appSettingsNode.RemoveChild($nodeToUpdate)<br /> }<br /> <br /> Write-Host "Creating new Configuration Node."<br /> $newPropertyNode = $configurationDocument.CreateNode("element", "add","")<br /> <br /> Write-Host "Setting Node Attributes."<br /> $newPropertyNode.SetAttribute("key", $PropertyName)<br /> $newPropertyNode.SetAttribute("value", $PropertyValue)<br /> <br /> Write-Host "Appending Child to AppSettings."<br /> $appSettingsNode = $configurationDocument.SelectSingleNode($configurationAppSettingXmlPath).AppendChild($newPropertyNode)<br /> <br /> Write-Host "Adding new property into the configuration file."<br /> $configurationDocument.Save($PathToConfigFile)<br /> <br /> Write-Host "Property was Successfully Updated."<br /> <br /> if([string]::IsNullOrWhiteSpace($NameOfServiceToRestart) -eq $false)<br /> {<br /> Write-Host "Service [$NameOfServiceToRestart] was defined.., Restarting it"<br /> Restart-Service -Name $NameOfServiceToRestart <br /> Write-Host "Service was Restarted..."<br /> }<br /> }</code></pre>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/10/59/08/50/ChangeAppConfigProperty.ps1" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-10-59-08-50/ChangeAppConfigProperty.ps1">ChangeAppConfigProperty.ps1</a></p>]]></content:encoded>
    </item>
    <item>
      <title>Debugging like a Boss with Visual Studio!</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/debugging-like-a-boss-with-visual-studio</link>
      <pubDate>Fri, 23 Jan 2015 15:07:00 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2015/01/23/debugging-like-a-boss-with-visual-studio/</guid>
      <description><![CDATA[There are a couple of things that I would like to go thru inthis post in what I consider the most...]]></description>
      <content:encoded><![CDATA[<p>There are a couple of things that I would like to go thru in<br />this post in what I consider the most important things to know while debugging<br />a .net application in visual studio&hellip; In this post I will assume that you know<br />how to attach to process and debug local processes that way.</p>
<p>&nbsp;</p>
<h1>Debugging remote processes (No Authentication)</h1>
<p><strong>Disclaimer!!</strong></p>
<p><em>First I would like to make clarify that this is not intended</em><br /><em>for production purposes, you should rely mostly on logging to diagnose and detect</em><br /><em>issues on your applications&hellip; Debugging in production with intrusive programs is</em><br /><em>strongly discouraged for live environments as they might cause users to get</em><br /><em>hanged in debug breakpoints.&nbsp; The steps</em><br /><em>that I&rsquo;m describing below I use them mostly when debugging onebox issues, this</em><br /><em>is, that I&rsquo;m debugging a virtual machine (that I own) where a set of components</em><br /><em>(that I own) have been deployed.</em></p>
<p>This is a very powerful feature to know, sometimes you need<br />to debug your application on a remote machine, so here are the steps that you<br />need to do</p>
<p>Copy the remote debugger from your dev machine to the one<br />where the process you are intending to debug is located.&nbsp; Note that the Remote Debugger is specific to<br />the version of visual studio that you will be using for the debugging session; these<br />are the typical locations for VS 2012/2013 (it may vary depending on your<br />installation):</p>
<p><strong>Visual Studio 2012</strong></p>
<p>C:\Program Files (x86)\Microsoft Visual Studio<br />11.0\Common7\IDE\Remote Debugger</p>
<p><strong>Visual Studio 2013</strong></p>
<p>C:\Program Files (x86)\Microsoft Visual Studio<br />12.0\Common7\IDE\Remote Debugger</p>
<p>The Remote debugger is not particularly big 50-ish MBs so<br />copying it into the target machine should not be a big problem.</p>
<p>&nbsp;</p>
<p>Now run msvsmon.exe. This should open the following Window</p>
<p>&nbsp;<a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/8535.RemoteDebugger.jpg" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/8535.RemoteDebugger.jpg"><img src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/8535.RemoteDebugger.jpg" original-url="https://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/8535.RemoteDebugger.jpg" alt="" border="0" /></a></p>
<p>Now go to Tools-&gt;Options-&gt;No Authentication.</p>
<p>Now you can go to visual studio (on your dev machine) and go<br />to attach to process, from the transport drop down select Remote, and then use<br />the full name with the port as displayed in the msvsmon.exe in the Qualifier textbox,<br />now press enter and you should see the processes show up in the &ldquo;Available Processes&rdquo;<br />go to the process that you want to debug and then click on the Attach button.</p>
<p>&nbsp;<a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/3343.AttachToProcess.jpg" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/3343.AttachToProcess.jpg"><img src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/3343.AttachToProcess.jpg" original-url="https://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/3343.AttachToProcess.jpg" alt="" border="0" /></a></p>
<p><strong>Note</strong>:</p>
<p><em>As with any debugging<br />you will need the PDBs of the dll that you are trying to debug, for more<br />information about PDBs you can read <a href="https://www.wintellect.com/devcenter/jrobbins/pdb-files-what-every-developer-must-know">this</a><br />fantastic article from wintellect&rsquo;s John Robbins</em></p>
<p>&nbsp;</p>
<h1>My Breakpoint is Not Working!!! &nbsp;&ldquo;:(</h1>
<p>Learn to love the Modules window! Whenever you are debugging<br />a process and your breakpoint is not breaking and there is an exclamation mark<br />on the breakpoint saying that no symbols have been loaded for the current process<br />it usually means that! &nbsp;This means that<br />Visual Studio was unable to find the PDBs and therefore Visual studio cannot infer<br />the mapping between your binary and your code.</p>
<p>&nbsp;</p>
<p>Now&hellip; Q: how can you find out where the dlls are being pulled<br />from and where it is trying to get the PDBs from? A: The Modules Window!</p>
<p>&nbsp;</p>
<p>When debugging: Go to Debug-&gt;Windows-&gt;Modules&hellip; your<br />breakpoint is not working? Go to the modules window find your dll, and check<br />the reason why the PDBs are not getting loaded, if you have the PDBs at hand<br />you can right click and do &ldquo;Load from Location&rdquo; and then you can tell it where<br />to load it from.</p>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/3872.ModulesWindow.jpg" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/3872.ModulesWindow.jpg"><img src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/3872.ModulesWindow.jpg" original-url="https://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/3872.ModulesWindow.jpg" alt="" border="0" /></a></p>
<h1>Loading Symbols Automatically</h1>
<p>In visual studio you can define paths from where to load<br />PDBs dynamically, you do this by going into Tools-&gt;Options, then from the<br />options on the left select Debugging-&gt;Symbols, and in here you can define a<br />location where your build system might store the PDBs automatically.</p>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/8420.Symbols.png" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/8420.Symbols.png"><img src="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Blogs.Components.WeblogFiles/00/00/01/66/65/8420.Symbols.png" original-url="https://blogs.msdn.com/resized-image.ashx/__size/550x0/__key/communityserver-blogs-components-weblogfiles/00-00-01-66-65/8420.Symbols.png" alt="" border="0" /></a></p>
<p>&nbsp;</p>]]></content:encoded>
    </item>
    <item>
      <title>Azure AD, Licensing users in a Security Group</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/azure-ad-licensing-users-in-a-security-group</link>
      <pubDate>Wed, 21 Jan 2015 23:45:00 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2015/01/21/azure-ad-licensing-users-in-a-security-group/</guid>
      <description><![CDATA[Today I was trying to figure it out how to license a set of users in a Security Group and I came up...]]></description>
      <content:encoded><![CDATA[<p>Today I was trying to figure it out how to license a set of users in a Security Group and I came up with a PowerShell function to do it so, the function is based on <a href="https://365lab.net/2014/04/15/office-365-assign-licenses-based-on-groups-using-powershell">this</a>&nbsp;article from 365Lab</p>
<p>First you need to&nbsp;install the latest "Windows Azure Active Directory Module for Windows PowerShell".&nbsp; The commands can be installed from <a href="https://msdn.microsoft.com/en-us/library/azure/jj151815.aspx#bkmk_installmodule">here</a>.</p>
<ol>
<li>Download the ps1 attached to this article</li>
<li>Run the "Windows Azure Active Directory Module for Windows PowerShell", this should open a PowerShell window</li>
<li>Import-Module &lt;FullPathToAttachedFile&gt;<ol>
<li>Example: Import-Module C:\temp\SetLicenseToUsersInSecurityGroup.ps1</li>
</ol></li>
<li>Set-LicenseToUsersInSecurityGroup -UserName &lt;TenantAdminUserName&gt; -Password &lt;TenantadminPassword&gt; -GroupName &lt;NameOfTheGroup&gt; -AccountSkuId &lt;accountSkuToAddLicensesTo&gt;<ol>
<li>You may get the AccountSkuId by running the following command: Get-MsolAccountSku</li>
</ol></li>
<li>After running this command you should get a confirmation of the users that were licensed.</li>
</ol>
<p>&nbsp;</p>
<p><strong>Important Notes</strong>:</p>
<ul>
<li>Users that were already licensed will not be changed, this is, this script will not remove licenses to users that were removed from the Security Group</li>
<li>Further changes on the Security Group will not reflect any changes in licenses</li>
<li>You will&nbsp;need&nbsp;PowerShell 3.0</li>
</ul>
<p>&nbsp;</p>
<p><strong>References</strong>:</p>
<ul>
<li><a href="https://blogs.technet.com/b/ems/archive/2014/12/01/how-to-assign-ems-licenses-using-the-azure-portal.aspx">How to Assign EMS Licenses Using the Azure Portal</a></li>
<li>
<p><a href="https://365lab.net/2014/04/15/office-365-assign-licenses-based-on-groups-using-powershell/">Office 365 Assign Licenses Based on Groups Using PowerShell</a></p>
</li>
</ul>
<p>&nbsp;</p>
<pre class="scroll"><code class="cplusplus">Function Set-LicenseToUsersInSecurityGroup<br /> {<br /> param (<br /> [parameter(Mandatory = $true)][string] $UserName,<br /> [parameter(Mandatory = $true)][string] $Password,<br /> [parameter(Mandatory = $true)][string] $GroupName,<br /> [parameter(Mandatory = $true)][string] $AccountSkuId)<br /> <br /> Import-Module MSOnline<br /> <br /> $securePassword = ConvertTo-SecureString $Password -AsPlainText -Force<br /> $userCredentials = New-Object System.Management.Automation.PSCredential($UserName, $securePassword)<br /> Connect-MsolService -Credential $userCredentials<br /> <br /> $groupId = (Get-MsolGroup | Where-Object {$_.DisplayName -eq $GroupName}).ObjectId<br /> $accountSku = Get-MsolAccountSku | Where-Object {$_.AccountSKUID -eq $AccountSkuId}<br /> <br /> if($accountSku -eq $null)<br /> { <br /> Write-Error 'Invalid Account Sku, Please get the account information from Get-MsolAccountSku'<br /> RETURN<br /> }<br /> <br /> Write-Output "Getting unlicensed users for Group Guid: $GroupID"<br /> <br /> $usersInGroup = (Get-MsolGroupMember -GroupObjectId $groupId -All).EmailAddress<br /> <br /> Write-Output 'Setting license to: ' $usersInGroup.Count<br /> foreach ($currentUserInGroup in $usersInGroup) <br /> {<br /> try <br /> {<br /> $currentUser = Get-MsolUser -UserPrincipalName $currentUserInGroup<br /> if($currentUser.UsageLocation -eq $null)<br /> {<br /> Write-Warning "Current User $currentUserInGroup does not have Usage Location, please set it using Set-MsolUser commandlet"<br /> continue;<br /> }<br /> <br /> if(($currentUser).Licenses | Where-Object {$_.AccountSkuId -eq $accountSku.AccountSkuId})<br /> {<br /> Write-Warning "Current User $currentUserInGroup is Already Licensed."<br /> continue;<br /> }<br /> <br /> Set-MsolUserLicense -UserPrincipalName $currentUserInGroup -AddLicenses $accountSku.AccountSkuId -ErrorAction Stop -WarningAction Stop<br /> Write-Output "Successfully licensed $currentUserInGroup with $AccountSkuId"<br /> } <br /> catch <br /> {<br /> Write-Warning "Error when licensing $currentUserInGroup"<br /> }<br /> }<br /> }</code></pre>
<p><a href="https://msdnshared.blob.core.windows.net/media/MSDNBlogsFS/prod.evol.blogs.msdn.com/CommunityServer.Components.PostAttachments/00/10/58/80/01/SetLicenseToUsersInSecurityGroup.ps1" original-url="https://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-10-58-80-01/SetLicenseToUsersInSecurityGroup.ps1">SetLicenseToUsersInSecurityGroup.ps1</a></p>]]></content:encoded>
    </item>
    <item>
      <title>Getting Process ID for specific Application Pools</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/getting-process-id-for-specific-application-pools</link>
      <pubDate>Mon, 06 Oct 2014 10:59:00 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2014/10/06/getting-process-id-for-specific-application-pools/</guid>
      <description><![CDATA[The other day I was debugging a web site and&nbsp;thought to myself "how can I know to which Process...]]></description>
      <content:encoded><![CDATA[<p>The other day I was debugging a web site and&nbsp;thought to myself "how can I know to which Process ID to attach to"? well I came across to the following:</p>
<p style="padding-left: 30px;">C:\windows\system32\inetsrv\appcmd.exe list wp</p>
<p>This command will list all the available application pools along with their process Id, now you can go and attach to the process specific to the application pool you are trying to debug</p>
<p>&nbsp;</p>]]></content:encoded>
    </item>
    <item>
      <title>Installing dll into GAC with PowerShell</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/installing-dll-into-gac-with-powershell</link>
      <pubDate>Mon, 06 Oct 2014 10:20:00 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2014/10/06/installing-dll-into-gac-with-powershell/</guid>
      <description><![CDATA[You may install a dll into the GAC (global assembly cache) by doing the...]]></description>
      <content:encoded><![CDATA[<p>You may install a dll into the GAC (global assembly cache) by doing the following:</p>
<pre class="scroll"><code class="cplusplus">[Reflection.Assembly]::LoadWithPartialName("System.EnterpriseServices") | Out-Null <br />[System.EnterpriseServices.Internal.Publish] $publish = new-object System.EnterpriseServices.Internal.Publish<br />$publish.GacInstall(&lt;&lt;FullFilePathToTheDll&gt;&gt;)<br /> </code></pre>
<p>This has to do very little with native PowerShell but rather with instantiating and using .NET libraries from PowerShell</p>
<p>&nbsp;</p>]]></content:encoded>
    </item>
    <item>
      <title>Debugging Optimized Code in .NET</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/debugging-optimized-code-in-net</link>
      <pubDate>Mon, 06 Oct 2014 10:14:37 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2014/10/06/debugging-optimized-code-in-net/</guid>
      <description><![CDATA[Sometime back I found myself trying to remotely debug a program thru visual studio, and while trying...]]></description>
      <content:encoded><![CDATA[<p>Sometime back I found myself trying to remotely debug a program thru visual studio, and while trying to access the value of one of the variables I got a message saying "Cannot evaluate expression because the code of the current method is optimized"... turns out that there are compilation flags&nbsp;that instruct the JIT to optimize the code (usually on release builds) and thus some variables will not be available during debugging.&nbsp; You may instruct the JIT not to optimize the code by doing the following:</p>
<p>Let's say that you have:</p>
<ul>
<li>DLLYouWantToDebug.dll</li>
<li>DLLYouWantToDebug.pdb</li>
</ul>
<p>&nbsp;Then you will create a new text file with the same&nbsp;name as the dll you are trying to debug but with "ini" extension, example:</p>
<ul>
<li>DLLYouWantToDebug.ini</li>
</ul>
<p>Open this file with Notepad and insert the following text in it:</p>
<p style="padding-left: 30px;"><em>[.NET Framework Debugging Control]</em><br /><em>GenerateTrackingInfo=1</em><br /><em>AllowOptimize=0</em></p>
<p>&nbsp;</p>
<p>This will override the optimization flag and then you will be able to see all the variable values</p>
<p>&nbsp;</p>
<p><strong>Disclaimer!</strong></p>
<p>Please note that this is not intended for production usage!</p>
<p>&nbsp;</p>
<p><strong>References</strong></p>
<p><strong><a href="https://msdn.microsoft.com/en-us/library/9dd8z24x(v=vs.110).aspx">https://msdn.microsoft.com/en-us/library/9dd8z24x(v=vs.110).aspx</a></strong></p>
<p><strong></strong>&nbsp;</p>
<p><strong>The following PowerShell will disable the optimization for the files in a folder or a specific dll/exe.</strong></p>
<pre class="scroll"><code class="cplusplus">Function Set-OptimizationConfigurationFiles<br /> {<br /> param (<br /> [parameter(Mandatory = $true)][ValidateScript ({Test-Path $_})][string] $PathToDeploymentFolder,<br /> [parameter(Mandatory = $false)][string] $SpecificDll)<br /> <br /> $allDllFiles = Get-ChildItem -Path $pathToDeploymentFolder | Where-Object {($_.Name -like '*.dll' -or $_.Name -like '*.exe') -and ($SpecificDll -eq $null -or $_.Name -eq $SpecificDll)}<br /> <br /> foreach($currentDllFile in $allDllFiles)<br /> {<br /> $fileName = $currentDllFile.BaseName<br /> $iniFullFileName = $currentDllFile.DirectoryName + '\' + $fileName + '.ini'<br /> <br /> '[.NET Framework Debugging Control]' &gt; $inifullFileName<br /> 'GenerateTrackingInfo=1' &gt;&gt; $inifullFileName<br /> 'AllowOptimize=0' &gt;&gt; $inifullFileName<br /> }<br /> }</code></pre>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>]]></content:encoded>
    </item>
    <item>
      <title>Hello World!</title>
      <link>https://docs.microsoft.com/archive/blogs/miguelnunez/hello-world</link>
      <pubDate>Thu, 21 Aug 2014 09:56:12 GMT</pubDate>
      <dc:creator><![CDATA[MiguelNunez]]></dc:creator>
      <guid
        isPermaLink="false">https://blogs.msdn.microsoft.com/miguelnunez/2014/08/21/hello-world/</guid>
      <description><![CDATA[This is my first post... So.... Hello World!, I'm a Software Developer, I'm proudly Born and Raised...]]></description>
      <content:encoded><![CDATA[<p>This is my first post... So.... Hello World!, I'm a Software Developer, I'm proudly Born and Raised Mexican and I find myself currently working at Microsoft as a Software Developer.&nbsp; I studied in Mexico on the Autonomous University of Baja California, I have a degree on computer engineering.&nbsp;&nbsp;Since I graduated I have been working mostly in .NET&nbsp;in various kinds of projects that goes from ASP.NET, Windows Forms, WPF, Windows Services, WCF.</p>
<p>I was inspired to open this blog from all the day-to-day experiences of a normal developer.</p>]]></content:encoded>
    </item>
  </channel>
</rss>