<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx</link><description>REI recently posted some comments/requests about Windows PowerShell syntax at: http://blogs.msdn.com/powershell/archive/2006/04/25/583273.aspx#675133 Let's go through a few of the points. ...the syntax was just way too cryptic and unintuitive. Often it's</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#675591</link><pubDate>Sun, 23 Jul 2006 13:39:26 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:675591</guid><dc:creator>David</dc:creator><description>Hello&lt;br&gt;&lt;br&gt;I am not sure if there is a bug register for PowerShell, and I hope you do not mind me posting it here.&lt;br&gt;&lt;br&gt;$a = &amp;quot;6&amp;quot;&lt;br&gt;$a = 0 + $a + 3&lt;br&gt;&lt;br&gt;Now, $a is eq 9, as expected&lt;br&gt;&lt;br&gt;$a = &amp;quot;6&amp;quot;&lt;br&gt;$a = 0 + $a * 3&lt;br&gt;&lt;br&gt;Now, $a is eq 666, not 18 as expected&lt;br&gt;&lt;br&gt;Is this a bug?&lt;br&gt;&lt;br&gt;Thanks</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#675769</link><pubDate>Sun, 23 Jul 2006 17:44:55 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:675769</guid><dc:creator>swrdfghtr</dc:creator><description>Thanks, Jeffery. This is precisely the sort of detailed, insider explanation that administrators are unaccustomed to getting from Microsoft. Even if we don't necessarily agree with a design decision, it's so incredibly useful to know about the scenario and backstory that resulted in that decision. This sort of transparency is deeply refreshing.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#675790</link><pubDate>Sun, 23 Jul 2006 18:28:04 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:675790</guid><dc:creator>n4cer</dc:creator><description>David, one issue with your example is that you are not using integers, but strings.&lt;br&gt;&lt;br&gt;$a = &amp;quot;6&amp;quot;&lt;br&gt;is a string as denoted by the quotes.&lt;br&gt;$a = 6&lt;br&gt;is an integer.&lt;br&gt;&lt;br&gt;I believe the other issue involves parsing modes and operator precedence.&lt;br&gt;&lt;br&gt;When PowerShell sees $a = 0 + $a + 3&lt;br&gt;PowerShell processes from left to right, first evaluating 0+$a, which puts PowerShell in Expression mode and gives the integer value of 6. Then it adds 3 to 6 and assigns the result to $a.&lt;br&gt;&lt;br&gt;However, when PowerShell sees $a = 0 + $a * 3&lt;br&gt;PowerShell first processes $a * 3 because the multiplication operator has higher precedence. This puts PowerShell into Command (or Argument) mode and the result is a string operation since $a is the first token and it is a string. This gives you the string &amp;quot;666&amp;quot;. Then 0 + $a is evaluated. 0 is first so PowerShell evaluates in Expression mode, turning the string &amp;quot;666&amp;quot; into the integer value 666. Likewise, if the 0 had been a 1, you'd have gotten the intger value 667.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#675795</link><pubDate>Sun, 23 Jul 2006 18:38:11 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:675795</guid><dc:creator>n4cer</dc:creator><description>Forgot to add that you can change the order of evaluation by using parentheses. So if you had $a = (0 + $a) * 3&lt;br&gt;then 0 + $a would be evaluated first rather than $a * 3, so PowerShell would have evaluated the expression in Expression mode as in your first example because the integer 0 is the first token. Thus $a would be converted to an integer and you would get the integer value 18 rather than the string value &amp;quot;666&amp;quot;.</description></item><item><title>Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#675903</link><pubDate>Sun, 23 Jul 2006 21:22:15 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:675903</guid><dc:creator>Rod Trent at myITforum.com</dc:creator><description>&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/powershell/archive/2006/07/23/Issues_with_Windows_PowerShell_syntax.aspx"&gt;http://blogs.msdn.com/powershell/archive/2006/07/23/Issues_with_Windows_PowerShell_syntax.aspx&lt;/a&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#676078</link><pubDate>Mon, 24 Jul 2006 01:37:10 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:676078</guid><dc:creator>David</dc:creator><description>Hello again&lt;br&gt;&lt;br&gt;The example &lt;br&gt;&lt;br&gt;$a = &amp;quot;6&amp;quot;&lt;br&gt;$a = 0 + $a + 3&lt;br&gt;&lt;br&gt;is in the documentation for Powershell. I would never use this sort of code. I was just trying to better understand the consequences of this sort of code. I thought it was interesting that &amp;nbsp;each of these:&lt;br&gt;&lt;br&gt;$a = 0 + $a + 3&lt;br&gt;$a = 0 + $a - 3&lt;br&gt;$a = 0 + $a / 3&lt;br&gt;&lt;br&gt;results in the expression mode, and the calculation being performed. But this :&lt;br&gt;&lt;br&gt;$a = 0 + $a * 3&lt;br&gt;&lt;br&gt;results in command mode, and the strings being concatenated, and the zero being dropped off as well. Shouldn't the &amp;quot;0 +&amp;quot; cause an exception when it is performed after the string manipulation, in command mode? It sounds like it just forgets the &amp;quot;0 +&amp;quot;&lt;br&gt;&lt;br&gt;So I can see why the multiply-equals results in the string multiplication. I can see why the divide results in the expression mode (there is no /= function for strings. But I would say that the documentation is a little bit wrong. It states:&lt;br&gt;&lt;br&gt;&amp;quot;In an assignment, the first element of the right hand side determines whether strings or integers are the result. &amp;nbsp;If an explicit requirement for an integer exists, preface the right hand side with &amp;quot;0 +&amp;quot; or cast the right hand side to a number, followed by the rest of the expression.&amp;quot;&lt;br&gt;&lt;br&gt;According to that statement, &amp;quot;$a = 0 + $a * 3&amp;quot; should result in &amp;nbsp;expression mode.&lt;br&gt;&lt;br&gt;Anyway, I think this code is dangerous, and should not be done, firstly because it is not good practice, and secondly because it is not explicit, and thirdly because this proves that the outcome is unpredictable.&lt;br&gt;&lt;br&gt;Thanks</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#676324</link><pubDate>Mon, 24 Jul 2006 07:33:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:676324</guid><dc:creator>n4cer</dc:creator><description>OK, I get what you're saying now.&lt;br&gt;&lt;br&gt;In the statement $a = 0 + $a * 3, PowerShell won't evaluate the 0 first. Due to higher precedence for multiplication it will evaluate $a * 3 first, get &amp;quot;666&amp;quot;, then evaluate 0 + $a (or 0 + &amp;quot;666&amp;quot;). The zero is the first element in the evaluation so PowerShell uses Expression mode and the result is an integer which is why the result is 666 and not &amp;quot;6660&amp;quot;. If you instead use the expression ($a * 3) + 0, then the evaluation after $a * 3 would be &amp;quot;666&amp;quot; + 0. Here, the string &amp;quot;666&amp;quot; is the first element, so PowerShell evaluates the expression in Command mode and the result is &amp;quot;6660&amp;quot;.&lt;br&gt;&lt;br&gt;You're right. The docs could be clearer about order of evaluation due to precedence, and how the existance (or lack thereof) of certain operators can affect parsing and evaluation. PowerShell will always take these factors into account and the first element in an expression will not always be the first element to be evaluated.&lt;br&gt;&lt;br&gt;I don't think it's a bug. It's similar to what would occur in C++, C#, etc., if you evaluated 2 + 6 * 3 vs (2 + 6) * 3. In the first example, 6*3 is first evaluated, whereas 2+6 is evaluated first in the second example, each yielding different results due to operator precedence. This type of pitfall affects more scenarios in PowerShell, however, due to its greater flexibility in type conversion and different parsing modes. In most programming languages, you'd have to perform the type conversion explicitly.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#676353</link><pubDate>Mon, 24 Jul 2006 08:33:35 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:676353</guid><dc:creator>David</dc:creator><description>Thanks n4cer&lt;br&gt;&lt;br&gt;Yes, I think it is a issue with the documentation, not a bug. But it points out the inconsistencies within a language that does not have strict type checking. Good luck debugging stuff like this. I prefer a strict type checking language so that you know what you are getting.&lt;br&gt;&lt;br&gt;I totally understand the need to have a more flexible option in a command line interface. It just means the coder has to know what they are doing.&lt;br&gt;&lt;br&gt;Like the documentation says, the confusion can be avoided by applying a strict type to the variable when it is created:&lt;br&gt;&lt;br&gt;[int]$a = &amp;quot;6&amp;quot;&lt;br&gt;$a = $a * 3&lt;br&gt;&lt;br&gt;results in the calculation being performed, even with the implicit type conversion.&lt;br&gt;&lt;br&gt;Thanks</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#676432</link><pubDate>Mon, 24 Jul 2006 10:50:05 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:676432</guid><dc:creator>Rei Miyasaka</dc:creator><description>Thanks for the reply, Jeff. I'm just as glad as you that you've taken the time to give a real explanation as to how things are done.&lt;br&gt;&lt;br&gt;I don't like to beat a dead horse, but let me explain my thoughts further...&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;quot;As such, we view functions as just another implementation choice for writing COMMANDS (not methods). &amp;nbsp;This is why we surface them using COMMAND syntax. &amp;nbsp;That said, we've brainstormed the idea of allowing either syntax because a number of people have stumbled on this point.&amp;quot;&lt;br&gt;&lt;br&gt;So will there be a command or registry value or something that I can change to switch modes? What happens when I'm reading someone's code and trying to understand it, or when I run someone else's script when I'm using the other setting?&lt;br&gt;&lt;br&gt;&lt;br&gt;That's great that you're making new a keyword. In the future, will I be able to say arraylist(), or are the brackets going to throw it off the way it does right now?&lt;br&gt;&lt;br&gt;The problem with the current situation is that we get an error saying that an expression was expected after the '('... which, to most of us OOP programmers, is an all too familiar error, but makes no sense in this context. I stumbled around for quite a while until I realized that constructors can't have the () when it doesn't take any arguments.&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;quot;Sure, we can all agree that Get-Members makes more sense than Get-Member but then how is someone from Korea &amp;nbsp;suppose to guess that it should be Get-ChildREN vs get-ChildS ?&amp;quot;&lt;br&gt;&lt;br&gt;As a Japanese-English translator, I guarantee that although you will often hear Japanese and Koreans mistaking singulars and plurals, this is rarely a problem for a computer user's purposes. Two reasons for this:&lt;br&gt;1. Even though most Japanese people have a hard time knowing _how_ to use plurals, most of them know one when they see one.&lt;br&gt;2. Because most of the time the plural form of a word is made by adding a character or two to the end of the word, the tab key solves this problem very well. Hungarian notation was thrown out in .NET thanks to Intellisense and is now frowned upon, so problems such as these that can be solved by UI advances are bound to suffer the same fate in the near future.&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;quot;Predictability is critical for a command line environment.&amp;quot;&lt;br&gt;&lt;br&gt;Unfortunately, the no-plurals policy doesn't resolve lack of predictability enough to be meaningful at all. Synonyms are so abundant in English that we'll end up looking up the documentation (or hitting tab) anyway.&lt;br&gt;&lt;br&gt;I don't mean to alienate non-English users, but I think being consistent with standard English as well as with the rest of the .NET platform would make it more predictable.&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;quot;The other reason why we stick with the singular tense is that it is often unknown whether a command provides a value or a set of values.&lt;br&gt;&lt;br&gt;True, but in the get-process example, if there are two instances of notepad, a method expecting a Diagnostics.Process object would break. It would be much more informative to know when a method _might_ return multiple objects, in which case we will know to either 1. make sure the call would yield only a single result -- perhaps by specifying a handle rather than a name, or 2. make sure the receiving function/script/etc can handle collections.&lt;br&gt;&lt;br&gt;Without knowing that the command can return multiple values we, are more likely to accidentally use it in a way that might in an off-chance return multiple values. I think both users and developers would be set back by this.&lt;br&gt;&lt;br&gt;&lt;br&gt;Thanks again for the detailed response. I'd love to hear from you more sometime, by email if another blog entry on the same topic would be inconvenient. My address is ragingrei hotmail.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#676455</link><pubDate>Mon, 24 Jul 2006 11:45:07 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:676455</guid><dc:creator>PowerShellTeam</dc:creator><description>&amp;gt; So will there be a command or registry value or something that I can change to switch modes? What happens when I'm reading someone's code and trying to understand it, or when I run someone else's script when I'm using the other setting? &lt;br&gt;&lt;br&gt;No. &amp;nbsp;IF we supported this, we would just allow either syntax.&lt;br&gt;&lt;br&gt;&amp;gt; In the future, will I be able to say arraylist()&lt;br&gt;&lt;br&gt;yes. You'll be able to say:&lt;br&gt; &amp;nbsp;$a = new ArrayList()&lt;br&gt;&lt;br&gt;&amp;gt; Even though most Japanese people have a hard time knowing _how_ to use plurals, most of them know one when they see one. &lt;br&gt;&lt;br&gt;Therein lies the problem. &amp;nbsp;With envrionments like Visual Studio, you will SEE things (via intellisense) and be able to RECOGNIZE them. &amp;nbsp;With a command line environment, you have to RECALL what to type. &amp;nbsp;RECOGNITION VS RECALL is the central theoretical split between GUI and CLI environments.&lt;br&gt;&lt;br&gt; I think being consistent with standard English as well as with the rest of the .NET platform would make it more predictable. &lt;br&gt;&lt;br&gt;&amp;gt; I think being consistent with standard English as well as with the rest of the .NET platform would make it more predictable. &lt;br&gt;&lt;br&gt;If our primary customers were developers, I'd agree with you however our primary customers are Admins/IT Pros who we assume will not have much/any knowledge of .NET. &amp;nbsp;Now that said, one of our explicit goals was to met the needs of those users in a way that provided a smooth glide path to .NET but that is a secondary design consideration.&lt;br&gt;&lt;br&gt;&lt;br&gt;Cheers!&lt;br&gt;Jeffrey Snover [MSFT]&lt;br&gt;Windows PowerShell/Aspen Architect&lt;br&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;br&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;&lt;br&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#679267</link><pubDate>Wed, 26 Jul 2006 21:14:59 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:679267</guid><dc:creator>Tshell</dc:creator><description>I am having a problem trying to figure out how to pass a varible to &amp;quot;where.&amp;quot;&lt;br&gt;&lt;br&gt;Senario: I have an XML file that contains all my Microsoft Product ID's. I want a function that will parse the XML file for a given product and return the PID.&lt;br&gt;&lt;br&gt;Example:&lt;br&gt;Function GetPIDS&lt;br&gt;{&lt;br&gt; &amp;nbsp;$pids = [xml] (Get-Content \\NDISDEV\Data$\AdminTools\Pids.xml)&lt;br&gt; &amp;nbsp;$pids.Product_Keys.PID | where {$_.Name -like $args} | Format-Table Name,Key&lt;br&gt;}&lt;br&gt;&lt;br&gt;Problem: where doesnt seem to like $args. I have tried $args, &amp;quot;$args&amp;quot;, and '$args'. It failes with all of them. &amp;nbsp;&lt;br&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#679290</link><pubDate>Wed, 26 Jul 2006 21:37:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:679290</guid><dc:creator>PowerShellTeam</dc:creator><description>This is a bug. If you assign $args to another variable like&lt;br&gt;&lt;br&gt;$myargs = $args&lt;br&gt;&lt;br&gt;and then use that variable in the scriptblock &amp;nbsp;instead of $args it should work ok. What's happening is that where-object invokes the scriptblock with $sb.Invoke() so $args is reset in the scriptblock.&lt;br&gt;&lt;br&gt;-bruce&lt;br&gt;&lt;br&gt;Bruce Payette [MSFT]&lt;br&gt;PowerShell Technical Lead</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#679298</link><pubDate>Wed, 26 Jul 2006 21:43:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:679298</guid><dc:creator>PowerShellTeam</dc:creator><description>Assign $args to a local variable and use it:&lt;br&gt;&lt;br&gt;Function GetPIDS &lt;br&gt;{ &lt;br&gt; $x = $args&lt;br&gt; $pids = [xml] (Get-Content \\NDISDEV\Data$\AdminTools\Pids.xml) &lt;br&gt; $pids.Product_Keys.PID | where {$_.Name -like $x[0]} | Format-Table Name,Key &lt;br&gt;} &lt;br&gt;&lt;br&gt;Jeffrey Snover [MSFT]&lt;br&gt;Windows PowerShell/Aspen Architect&lt;br&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;br&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;&lt;br&gt;&lt;br&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#680266</link><pubDate>Thu, 27 Jul 2006 17:08:12 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:680266</guid><dc:creator>James</dc:creator><description>I encountered a problem with the globbing syntax that I couldn't solve. Filenames containing [] characters are almost impossible to manipulate because the names are treated as regular expressions. I'm not trying to match a character class: the filename really contains square brackets.&lt;br&gt;&lt;br&gt;The worst thing is that often such mistakes are completely silent: some files just don't get processed. It's really quite dangerous.&lt;br&gt;&lt;br&gt;After wasting two hours by constructing various alternatives involving pipelines to try to prevent interpretation of strings as filespecs, of trying to escape the filenames before they're interpreted, and of reading documentation to try to find a way of avoiding wildcard expansion, I gave up with PowerShell and haven't used it since. I'd be really interested in knowing the solution, though.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#686413</link><pubDate>Wed, 02 Aug 2006 16:19:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:686413</guid><dc:creator>James</dc:creator><description>I thought I'd provide an example of the problem. In an empty directory, try this:&lt;br&gt;&lt;br&gt; &amp;nbsp; new-item [test] -type file&lt;br&gt; &amp;nbsp; get-childitem | remove-item&lt;br&gt;&lt;br&gt;The file [test] is not deleted. Of course, in this case, remove-item * is an acceptable substitute, but in my case I had 'where-item' in the pipeline (and I was actually trying to archvie the items somewhere safe).&lt;br&gt;&lt;br&gt;It was a surprise to find that a pipe of objects wasn't equivalent to specifying those same objects with wildcards. A lot of programs use suffixes like [1] on filenames, and this is causing me problems.&lt;br&gt;&lt;br&gt;Another observation. If you try:&lt;br&gt; &amp;nbsp; move-item -path * -destination newname&lt;br&gt;&lt;br&gt;You get the error:&lt;br&gt; &amp;nbsp; Move-Item : Cannot move item because item at 'Some\Path\[test]' does not exist.&lt;br&gt;&lt;br&gt;Hm. I'm stuck.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#699840</link><pubDate>Mon, 14 Aug 2006 20:36:12 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:699840</guid><dc:creator>PowerShellTeam</dc:creator><description>Hi James;&lt;br&gt;&lt;br&gt;We are aware of some pretty big usability issues with special characters in the current release. &amp;nbsp;We've spent a lot of time improving PowerShell in this area since then, which you should see in the next drop.&lt;br&gt;&lt;br&gt;Lee</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#706741</link><pubDate>Sat, 19 Aug 2006 02:31:45 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:706741</guid><dc:creator>Michael</dc:creator><description>Having suffered from the same problems as James, it's good to hear that you're working on it. I just want to say that so far PowerShell is really great and thank you so much for listening to user concerns and responding.</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#706816</link><pubDate>Sat, 19 Aug 2006 03:15:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:706816</guid><dc:creator>Jeffrey Snover</dc:creator><description>&amp;gt; thank you so much for listening to user concerns and responding. &lt;br&gt;&lt;br&gt;You guys are the customers. &amp;nbsp;Talk and we'll listen. &amp;nbsp;&lt;br&gt;We want you to be the happiest campers in the forest. &amp;nbsp;:-)&lt;br&gt;&lt;br&gt;Jeffrey Snover [MSFT]&lt;br&gt;Windows PowerShell/Aspen Architect&lt;br&gt;Visit the Windows PowerShell Team blog at: &amp;nbsp; &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/PowerShell"&gt;http://blogs.msdn.com/PowerShell&lt;/a&gt;&lt;br&gt;Visit the Windows PowerShell ScriptCenter at: &amp;nbsp;&lt;a rel="nofollow" target="_new" href="http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx"&gt;http://www.microsoft.com/technet/scriptcenter/hubs/msh.mspx&lt;/a&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#2099152</link><pubDate>Thu, 12 Apr 2007 15:56:39 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2099152</guid><dc:creator>halr9000</dc:creator><description>&lt;p&gt;I have a question on how/why you guys chose the syntax for comparision and logical operators. &amp;nbsp;(I'm quoting the quick reference guide that comes with 1.0.)&lt;/p&gt;
&lt;p&gt;I'd much rather use:&lt;/p&gt;
&lt;p&gt;if a==b {}&lt;/p&gt;
&lt;p&gt;then:&lt;/p&gt;
&lt;p&gt;if a -eq b {}&lt;/p&gt;
&lt;p&gt;And you support ! for not, but not &amp;amp;&amp;amp; and || for &amp;quot;and&amp;quot; and &amp;quot;or&amp;quot;, respectively? &amp;nbsp;&lt;/p&gt;
&lt;p&gt;And along the same lines, why did you choose &amp;quot;`&amp;quot; (backquote) to escape characters, rather than the more common &amp;quot;\&amp;quot;?&lt;/p&gt;
&lt;p&gt;I'm a sysadmin, not a programmer, and I don't like having to memorize all these inconsistencies. &amp;nbsp;(Comparing command shell scripts, vbscript, jscript, etc.)&lt;/p&gt;
&lt;p&gt;Thanks for the great work though, I do appreciate the new features.&lt;/p&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#2503195</link><pubDate>Wed, 09 May 2007 16:26:32 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:2503195</guid><dc:creator>Mike Blake-Knox</dc:creator><description>&lt;p&gt;I ran into this article while looking for a description of PowerShell expression syntax. Where is the expression documentation mentioned (several times) above?&lt;/p&gt;
&lt;p&gt;It would be REALLY nice if it happened to be a complete PowerShell reference (included, for example, a description of begin/process/end statement blocks.&lt;/p&gt;
&lt;p&gt;Thanks&lt;/p&gt;
&lt;p&gt;Mike&lt;/p&gt;</description></item><item><title>re: Issues with Windows PowerShell syntax</title><link>http://blogs.msdn.com/powershell/archive/2006/07/23/Issues-with-Windows-PowerShell-syntax.aspx#8116815</link><pubDate>Sun, 09 Mar 2008 12:19:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8116815</guid><dc:creator>Greg</dc:creator><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;I have also a problem with powershell :)&lt;/p&gt;
&lt;p&gt;Concerning regular expression, here is my code: &amp;nbsp; &amp;nbsp;&lt;/p&gt;
&lt;p&gt;$objEntry = [ADSI]''&lt;/p&gt;
&lt;p&gt;foreach ($objOU in $objEntry.psbase.Children)&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;if ($objOU.Name -match &amp;quot;^(\w+)$&amp;quot;)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;$matches[0]&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt;}&lt;/p&gt;
&lt;p&gt;I try to get all organizational unit with matching the regular expression.&lt;/p&gt;
&lt;p&gt;In that case, variable $matches is not populated. What's append ? How can i fix the problem ?&lt;/p&gt;
&lt;p&gt;Thx !&lt;/p&gt;</description></item></channel></rss>