This project is read-only.

Character not valid Assemblyinfo

Oct 18, 2012 at 7:44 PM

Trying to use the AssemblyInfo Activity and I am setting the AssemblyFileVersion to


Which gives me an error "Character Invalid for the first $ sign it also gives me an error for the formatting of the date YYYY is not declared or may be inaccessible due to its protection level

THis is in VS 2012

Any ideas on what I am doing wrong?

Also I would like to get the build number and use that in the revision number and I dont see how to pass that nto the activity.

Oct 19, 2012 at 1:36 PM


If you pass this value directly to the AssemblyFileVersion property, have you enclosed it in double quotes : "$(current).$(current).$(increment).$(date:yyyy)" ?

The AssemblyFileVersion property is of type InOutArgument<string> and when passing a constant string value it must be between double quotes.


Oct 19, 2012 at 8:22 PM

If I put it in double quotes I get the error "Compiler error(s) encountered processing expression ""$(current).$(current).$(increment).$(date:yyyy)"".Invalid L-value expression

Oct 24, 2012 at 10:29 AM


I could not reproduce your bug, could you attach a sample workflow where this bug happens ?



Oct 25, 2012 at 5:18 PM


I have the same problem in Visual Studio 2012, please try the following:

- add a new empty workflow

- place a single AssemblyInfo activity there

- fill in its AssemblyCompany - set it egz. to "aaa" (including double quotes)

Now blue exclamation mark icon appears on the right side of property editor with tooltip: "The left-hand side of an assignment must be a variable, property or indexer". The same problem occurs in other properties. In real workflow for TFS builder the tooltip message is "Invalid L-value expression" as nanderto wrote.

Oct 29, 2012 at 7:37 PM

I am having the same problem in Visual Studio 2012. 

Nov 26, 2012 at 6:21 PM

I am having this issue in 2010. Are your instructions missing information on variables or arguments that need to be created in order for the process to reference them?

Nov 29, 2012 at 8:01 PM

Yes, I'm also seeing this same problem (VS 2012).  Has anyone resolved it?

Dec 9, 2012 at 4:52 PM



Can someone send a link to a template with this issue or raise an issue.





Dec 13, 2012 at 5:50 PM
Edited Dec 13, 2012 at 5:51 PM

I have created issue 11429 for this problem. It has a build template and screenshot. Please contact me for any other information that you may need. I created the build template after following the directions on the AssemblyInfo wiki page.

Dec 15, 2012 at 2:51 AM

I too am getting the same problem.  When entering a string, such as "$(current).$(current).$(current).$(increment)" in AssemblyVersion or FileAssemblyVersion, I get the error: Invalid L-value expression.


Does anyone have an example of a build template that works in setting these properties?

Dec 18, 2012 at 9:37 AM


The "Invalid L-value expression" error is due to the recent change where we introduced the Get/Set action. All parameters have changed from an InArgument to an InOutArgument to allow reading the values.

Unfortunately a side effect is that you can no more pass constant values but you need to pass variables.


Feb 27, 2013 at 5:12 PM
@GuillaumeRouchon - So how does this affect the instructions: How to integrate the AssemblyInfo build activity?

How do we use the tokens $(current), $(increment) from a variable?
Apr 17, 2013 at 3:31 PM
Edited Apr 17, 2013 at 3:32 PM
WORKAROUND (Invalid L-value expression error):
  • Define a string variable myVar
  • Use an "Assign" activity (tab "Primitives") to assign the token string to myVar
  • Use myVar instead of the string when configuring the AssemblyInfo activity