expression

Editing a xaml icons or images

Is it possible to edit a xaml icons or images in the expression design or using other tools? Is it possible to import a xaml images (that e.g you have exported) in the expression designer for editing? ...

Are these jQuery expressions equivalent?

I'm wondering if these two expressions are equivalent, because if they are, it would make this much easier. $('div', this).filter(':not(.trigger)')... $('div:not([class*=trigger])', this)... (this providing a context under which to look for the specified div) ...

Silverlight DataGrid Property error - "The member "AutoGenerateColumns" is not recognized or is not accessible"

I am trying to modify a Datagrid in Expression Blend 3 using Silverlight 3 tools. When I attepmt to open the file Blend shows the "Invalid XAML" error and in the XAML shows errors on certain properties within the DataGrids declaration. <my:DataGrid x:Name="dataGridLegals" AutoGenerateColumns="False" GridLinesV...

Boolean Expression Evaluation in Java

Hey everyone, Is there a relatively simpler (when compared with writing a parser) way to evaluate boolean expressions in Java? I do not want to use the JEP library. I have a String expression something like: (x > 4 || x < 8 && p > 6) [ I will replace the variables with values. Is there a way by which I can evaluate this expression? The ...

C comma operator

Why is the expression specified inside a comma operator (such as the example below) not considered a constant expression? For example, int a = (10,20) ; when given in global scope yields an error "initializer is not a constant", though both the expressions separated by a comma operator are constants (constant expressions). Why is th...

Expression Encoder 3: Green artifacts after encoding

Some of the videos I encode using the Expression Encoder 3.0 have green lines at the bottom. Since I have no prior experience with encoding, I have no clue about why this is happening. Though I think it might have something to do with the format of the videos I am encoding. I am using some very basic code: DirectoryInfo dInfo = new Dire...

Embed a JQuery expression inside a css file??

As the question implies, can I add a JQuery script inside an css file as an expression? Or something like: .parent{ background-color: pink; position:relative; width: 100%; } .child{ position: absolute; background: transparent url('./background.gif') no-repeat top right; /*height: 100%;*/ height: expression($(this).parent.height...

Do all parts of a SQL SERVER expression using 'OR' get evaluated?

Given: WHERE (@Id Is NULL OR @Id = Table.Id) If @Id is null: the expression evaluates to true. Does the second part @Id = Table.Id still get considered? or is it sufficient that the expression evaluates to true given that the first part is (which is the case in c#). This is relevant because of some much more complex OR statements whe...

JSP EL (Expression Language) causing problems in Eclipse

My system: Ubuntu 9.10. Eclipse 3.5.1 with Java EE 1.2.1 (manual install - NOT from synaptic). Web Developer Tools 3.1.1 I've recently adopted someone else's code (a Dynamic Web Project), and run into lots of errors, warnings and incorrect syntax highlighting in Eclipse. I've narrowed it down to these 4 lines of code (create a new Dynam...

Linq Query Expression reuse

Post Edited Would this be possible ? Have a query expression that is precompiled i.e private static Func<SmwrDataContext, int, IQueryable<Xyz>> _validXyzs = CompiledQuery.Compile((Context context, int Id) => from xyz in _db.XYZs join abc in _db.ABCs on xyz.Id equa...

php - regex hostname extraction

I have been looking around for a regex expression that will spit out just the 'stackoverflow' part and no www. or .com etc. All I could find was to check if the url's were valid... I have used php's url filter to determine that much I now am looking to determine which site it is. I have never written an expression before so I am hoping ...

Expression Encoder SDK - WMA Pro Codec Issues with Windows Server 2003

I am using the Expression Encoder SDK to encode .avi and Flash files to a .wmv format suitable for Silverlight. By default, EE encodes files with audio using the the WMA PRO codec. If you are running Windows Server 2003, this is a problem as it doesn't support the WMA PRO codec and produces and error message similar to the following. ...

sql complex like expression @user

im trying to find all the mentions for the matched username (sam) from the database text code with following: $sql = "select * from tweet where feed like '%@sam%'"; this will return all the rows which user have been mention at. but now the problem is, it also returns rows with @sam3, @sam-dadf or anything that is after @sam.. how c...

PowerShell: how *exactly* does the RHS of the -f operator work?

Last time I got confused by the way PowerShell eagerly unrolls collections, Keith summarized its heuristic like so: Putting the results (an array) within a grouping expression (or subexpression e.g. $()) makes it eligible again for unrolling. I've taken that advice to heart, but still find myself unable to explain a few esoterica. ...

Why could an Expression's Body in C#.net not use properties of type int, double or bool?

I have a function: private string GetPropertyName(Expression<Func<object, object>> f) { if ((f.Body as MemberExpression) != null) { return (f.Body as MemberExpression).Member.Name; } return ""; } And it is used this way: string x1 = GetPropertyName(x => Property1); string x2 = GetPropertyName(x => Property2); str...

Creating Regular Expressions in Python

Hi All, I'm trying to create regular expression that filters from the following partial text: amd64 build of software 1:0.98.10-0.2svn20090909 in archive what I want to extract is: software 1:0.98.10-0.2svn20090909 How can I do this?? I've been trying and this is what I have so far: p = re.compile('([a-zA-Z0-9\-\+\.]+)\ ([0-9\:\...

.NET Expression SDK LiveJob Authentication

I'm trying to stream a live feed to a Publishing Point but keep getting 'Access is Denied' errors. I can do this just fine in the Expression Encoder application (using a valid username and password). But when I try to use the same username/password in my custom app, I get that error. I've tried pre-connecting without credentials, whic...

Disjunctive normal form with range predicate

Hey! I need a library/algorithm that can transform an arbitrary logical expression that contains range predicates into a reduced disjoint normal form. Example : (x > 40) & ( (x > 50) | (y > 10)) -> (x > 50) | (x > 40) & (y > 10) Basically, what I want to simply such an expression in order to evaluated as fast as possible. Anyone c...

nested regular expressions in python

In perl I can do this: $number = qr/ zero | one | two | three | four | five | six | seven | eight | nine /ix; $foo = qr/ quantity: \s* $number /ix; My actual regular expression is many lines and does two-digit and ordinal numbers (e.g., "twenty-two", "forty-fourth" and "twelve are all complete matches), and I use it in several places....

Linq Lambda Expression

I am trying to do this on a method which is basically a mapper - maps old categories List to a new List. The OldCategory has fewer properties. return categories = from c in oldCategories select new Category { CategoryName = c.CategoryName, Id = c.CategoryId, Teams = CombineTeam(c.Team, coreTeam) }; Why can't I use CombineTeam met...