Search Results

Search found 1870 results on 75 pages for 'matt mcclellan'.

Page 37/75 | < Previous Page | 33 34 35 36 37 38 39 40 41 42 43 44  | Next Page >

  • Comparing two List<MyClass> in C#

    - by Matt
    I have a class called MyClass This class inherits IEquatable and implements equals the way I need it to. (Meaning: when I compare two MyClass tyupe objects individually in code, it works) I then create two List: var ListA = new List<MyClass>(); var ListB = new List<MyClass>(); // Add distinct objects that are equal to one another to // ListA and ListB in such a way that they are not added in the same order. When I go to compare ListA and ListB, should I get true? ListA.Equals(ListB)==true; //???

    Read the article

  • Mibble MIB Parser - extracting comments from the mib.

    - by this.matt
    I am using the Mibble MIB Parser to extract all simple data types from an MIB file. I've been successful until my attempt to extract comment text. Take the following module as an example: invBookList OBJECT-TYPE SYNTAX INTEGER { mobydick(1), -- call me ishmael paradiselost(2), -- aComment 1984(3), -- aComment solaris(4) -- aComment } MAX-ACCESS read-only STATUS current DESCRIPTION "A few Books for an example." ::= { invMasterList 43 } According to Mibble's API, the OBJECT-TYPE can be accessed by extracting an SnmpObjectType and then calling the appropriate getter method. Which I have done, and can successfully extract all of the text except the comments in the INTEGER syntax. I have tried calling getSyntax().getComment() on the SnmpObjectType, but always returns null. getSyntax() will extract the INTEGER syntax, e.g.: mobydick(1),paradiselist(2),1984(3),solaris(4) but unfortunately strips out the comments. Any one out there have experience with Mibble Parser who knows how to extract the comments? Many Thanks.

    Read the article

  • How to make Fluent NHibernate ignore Dictionary properties

    - by Matt Winckler
    I'm trying to make Fluent NHibernate's automapping ignore a Dictionary property on one of my classes, but Fluent is ignoring me instead. Ignoring other types of properties seems to work fine, but even after following the documentation and adding an override for the Dictionary, I still get the following exception when BuildSessionFactory is called: The type or method has 2 generic parameter(s), but 1 generic argument(s) were provided. A generic argument must be provided for each generic parameter. I've tried overriding by property name: .Override<MyClass>(map => { map.IgnoreProperty(x => x.MyDictionaryProperty); }) and also tried implementing ignores using a custom attribute, both of which result in the same exception from BuildSessionFactory. The only thing so far that makes this exception go away is removing the Dictionary property entirely. My question seems to be identical to this one which was never answered (though I'll expand the scope by stating it doesn't matter whether the dictionary is on an abstract base class; the problem always happens for me regardless of what class the property is on). Any takers this time around?

    Read the article

  • Scrolling screen upward to expose TextView above keyboard

    - by Matt Winters
    I think I'm missing something obvious and would appreciate an answer. I have a view with a 2-section grouped tableView, each section having one row and a textView, the heights of the rows 335 and 140. This allows for a box with nicely rounded corners to type text into when the keyboard appears (140 height section) and when the keyboard is dismissed, a nice box to read more text (notes); most of the time, use is without the keyboard. I also added a toolbar at the bottom of the screen to scroll up above the keyboard. A button on the toolbar dismisses the keyboard. This last part works fine with the keyboard going up and down using a notification and the following code in a keyboardWillShow method: [UIView beginAnimations:@"showKeyboardAnimation" context:nil]; [UIView setAnimationDuration:0.50]; self.view.frame = CGRectMake(self.view.frame.origin.x, self.view.frame.origin.y, self.view.frame.size.width, self.view.frame.size.height - 216); [UIView commitAnimations]; But with the above code, the 2 sections of the tableView remain unscrolled, only the toolbar and the keyboard move. With the following code (found both in previous posts), both the toolbar and the tableView sections move. [UIView beginAnimations:nil context:NULL]; [UIView setAnimationDuration:0.50]; CGRect rect = self.view.frame; rect.origin.y -= 216; self.view.frame = rect; [UIView commitAnimations]; Now I know that I have to tweak the numbers to get the everything as I want it but my first question is what is substantively different between the 2 sets of code that the sections move in the 2nd but not in the 1st? The toolbar also moves with the 2nd code. The second question is, am I going to be able to scroll the smaller height section from off the screen to above the keyboard while at the same time moving the toolbar up just 216? Thanks

    Read the article

  • Hibernate vs JPA vs JDO - pros and cons of each?

    - by matt b
    I'm familiar with ORM as a concept, and I've even used nHibernate several years ago for a .NET project; however, I haven't kept up with the topic of ORM in Java and haven't had a chance to use any of these tools. But, now I may have the chance to begin to use some ORM tools for one of our applications, in an attempt to move away from a series of legacy web services. I'm having a hard time telling the difference betweeen the JPA spec, what you get with the Hibernate library itself, and what JDO has to offer. So, I understand that this question is a bit open-ended, but I was hoping to get some opinions on: What are the pros and cons of each? Which would you suggest for a new project? Are there certain conditions when it would make sense to use one framework vs the other?

    Read the article

  • UnsatisfiedLinkError: The specified procedure could not be found

    - by matt
    I'm writing some JNI code in C++ to be called from an applet on Windows XP. I've been able to successfully run the applet and have the JNI library loaded and called, even going so far as having it call functions in other DLLs. I got this working by setting up the PATH system environment variable to include the directory all of my DLLs are in. So, the problem, is that I add another call that uses a new external DLL, and suddenly when loading the library, an UnsatisfiedLinkError is thrown. The message is: 'The specified procedure could not be found'. This doesn't seem to be a problem with a missing dependent DLL, because I can remove a dependent DLL and get a different message about dependent DLL missing. From what I've been able to find online, it appears that this message means that a native Java function implementation is missing from the DLL, but it's odd that it works fine without this extra bit of code. Does anyone know what might be causing this? What kinds of things can give a 'The specified procedure could not be found' messages for an UnsatisifedLinkError?

    Read the article

  • Element binding in Silverlight

    - by Matt
    Where can I find some good documentation on data/element binding? My Google searches haven't turned much up. I had a custom class with two properties named Text and Value. When I tried binding a list to a listbox it wouldn't work. By chance I modifed my datatemplate from this <TextBox Text="{Binding Text}"></TextBox> to this <TextBox Text="{Binding Path=Text}"></TextBox> and then everything worked great. I need some indepth documenation/samples to data/element binding. I don't understand why some examples have the path set whereas others do not. A full explanation of this, and all other nice to know tips would be much appreciated.

    Read the article

  • Linq to SQL Error with Many-to-Many table

    - by Matt Connolly
    I am getting the following error with linq-to-sql when I try to access a many-to-many collection: Members 'Int32 XXX' and 'Int32 YYY' both marked as IsPrimaryKey and IsDbGenerated. The statement is true, in that both of those columns are primary key integers with identity insert. The table I am trying to access has a foreign key to both YYY and ZZZ, and then ZZZ has a foreign key to XXX. There doesn't appear to be anything wrong with my data structure. I tried setting "Child Property" to false on the ZZZ-YYY relationship, but it didn't change anything.

    Read the article

  • Implicitly invoking parent class initializer

    - by Matt Joiner
    class A(object): def __init__(self, a, b, c): #super(A, self).__init__() super(self.__class__, self).__init__() class B(A): def __init__(self, b, c): print super(B, self) print super(self.__class__, self) #super(B, self).__init__(1, b, c) super(self.__class__, self).__init__(1, b, c) class C(B): def __init__(self, c): #super(C, self).__init__(2, c) super(self.__class__, self).__init__(2, c) C(3) In the above code, the commented out __init__ calls appear to the be the commonly accepted "smart" way to do super class initialization. However in the event that the class hierarchy is likely to change, I have been using the uncommented form, until recently. It appears that in the call to the super constructor for B in the above hierarchy, that B.__init__ is called again, self.__class__ is actually C, not B as I had always assumed. Is there some way in Python-2.x that I can overcome this, and maintain proper MRO when calling super constructors without actually naming the current class?

    Read the article

  • Testing a Doctrine2 Entity with assertEquals results in fatal out-of-memory error

    - by Matt
    I have a PHPUnit test that's using a Doctrine2 custom repository and Doctrine Fixtures. I wanted to test that a query gave me back an expected entity from my fixture. But when I try $this->assertEquals($expectedEntity, $result);, I get Fatal error: out of memory. I'm guessing it is recursing into all the relations and the entity manager and whatnot. Is there a good way to test this equality? Should I just assertEquals on the IDs of the entities?

    Read the article

  • warnings emitted during 'easy_install'

    - by Matt Anderson
    When I easy_install some python modules, warnings such as: <some module>: module references __file__ <some module>: module references __path__ <some module>: module MAY be using inspect.trace <some module>: module MAY be using inspect.getsourcefile sometimes get emitted. Where (what package / source file) do these messages come from? Why is referencing __file__ or __path__ considered a bad thing?

    Read the article

  • Is there a W3C valid way to disable autocomplete in a HTML form?

    - by matt b
    When using the xhtml1-transitional.dtd doctype, collecting a credit card number with the following HTML <input type="text" id="cardNumber" name="cardNumber" autocomplete='off'/> will flag a warning on the W3C validator: there is no attribute "autocomplete". Is there a W3C / standards way to disable browser auto-complete on sensitive fields in a form?

    Read the article

  • Use ASP.Net server control code generation from .ashx

    - by Matt Dawdy
    I'm trying to take an existing bunch of code that was previously on a full .aspx page, and do the same stuff in a .ashx handler. The code created an HtmlTable object, added rows and cells to those rows, then added that html table the .aspx's controls collection, then added it to a div that was already on the page. I am trying to keep the code in tact but instead of putting the control into a div, actually generate the html and I'll return that in a big chunk of text that can be called via AJAX client-side. HtmlTable errors out when I try to use the InnerHtml property (says it isn't supported), and when I try RenderControl, after making first a TextWriter and next an HtmlTextWriter object, I get the error that Page cannot be null. Has anyone done this before? Any suggestions?

    Read the article

  • Using xsi:nil in XML

    - by Matt
    I am generating an XML file from a VB.NET app. The document was generating fine before I tried to add nillable elements. I am now testing putting in just one nil element as: <blah xsi:nil="true"></blah> Once this element is in place and I try to view the XML file in IE it is unable to display. I am receiving: > The XML page cannot be displayed > Cannot view XML input using XSL style > sheet. Please correct the error and > then click the Refresh button, or try > again later. > > -------------------------------------------------------------------------------- > > The operation completed successfully. > Error processing resource If I remove this one element it displays fine again. What am I missing here?

    Read the article

  • Flash/AIR AS3: comparing contents of Screen.screens

    - by matt lohkamp
    In a sane world, this works as expected: var array:Array = ['a','b','c]; trace(array.indexOf(array[0])); // returns 0 In an insane world, this happens: trace(Screen.screens.indexOf(Screen.screens[0])); // returns -1 ... if Screen.screens is an Array of the available instances of Screen, why can't that array give an accurate indexOf one of its own children? edit - apparently to get back to the world of the sane, all you have to do is this: var array:Array = Screen.screens; trace(array.indexOf(array[0])); // returns 0 Anyone know why?

    Read the article

  • mysql create table help with unique

    - by Matt
    I'm trying to create a table, and can't figure out how to assign two columns to be unique.. I know how to alter a table thats already created, but how do you do it in the create.. im after a create if not exist col1 TEXT, col2 TEXT, col3 TEXT unique(col1, col2) ^very rough basic but you get the idea

    Read the article

  • What does get-task-allow do in Xcode?

    - by Mr. Matt
    So when I set up my entitlements in my iPhone app project, I create a new Entitlements.plist, and set the value of get-task-allow to false. But why? What does this key represent? EDIT Note this is related to this question - I found that flipping the value of this key to true allowed me to install the app on my device)

    Read the article

  • Simple grid layout question

    - by Matt H.
    I can't believe I'm back to this after working with WPF for 3 months :) Consider very common setup: How do I configure the rowheights so that the top and bottom rows (menu bar and status bar) size to fit the height of their content, and the middle row (main content), fills the remaining available space in the program? I can't fix the height of the top/bottom rows because the height of their content can vary. <Window> <Grid> <Grid.RowDefinitions> <RowDefinition/> <RowDefinition/> <RowDefinition/> </Grid.RowDefinitions> <Menu Grid.Row=0> ...menuitems </Menu> <Grid Grid.Row=1> ...main application content here (like most programs) </Grid> <StatusBar> ...statusbaritems </StatusBar> </Grid> </Window>

    Read the article

  • Add a thousands separator to a total with Javascript or jQuery?

    - by Matt
    I have a function that sums a column of data in an html table. It does so admirably only I would like to have it put the commas in there that are needed to separate the thousands. Initially, you'll note, there are commas in the numbers being added. So that the function will add them, they are removed. How do I add the commas back in there? <script type="text/javascript"> function sumOfColumns(tableID, columnIndex, hasHeader) { var tot = 0; $("#" + tableID + " tr" + (hasHeader ? ":gt(0)" : "")) .children("td:nth-child(" + columnIndex + ")") .each(function() { tot += parseInt($(this).html().replace(',', '')); }); return "Total Pounds Entered : " + tot; } </script>

    Read the article

  • Flash AS3: crop TextField content off at X lines, add '...' at the end

    - by matt lohkamp
    There's only room for three lines of text in the interface, but the content is external and variable, and if it ends up taking up more than three lines, there needs to be some sort of 'view all' button functionality. I can kind of think about what that function needs to look like, but I'm not quite sure what the best way to do it in AS3 would be. Something like (in pseudo code): function cropText(source:TextField, length:int, append:String):TextField{ if(source.lineCount > length){ source.text = // magic function that retuns the first length lines, // minus append.length characters, with the append value tacked onto the end } return source; } ... right? How would you fill in the missing bit?

    Read the article

  • Struggling to make sense of some Objective-C code

    - by Matt
    I'm an Objective-C newbie and am enjoying reading/learning Objective-C in order to do iPhone development but I'm struggling to understand some of the code, especially the code that comes with the UIKit framework. For example, take this line: - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSelection:(NSInteger)section { ... I understand the parameters passed in but am struggling to understand the return parameter. Any help appreciated.

    Read the article

  • per build configuration files on iPhone ?

    - by Matt
    I'm looking for the best way to store per-Build configuration information for an iPhone app. In my iPhone app there are several url's and storage location settings that are specific to a particular build (DEBUG RELEASE etc) Currently i have three recipients for my app, QA/Test, myself and the customer, each has specific settings for the url's and storage locations mentioned above. whats the best way to do this? NOTE: they don't necessarily have to be defined in the build but what im looking for is advice on the best way to store alternate configuration settings. ALSO NOTE: i do not want these settings to be editable through the settings app thanks

    Read the article

  • Stack memory in Android

    - by Matt
    I'm writing an app that has a foreground service, content provider, and a Activity front end that binds to the service and gets back a List of objects using AIDL. The service does work and updates a database. If I leave the activity open for 4-8+ hours, and go to the "Running Services" section under settings on the phone (Nexus One) an unusually large amount of memory being used is shown (~42MB). I figure there is a leak. When I check the heap memory i get Heap size:~18MB, ~2MB allocated, ~16MB free. Analyzing the hprof in Eclipse MAT seems fine, which leads me to theorize that memory is leaking on the stack. Is this even possible? If it is, what can I do to stop or investigate the leak? Is the reported memory usage on the "Running Services" section of android even correct (I assume it is)? Another note: I have been unable to reproduce this issue when the UI is not up (with only the service running)

    Read the article

< Previous Page | 33 34 35 36 37 38 39 40 41 42 43 44  | Next Page >