Daily Archives

Articles indexed Friday August 22 2014

Page 4/19 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Doing imagemagick like stuff in Unity (using a mask to edit a texture)

    - by Codejoy
    There is this tutorial in imagemagick http://www.imagemagick.org/Usage/masking/#masks I was wondering if there was some way to mimic the behavior (like cutting the image up based on a black image mask that turns image parts transparent... ) and then trim that image in game... trying to hack around with the webcam feature and reproduce some of the imagemagick opencv stuff in it in Unity but I am saddly unequipped with masks, shaders etc in unity skill/knowledge. Not even sure where to start.

    Read the article

  • How to make rigid bodies collide with Apex Clothing in PhysX for Maya

    - by b1nary.atr0phy
    According to the [Apex] Clothing Overview section of the documentation: Colliding with Rigid Bodies Rigid bodies present in your scene will push clothing around roughly as you might expect. Well, I beg to differ. The Apex Cloth collides with the floor just fine, but that's about the only thing it collides with (unless I add ragdoll to the same skeleton that the cloth is attached to.) So for example, if I try to bounce a ball (dynamic rigid body) into the cloth, it simply bounces through it. If I try to walk an actor with ragdoll through it, he simply clips through it as well. Anyone have any insight on this?

    Read the article

  • Set Position of multiple bodies

    - by philipp
    I have a character composed of five bodies which are tied together by a lot of joints. On of them is the overall chassis, to which all forces and impulses are applied to move the whole Character. All in all that works very fine, except one thing: I need to set the Position of the Character so that it get Beamed from one place to the other in one single frame. Unfortunately I cannot get this to work. I tried the following code, without any success… playerbodies.forEach(function (bd) { bd.SetLinearVelocity(new b2.Vec2()); var t = bd.GetTransform(); t.p.x -= 10; bd.SetTransform(t, bd.GetAngle()); }); How can I make that happen?

    Read the article

  • XNA Diffuse Shader Issue. Edge lighting problem. Image Attached

    - by adtither
    As you can see in this image the diffuse shading is working correctly in some places but in other places such as the the bottom of the sphere you can see the squares/triangles of the mesh. Any idea what would be causing this? Let me know if you need anymore information related to code. I can upload my normals calculations and shader effect if required. EDIT: Here's a link to the shader I'm using http://pastebin.com/gymVc7CP Link to normals calculations: http://pastebin.com/KnMGdzHP Seems to be an issue with edge lighting. Can't seem to see where I'm going wrong with the normals calculations though.

    Read the article

  • Long delays in Unity3D substance generation

    - by Josh Buhler
    Currently working on an iOS/Android project in Unity3d, and we're seeing some incredibly long times for generating substances between testing runs. We can run the game, but once we shut down the playback, Unity begins to re-import all off the substances built using Substance Designer. As we've got a lot of these in our game, it's starting to lead to 5 minute delays between testing runs just to test a small change. Any suggestions or parameters we should check that could possibly prevent Unity from needing to regenerate these substances every time? Shouldn't it be caching these things somewhere?

    Read the article

  • Jasmine DOM test using jasmine jquery with require module

    - by Purushoth
    I am using custom variant of jasmine 2.0 from here https://github.com/erikringsmuth/jasmine2-amd-specrunner. So that testing my require.js based application made possible. Here i have facing problem with using jasmine-jquery. The jasmine object is undefined. $ and window is fine. function (window, jasmine, $) I have reference added jasmine and jquery lib too <script type="text/javascript" src="lib/jasmine.js"></script> <script type="text/javascript" src="lib/jquery-2.1.1.min.js"></script> <script type="text/javascript" src="lib/helpers/jasmine-jquery.js"></script>

    Read the article

  • Not able to click on all the links in Selenium Webdriver.Only the first link gets clicked

    - by Kiran
    .i want to go to a frame in which some links are there....Once I come in to a fram.i want to click all the links one by one..using webdriver...below is the code i have written.plz suggest me public static void main(String[] args) { // TODO Auto-generated method stub WebDriver driver=new FirefoxDriver(); driver.get("http://timesofindia.indiatimes.com/home"); WebDriverWait wait= new WebDriverWait(driver,200); wait.until(ExpectedConditions.presenceOfElementLocated(By.id("riShop"))); driver.switchTo().frame("riShop"); List<WebElement> lst=driver.findElements(By.tagName("a")); for(inti=0;i<lst.size();i++){ lst.get(i).click(); driver.navigate().back(); } } } } In the above code....only the first link gets clicked and then i get exception like..unable to locate the next element.....NoSuchException plz suggest me something about it...

    Read the article

  • IIS 8 - PHP Manager - Enabling php_oci8.dll for Oracle Connection

    - by Jemru
    I would need to connect to Oracle DB in my PHP codes. I'm using Windows Server 2012, IIS 8 with PHP Manager. I opened IIS PHP Manager, then go to PHP Extensions, then I enabled "php_oci8.dll" extension. However when I tried to connect to Oracle DB I'm getting the following PHP error: PHP Fatal error: Call to undefined function oci_connect() I just restarted the IIS using the IIS Manager, but didn't done computer reboot. Do I need to reboot? Do I also need to download "instantclient-basic-windows.x64-12.1.0.1.0.zip"? If yes, do I just need to set it to classpath "Path" where I extracted? Thank you very much in advance.

    Read the article

  • HTML email image inverts on link click Outlook 07/10/13

    - by Matt Maclennan
    I'm having an issue on a HTML email in Word rendered Outlooks (2007, 2010, 2013) where I click an image link, and when the mouse is clicked, the image inverts... Here is the code below... <td align="left" width="360" valign="top" style="mso-table-lspace: 0pt; mso-table-rspace: 0pt; border-collapse: collapse;" class="hide"> <a href="#" target="_blank"> <img src="test.jpg" width="360" height="528" alt="alt tag" style="display:block;" class="img_mob centertable" border="0" align="left"> </a> </td> Here is a comparison on the image clicked/not clicked... I have tried putting a text-decoration: none on the link. All the links are styled inline as well. This is the only image that it is having this issue on the email, so tried re-saving the image with no luck. The image is saved as a JPEG and SRGB from a Photoshop PSD. Any ideas? Thanks.

    Read the article

  • How to filter List<T> with LINQ and Reflection

    - by Ehsan Sajjad
    i am getting properties via reflection and i was doing like this to iterate on the list. private void HandleListProperty(object oldObject, object newObject, string difference, PropertyInfo prop) { var oldList = prop.GetValue(oldObject, null) as IList; var newList = prop.GetValue(newObject, null) as IList; if (prop.PropertyType == typeof(List<DataModel.ScheduleDetail>)) { List<DataModel.ScheduleDetail> ScheduleDetailsOld = oldList as List<DataModel.ScheduleDetail>; List<DataModel.ScheduleDetail> ScheduleDetailsNew = newList as List<DataModel.ScheduleDetail>; var groupOldSchedules = ScheduleDetailsOld .GroupBy(x => x.HomeHelpID) .SelectMany(s => s.DistinctBy(d => d.HomeHelpID) .Select(h => new { h.HomeHelpID, h.HomeHelpName })); } } Now i am making it generic because there will be coming different types of Lists and i don't want to put if conditions this way i want to write generic code to handle any type of list. I came up with this way: private void HandleListProperty(object oldObject, object newObject, string difference, PropertyInfo prop) { var oldList = prop.GetValue(oldObject, null) as IList; var newList = prop.GetValue(newObject, null) as IList; var ListType = prop.PropertyType; var MyListInstance = Activator.CreateInstance(ListType); MyListInstance = oldList; } i am able to get the items in MyListInstance but as the type will come at runtime i am not getting how to write linq query to filter them, any ideah how to do.

    Read the article

  • How to handle duplicate values in d3.js

    - by Mario
    First I'm a d3.js noob :) How you can see from the title I've got a problem with duplicated data and aggregate the values is no option, because the name represent different bus stops. In this example maybe the stops are on the fron side and the back side of a building. And of course I like to show the names on the x-axis. If i created an example and the result is a bloody mess, see jsFiddel. x = index name = bus stop name n = value I've got a json e.g.: [{ "x": 0, "name": "Corniche St / Abu Dhabi Police GHQ", "n": 113 }, { "x": 1, "name": "Corniche St / Nation Towers", "n": 116 }, { "x": 2, "name": "Zayed 1st St / Al Khalidiya Public Garden", "n": 146 }, ... { "x": 49, "name": "Hamdan St / Tariq Bin Zeyad Mosque", "n": 55 }] The problem: It is possible that the name could appear more then once e.g. { "x": 1, "name": "Corniche St / Nation Towers", "n": 116 } and { "x": 4, "name": "Corniche St / Nation Towers", "n": 105 } I like to know is there a way to tell d3.js not to use distinct names and instead just show all names in sequence with their values. Any ideas or suggestions are very welcome :) If you need more information let me know. Thanks in advanced Mario

    Read the article

  • how I can convert the string output into data.frame

    - by user2968058
    i have a data set called SIZEDIST$AVG.µm., and i have fitted this data with a weibull curve. now i have generated the quantiles by using the quantile function and now i want to access the output of this function generated at the interval of p=0.01. fwbl<-fitdist(SIZEDIST$AVG.µm., "weibull",start=list(shape=0.8,scale=1)) fwbl quantwbl<-quantile(fwbl,probs=seq(.1,.99,.01)) quantwbl str(quantwbl) using str(quantwbl) i can visualize the output but i cant convert them into data.frame

    Read the article

  • Passing Data of WebView to Another Activity

    - by meygraph
    I've designed a training program and Html texts and image put into training. I want to address my html file by an activity to sent another activity. This is MainActivity /* * ListView item click listener. So we'll have the do stuff on click of * our ListItem */ listViewArticles.setOnItemClickListener(new OnItemClickListener() { public void onItemClick(AdapterView<?> parent, View view, int position, long id) { switch (position) { case 0: Intent newActivity0 = new Intent(TrickPage.this,a_Dotted_Lines.class); startActivity(newActivity0); break; case 1: Intent newActivity1 = new Intent(TrickPage.this,TutorialsPage.class); startActivity(newActivity1); break; case 2: Intent newActivity2 = new Intent(TrickPage.this,TutorialsPage.class); startActivity(newActivity2); break; case 3: Intent newActivity3 = new Intent(TrickPage.this,TutorialsPage.class); startActivity(newActivity3); break; default: // Nothing do! } and this SecondActivity (show WebView) public class a_Dotted_Lines extends Activity { private WebView webView; @SuppressLint("SetJavaScriptEnabled") @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.a_dotted_lines); // Button HOME ImageButton ImageButton_home = (ImageButton) findViewById(R.id.ImageButton_home); ImageButton_home.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { Intent intent = new Intent(); intent.setClass(a_Dotted_Lines.this, Main.class); startActivity(intent); overridePendingTransition(R.anim.fadein, R.anim.fadeout); } }); //Button Previous ImageButton ImageButton_previus = (ImageButton) findViewById(R.id.ImageButton_previus); ImageButton_previus.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View v) { //Closing SecondScreen Activity finish(); } }); webView = (WebView) findViewById(R.id.webview_compontent); webView.getSettings().setJavaScriptEnabled(true); webView.loadUrl("file:///android_asset/html/article.htm"); } } I want Send "file:///android_asset/html/article.htm" or other addres from MainActivity Is it possible? Sorry My English is not good

    Read the article

  • Play audio file data - Spring MVC

    - by Vijay Veeraraghavan
    In my web-application, I have various audio clips uploaded by the users in the database stored in the BLOB column. The audio files are low bit rate WAV files. The clips are secured, one can see only those clips he has uploaded. Instead of user downloading the clip and playing it in his player, I need it be steamed online in the web page itself. In the jsp I use the <audio> tag with the source mapping to the controller mappping url. <td> <audio controls><source src="recfile/${au.id}" type="audio/mpeg" /></audio> </td> Where, the recfile is the request mapping and the au.id is the audio id. In the controller I process the request like below @RequestMapping(value = "/recfile/{id}", method = RequestMethod.GET, produces = { MediaType.APPLICATION_OCTET_STREAM_VALUE }) public HttpEntity<byte[]> downloadRecipientFile(@PathVariable("id") int id, ModelMap model, HttpServletResponse response) throws IOException, ServletException { LOGGER.debug("[GroupListController downloadRecipientFile]"); VoiceAudioLibrary dGroup = audioClipService.findAudioClip(id); if (dGroup == null || dGroup.getAudioData() == null || dGroup.getAudioData().length <= 0) { throw new ServletException("No clip found/clip has not data, id=" + id); } HttpHeaders header = new HttpHeaders(); I tried this too //header.setContentType(new MediaType("audio", "mp3")); header.setContentType(new MediaType("audio", "vnd.wave"); header.setContentLength(dGroup.getAudioData().length); return new HttpEntity<byte[]>(dGroup.getAudioData(), header); } When the jsp loads, the controller get the request, it serves back the audio data fetched from the database, the jsp too shows the player with the controls. But when I play it nothing happens. Why is it? Am I missing anything in the configuration? Am I doing it right?

    Read the article

  • Scanner's Read Line returning NoSuchElementException

    - by Brian
    This is my first time using StackOverflow. I am trying to read a text file which consists of a single number one the first line. try { Scanner s = new Scanner(new File("HighScores.txt")); int temp =Integer.parseInt(s.nextLine()); s.close(); return temp; } catch (FileNotFoundException e) { // TODO Auto-generated catch block e.printStackTrace(); } However, I get an error: java.util.NoSuchElementException: No line found at java.util.Scanner.nextLine(Unknown Source) at GameStart.getHighScore(GameStart.java:334) at GameStart.init(GameStart.java:82) at sun.applet.AppletPanel.run(Unknown Source) at java.lang.Thread.run(Unknown Source) I know that HighScores.txt is not empty, so why is this problem occuring? I tried using BufferedReader, and BufferReader.readLine() return null.

    Read the article

  • jquery ajax call in onsubmit function is not working

    - by shilna mk
    I have form submission page add_sale.php and an ajax page ajx_check_sale.php.Ajax call is inthe onsubmit function.But ajax is not worikng.Anybody give any solution plz.. I have form submission page add_sale.php and an ajax page ajx_check_sale.php.Ajax call is inthe onsubmit function.But ajax is not worikng.Anybody give any solution plz.. add_sale.php function sale_credit(id) { var cust_name=$('#cust_name').val(); $.ajax({ type: "POST", url: 'ajx_typ1.php', data:'id='+id, success: function(msg) { $("#sale_type1").html(msg); } }); $.ajax({ type: "POST", url: 'ajx_typ3.php', data:'id='+id, success: function(msg) { $("#sale_type3").html(msg); } }); $.ajax({ type: "POST", url: 'ajx_typ2.php', data:'id='+id, success: function(msg) { $("#sale_type2").html(msg); } }); } function validate_form() { var cust_name= $('#cust_name').val(); var total= $('#total').val(); var sale_type= $('#sale_type').val(); if(sale_type=='return') { $.ajax({ type: "POST", url: 'ajx_check_sale.php', data:'cust_name='+cust_name + '&total=' + total, success: function(msg) { alert(msg); /*if(msg==0) { alert("Return is greater then sale"); return false; } */ } }); } } <form action="" method="post" name="adFrm" onSubmit="return validate_form()"> <select name="sale_type" style="width:130px;" id="sale_type" onchange="sale_credit(this.value)" > <option value="">Select</option> <option value="credit">Credit</option> <option value="payment">Payment</option> <option value="return">Return</option> </select> </form> ajx_check_sale.php require_once("codelibrary/inc/variables.php"); require_once("codelibrary/inc/functions.php"); echo $cust_name=$_POST['cust_name']; echo $return=$_POST['total']; $cus="select sum(total) as total_sum from customer where id='$cust_id'"; $cus2=mysql_query($cus); $fet=mysql_fetch_array($cus2); $total=$fet['total_sum']; if($return>$total) { $status=0; echo $status; } else { $status=1; echo $status; }

    Read the article

  • HttpWebRequest possibly slowing website

    - by Steven Smith
    Using Visual studio 2012, C#.net 4.5 , SQL Server 2008, Feefo, Nopcommerce Hey guys I have Recently implemented a new review service into a current site we have. When the change went live the first day all worked fine. Since then though the sending of sales to Feefo hasnt been working, There are no logs either of anything going wrong. In the OrderProcessingService.cs in Nop Commerce's Service, i call a HttpWebrequest when an order has been confirmed as completed. Here is the code. var email = HttpUtility.UrlEncode(order.Customer.Email.ToString()); var name = HttpUtility.UrlEncode(order.Customer.GetFullName().ToString()); var description = HttpUtility.UrlEncode(productVariant.ProductVariant.Product.MetaDescription != null ? productVariant.ProductVariant.Product.MetaDescription.ToString() : "product"); var orderRef = HttpUtility.UrlEncode(order.Id.ToString()); var productLink = HttpUtility.UrlEncode(string.Format("myurl/p/{0}/{1}", productVariant.ProductVariant.ProductId, productVariant.ProductVariant.Name.Replace(" ", "-"))); string itemRef = ""; try { itemRef = HttpUtility.UrlEncode(productVariant.ProductVariant.ProductId.ToString()); } catch { itemRef = "0"; } var url = string.Format("feefo Url", login, password,email,name,description,orderRef,productLink,itemRef); var request = (HttpWebRequest)WebRequest.Create(url); request.KeepAlive = false; request.Timeout = 5000; request.Proxy = null; using (var response = (HttpWebResponse)request.GetResponse()) { if (response.StatusDescription == "OK") { var stream = response.GetResponseStream(); if(stream != null) { using (var reader = new StreamReader(stream)) { var content = reader.ReadToEnd(); } } } } So as you can see its a simple webrequest that is processed on an order, and all product variants are sent to feefo. Now: this hasnt been happening all week since the 15th (day of the implementation) the site has been grinding to a halt recently. The stream and reader in the the var content is there for debugging. Im wondering does the code redflag anything to you that could relate to the process of website? Also note i have run some SQL statements to see if there is any deadlocks or large escalations, so far seems fine, Logs have also been fine just the usual logging of Bots. Any help would be much appreciated! EDIT: also note that this code is in a method that is called and wrapped in A try catch UPDATE: well forget about the "not sending", thats because i was just told my code was rolled back last week

    Read the article

  • how to get category value from xml params?

    - by C-link Nepal
    I have the following field in xml: <field name="cat1" type="category" extension="COM_CONTENT" label="MOD_ITEM_CAT1" description="MOD_ITEM_CAT_DESC" /> Now, I wanted to get selected value: echo $params->get('cat1'); Which shows me 8 (the value of selected option) not it's title. I've category title people and it should show people instead of 8. So, how to extract the title of the category?

    Read the article

  • Loading specific files from arbitrary directories?

    - by Haydn V. Harach
    I want to load foo.txt. foo.txt might exist in the data/bar/ directory, or it might exist in the data/New Folder/ directory. There might be a different foo.txt in both of these directories, in which case I would want to either load one and ignore the other according to some order that I've sorted the directories by (perhaps manually, perhaps by date of creation), or else load them both and combine the results somehow. The latter (combining the results of both/all foo.txt files) is circumstantial and beyond the scope of this question, but something I want to be able to do in the future. I'm using SDL and boost::filesystem. I want to keep my list of dependencies as small as possible, and as cross-platform as possible. I'm guessing that my best bet would be to get a list of every directory (within the data/ folder), sort/filter this list, then when I go to load foo.txt, I search for it in each potential directory? This sounds like it would be very inefficient, if I have dozens of potential directories to search through every time. What's the best way to go about accomplishing this? Bonus: What if I want some of the directories to be archives? ie. considering both data/foo/ and data/bar.zip to both be valid, and pull foobar.txt from either one without caring.

    Read the article

  • php code is not fetching data from mysql database using wamp server

    - by john
    I want to display a table from database in phpMyAdmin by putting the following conditions that in every different options in drop down menu it displays different table from database by pressing the button of search. But it is not doing so. <p class="h2">Quick Search</p> <div class="sb2_opts"> <p></p> <form method="post" action="" > <p>Enter your source and destination.</p> <p>From:</p> <select name="from"> <option value="Islamabad">Islamabad</option> <option value="Lahore">Lahore</option> <option value="murree">Murree</option> <option value="Muzaffarabad">Muzaffarabad</option> </select> <p>To:</p> <select name="To"> <option value="Islamabad">Islamabad</option> <option value="Lahore">Lahore</option> <option value="murree">Murree</option> <option value="Muzaffarabad">Muzaffarabad</option> </select> <input type="submit" value="search" /> </form> </form> </table> <?php $con=mysqli_connect("localhost","root","","test"); if (mysqli_connect_errno()) { echo "Failed to connect to MySQL: " . mysqli_connect_error(); } if(isset($_POST['from']) and isset($_POST['To'])) { $from = $_POST['from'] ; $to = $_POST['To'] ; $table = array($from, $to); switch ($table) { case array ("Islamabad", "Lahore") : $result = mysqli_query($con,"SELECT * FROM flights"); echo "</flights>"; //table name is flights break; case array ("Islamabad", "Murree") : $result = mysqli_query($con,"SELECT * FROM isb to murree"); echo "</isb to murree>"; //table name isb to murree ; break; case array ("Islamabad", "Muzaffarabad") : $result = mysqli_query($con,"SELECT * FROM isb to muzz"); echo "</isb to muzz>"; break; //..... //...... default: echo "Your choice is nor valid !!"; } } mysqli_close($con); ?>

    Read the article

  • activemq round robin between queues or topics

    - by forkit
    I'm trying to achieve load balancing between different types of messages. I would not know in advance what the messages coming in might be until they hit the queue. I know I can try resequencing the messages, but I was thinking that maybe if there was a way to have the various consumers round robin between either queues or between topics, this would solve my problem. The main problem i'm trying to solve is that I have many services sending messages to one queue with many consumers feeding off one queue. I do not want one type of service monopolizing the entire worker cluster. Again I don't know in advance what the messages that are going to hit the queue are going to be. To try to clearly repeat my question: Is there a way to tell the consumers to round robin between either existing queues or topics? Thank you in advance.

    Read the article

  • Android & Google Maps - close info window with back button

    - by m4ch3t3
    I have an activity that holds a fragment with Google Map view in it. App adds several dozens of markers to the MapView, using MarkerManager and ClusterRenderer to form clusters. The problem is that when I have marker's InfoWindow opened and I press hardware Back button, it closes the app. Instead of that, I would like to have the InfoWindow closed. Is there any straightforward way to achieve this?

    Read the article

  • Yii 'limit' on related model's scope

    - by pethee
    I have a model called Guesses that has_many Comments. I'm making eager queries to this to then pass on as JSON as response to an API call. The relations are obviously set between the two models and they are correct(one2many <= belongs2) I added a scope to Comments called 'api' like this: public function scopes() { return array( 'api' => array( 'select' => 'id, comment, date', 'limit'=>3, 'order'=>'date DESC', 'together'=>true, ), ); } And I'm running the following one-liner query: $data = Guesses::model()->with('comments:api')->findAll(); The issue here is that when calling the 'api' scope using a with('relation'), the limit property simply doesn't apply. I added the 'together'=true there for another type of scope, plus I hear it might help. It doesn't make a difference. I don't need all the comments of all Guesses. I want the top 3 (or 5). I am also trying to keep the one-liner call intact and simple, manage everything through scopes, relations and parameterized functions so that the API call itself is clean and simple. Any advice?

    Read the article

  • Getting repeat values after copying 2-3 items to clipboard in android?

    - by Gurpreet singh
    I am using clipboard code like below in my app.Everything is working fine if i copy one item at a time.But when we copy 2-3 items one after other and paste somewhere it starts retrieving repeated past value from clipboard rather than the current value.After googling a lot i came to know that its a problem with Samsung phones and i need to clear clipboard history for that.But i could not find any way to clear clipboard history. Public void CopyToClipboard { int pos = (Integer) v.getTag(); StatusEntity obj=getItem(pos); ClipboardManager clipmanager= (ClipboardManager)getContext().getSystemService(getContext().CLIPBOARD_SERVICE); ClipData clip=ClipData.newPlainText("data",obj.getStatus()); clipmanager.setPrimaryClip(clip); Toast.makeText(getContext(), "Copied to clipboard", 1000).show(); } Hoping that anyone of you can help me regarding this .Any help would be appreciated.

    Read the article

  • Field annotated multiple times by the same attribute

    - by Jaroslaw Waliszko
    For my ASP.NET MVC application I've created custom validation attribute, and indicated that more than one instance of it can be specified for a single field or property: [AttributeUsage(AttributeTargets.Field | AttributeTargets.Property, AllowMultiple = true)] public sealed class SomeAttribute: ValidationAttribute I've created validator for such an attribute: public class SomeValidator : DataAnnotationsModelValidator<SomeAttribute> and wire up this in the Application_Start of Global.asax DataAnnotationsModelValidatorProvider.RegisterAdapter( typeof (SomeAttribute), typeof (SomeValidator)); Finally, if I use my attribute in the desired way: [SomeAttribute(...)] //first [SomeAttribute(...)] //second public string SomeField { get; set; } when validation is executed by the framework, only first attribute instance is invoked. Second one seems to be dead. I've noticed that during each request only single validator instance is created (for the first annotation). How to solve this problem and fire all attributes?

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >