filter

How to automatically update filter and/or sort order on CollectionViewSource, when an individual item's property changes?

Ok, so this question is related to Windows Phone 7/Silverlight (updated WP7 Tools, Sept 2010), specifically filtering an underlying ObservableCollection<T>. In mucking about with the WP7 template Pivot control application, I've run into an issue whereby changing an underlying item in an ObservableCollection<T>, does not result in the on...

Filtering out duplicate XElements based on an attribute value from a Linq query

I'm using Linq to try to filter out any duplicate XElements that have the same value for the "name" attribute. Original xml: <foo> <property name="John" value="Doe" id="1" /> <property name="Paul" value="Lee" id="1" /> <property name="Ken" value="Flow" id="1" /> <property name="Jane" value="Horace" id="1" /> <property name="Paul" value...

Add a select box on the right admin filter in django - how to do ?

Hi, I want to used select box on my admin filter on django. FOr now django used list_filter on the admin model, and add a list of all data list_filter = ('data') and show : filter data - data1 - data2 - ... but if i v thousand data, i see a big list drop down my admin page... Is it possible to show a select box with the lis...

How to select a single record based on a multivalued candidate key and synchronize subforms to work with that record?

Hi, In a parent-form, I filtered a table on a candidate key consisting of multiple values, so the result should give a single record. Now I can't get the subforms to synchronize to that. It keeps showing the same record (with the possibility to loop trough all values using the buttons) Either the applied filter does not work, or there i...

datatable:make serverside script for filter each column

i want to make my table can filtering in each column. i get client side script from DataTable.net. To make this work, i must make change at server side script for this datatable. My table fields is: Line, Model_name, Version, Lot, Serial_number, ID_number, Lot_no_S_Serial, and Prod_date. i have tried to syncronizing each column to this ...

ActionScript - Retrieving Index Of Specific Filter

i have a few filters on a sprite. on mouse over i would like to access one of the filters in the filters array, but i'm having a bit of trouble trying to accomplish this. mySprite.filters = [new DropShadowFilter(), new GlowFilter(), new BlurFilter()]; mySprite.addEventListener(MouseEvent.MOUSE_OVER, mouseOverEventHandler); function mo...

How to use ObjectQuery with Where filter separated by OR clause

Hi guys, Could somebody help me to answer how to rewrite raw SQL filter WHERE (...) OR (...) with ObjectQuery bilder, please? String queryRaw = "SELECT ls.LocaleName, ls.IsActive, ls.LocaleDescription " + "FROM RoutesEntities.Locales AS ls "; //" WHERE ls.LocaleName = 'en' OR ls.LocaleName = 'de' " ...

On Windows, how would you filter a packet sequence?

I'd like to filter a specific packet sequence, if not by process, then by IP address/port combination. Writing a DLL, modifying the process in question, or writing a program which hooks all functions isn't a viable solution; for whatever reason, hooking WSARecv fails. I considered IPSEC, but I'm not sure if that allows you to block the...

Twitter URL for returning /user_timeline Searches

I may be completely overlooking something but I can't seem to filter the user_timeline results by keyword in the REST api. example: http://twitter.com/status/user_timeline/starbucks.json?q=pumpkin returns all the results, not the ones filtered by the word 'pumpkin'. ...

How to change Drupal input filter behaviour based on output location

I have a Drupal filter module whose output I would like to alter, depending on where the output is going to be displayed. Specifically, I want to the filter to give the full output for nodes, but trim the content down for blocks. ...

filtering form inputs

I have a simple contact form with name, email, a select list, and textarea. In my mailer php script I'm trying to add a simple filter to prevent SQL injection or other forms of hacking. For example, I'm using $name = filter_input(INPUT_POST, 'name', FILTER_SANITIZE_SPECIAL_CHARS); Is this good? ...

PHP Array filter regular expressions

Hi all i have an array shown below Array ( [0] => http://api.tweetmeme.com/imagebutton.gif?url=http://mashable.com/2010/09/25/trailmeme/ [1] => http://cdn.mashable.com/wp-content/plugins/wp-digg-this/i/gbuzz-feed.png [2] => http://mashable.com/wp-content/plugins/wp-digg-this/i/fb.jpg [3] => http://mashable.com/wp-cont...

Use both PDO prepared statemnts and filter_var?

Hey guys, I'm learning OO PHP, and have been looking into PDO -- One thing I'm not clear on though is whether I should be using PDO prepared statements in conjunction with the filter_var() function or just by themselves. For instance, should I be doing $query = $database->connection->prepare("SELECT name FROM acounts WHERE id = :id LIMI...

How to filter accelerometer data from noise

Hello, attached is a plot of accelerometer data with 3 axis. The sudden bumps in the plot is the noise. I would like to get rid of them. So what filter should be used in this case ? If it is possible provide some pseudo code for it and explanation. Regards, Levon ...

IE 8 absolute positioned element outside its parent clipping problem

I have an absolute positioned div inside another absolute positioned div. The child div content is much bigger than the parent can contain. This is by design. I need the child div to spill out of its parent. It does so in every other browser except IE 8 (IE 7 looks OK, not sure) In IE8 the part of the child that is out of parent is clipp...

Drupal: ajax pager not working with views exposed filters

I have several views (block displays) on my site and I've noticed that the ones without exposed filters have working ajax pagers. For some reason the views with exposed filters seem to keep the ajax pager from working for that view. The option is set to "yes" in the view so it's not just a simple oversight. My question would be: Does aj...

I'm looking for specific matrices to plug into a convolution matrix

Assuming I already have a working convolution matrix algorithm in place, I'm looking for practical examples of general matrices that are useful for image processing in particular. The canonical examples you'll find everywhere are non-gaussian box blur: 1 1 1 1 1 1 1 1 1 Image sharpening: 0 -1 0 -1 5 -1 0 -1 0 Edge detec...

Rails plugin to filter abuse words / expletives ?

I've been looking, but can't seem to find a RoR plugin/gem for filtering out abuse words / expletives from strings. Do you know of a RoR plugin that does this? Ps. I do understand that there are many ways that such words can be displayed (like shit, shït, shıt, śhit, and śhiŧ). If a plugin can filter out such "words" as well, that's a...

Tomcat compression is disabled when custom filters are used

I have a question regarding the use of Tomcat 6.0.14, and the interaction between the Tomcat built in compression, and custom filters. I am just using Tomcat - with no http server in front. My problem is that when I enable my filter, the compression seems to be disabled. This is observed by examining the output from a Fiddler trace. An...

using for each loop in visual basic for developers in excel to copy on visible values

Hey all, I would like to use a for each loop in excel to copy only all visible values in my excel spreadsheet in order to remove the link from the auto filtering so that when I export or copy these values, the hidden values from the auto filter don't come back. Here's macro: Sub sortify() Application.ScreenUpdating = False Range("A...