Search Results

Search found 1833 results on 74 pages for 'steve mills'.

Page 34/74 | < Previous Page | 30 31 32 33 34 35 36 37 38 39 40 41  | Next Page >

  • EF 4 - associations with keys that dont match

    - by Steve Ward
    We're using POCOs and have 2 entities: Item and ItemContact. There are 1 or more contacts per item. Item has as a primary key: ItemID LanguageCode ItemContact has: ItemID ContactID We cant add an association with a referrential constraint as they have differing keys. There isnt a strict primary / foreign key as languageCode isnt in ItemContact and ContactID isnt in Item. How can we go about mapping this with an association for contacts for an item if there isnt a direct link but I still want to see the contacts for an item? One of the entities originates in a database view so it is not possible to add foreign keys to the database Thanks Stephen Ward

    Read the article

  • Web page width on LG mobile phone

    - by steve
    Hi I'm trying to develop a site for mobile phones. At the moment it seems to work on iphone and android htc desire and an n95. When I try it on an LG renoir instead of the page fitting the width of the screen the page displays at least twice as wide as it should meaning you can scroll left and right. Has anyone come across this before, or knows how to stop it. Warm regards

    Read the article

  • CSS and Page Size and Horizontal Scrollbar

    - by Steve
    When I added some CSS stuff to my page, the page got wider and and horizontal appeared even the content is very minimal and does not require to scroll. How can I remove it. I used the following to remove it but it appears as a hack and I am just playing around with CSS, so is there a proper way to do this

    Read the article

  • git: 'log master..origin/master' not behaving as expected

    - by steve jaffe
    I'm trying to compare my copy of 'master' to that on the remote repository which it tracks. I thought that the following command would work, and often it seems to. However, sometimes it produces nothing and yet I know that the remote branch has many changes, which I can confirm by doing a pull. git log master..origin/master Can anyone explain this behavior and tell me what command I should be using to determine the changes between local and remote? [Another piece of data: I've had it happen that 'git log master..origin/master' produces nothing. Then I do a pull. The pull fails because I have a working copy of some file. After this, 'git log master..origin/master' does show me the differences. It seems the pull has updated some local log? If so, how could I achieve this without doing (or attempting to do) a pull?]

    Read the article

  • Visual Studio - "attach to particular instance of the process" macro

    - by Steve
    I guess prety much everyone who does a lot of debugging have a handy macro in Visual Studio (with shortcut to it on a toolbar) which when called automatically attaches to a particular process (identified by name). it saves a lot of time rather than clicking "Debug" - "Attach to the process ...", but it only works if one is running a single instance of the process one wants to attach to. If theres is more than one instance of particular process in memory - the first one (with a smaller PID?) is being choose by debugger. Does anyone have a macro which shows a dialog (if more that 1 process with a specified name running) and lets developer to select to one he/she really wants to attach to. I guess the selection could be made based on a windwow caption text (which would be suffice in most of cases) and when the particular instance is selected macro passes the PID of the process to the Debugger object? If someone has that macro or knows how to write it - please share. Thanks.

    Read the article

  • How to Convert multiple sets of Data going from left to right to top to bottom the Pythonic way?

    - by ThinkCode
    Following is a sample of sets of contacts for each company going from left to right. ID Company ContactFirst1 ContactLast1 Title1 Email1 ContactFirst2 ContactLast2 Title2 Email2 1 ABC John Doe CEO [email protected] Steve Bern CIO [email protected] How do I get them to go top to bottom as shown? ID Company Contactfirst ContactLast Title Email 1 ABC John Doe CEO [email protected] 1 ABC Steve Bern CIO [email protected] I am hoping there is a Pythonic way of solving this task. Any pointers or samples are really appreciated! p.s : In the actual file, there are 10 sets of contacts going from left to right and there are few thousand such records. It is a CSV file and I loaded into MySQL to manipulate the data.

    Read the article

  • SQL Query that can return intersecting data

    - by Alex
    I have a hard time finding a good question title - let me just show you what I have and what the desired outcome is. I hope this can be done in SQL (I have SQL Server 2008). 1) I have a table called Contacts and in that table I have fields like these: FirstName, LastName, CompanyName 2) Some demo data: FirstName LastName CompanyName John Smith Smith Corp Paul Wade Marc Andrews Microsoft Bill Gates Microsoft Steve Gibbs Smith Corp Diane Rowe ABC Inc. 3) I want to get an intersecting list of people and companies, but companies only once. This would look like this: Name ABC Inc. Bill Gates Diane Rowe John Smith Marc Andrews Microsoft Smith Corp Steve Gibbs Paul Wade Can I do this with SQL? How?

    Read the article

  • Customized sorting on DataTable in C#?

    - by Steve
    This is a C# Winform question. I have a DataGridView which is bounded to a DataTable. I construct the DataTable myself, which several DataColumn instances. When the DataTable is bound to the DataGridView, by default, every column is sortable by clicking the headers of the DataGridView. But the sorting behavior is something "by default". It seems that it is sorted by string. This is true even if I put this as my code: DataColumn dc = new DataColumn("MyObjectColumn", typeof(MyObject)); And MyObject has overriden ToString() and has implemented the IComparable interface. That means even if I have told the DataTable how to sort the special column with the implementation of IComparable interface, DataGridView still doesn't do it the way I expect. So how can I let DataTable sort data in the way I want? Thanks for the answers.

    Read the article

  • IoC / Dependency Injection - please explain code versus XML

    - by steve.macdonald
    I understand basically how IoC frameworks work, however one thing I don't quite get is how code-based config is supposed to work. With XML I understand how you could add a new assembly to a deployed application, then change the config in XML to include it. If the application is already deployed (i.e., compiled in some form) then how can code changes be made without recompiling? Or is that what people do, just change config in code and recompile?

    Read the article

  • How to programmatically bind to a Core Data model?

    - by Dave Gallagher
    Hello. I have a Core Data model, and was wondering if you know how to create a binding to an Entity, programmatically? Normally you use bind:toObject:withKeyPath:options: to create a binding. But I'm having a little difficulty getting this to work with Core Data, and couldn't find anything in Apple's docs regarding doing this programmatically. The Core Data model is simple: An Entity called Book An Attribute of Book called author (NSString) I have an object called BookController. It looks like so: @interface BookController : NSObject { NSString *anAuthor; } @property (nonatomic, retain) NSString *anAuthor; // @synthesize anAuthor; inside @implementation I'd like to bind anAuthor inside BookController, to author inside a Book entity. This is how I'm attempting to wrongly do it (it partially works): // A custom class I made, providing an interface to the Core Data database CoreData *db = [[CoreData alloc] init]; // Creating a Book entity, saving it [db addMocObject:@"Book"]; [db saveMoc]; // Fetching the Book entity we just created NSArray *books = [db fetchObjectsForEntity:@"Book" withPredicate:nil withSortDescriptors:nil]; NSManagedObject *book = [books objectAtIndex:0]; // Creating the binding BookController *bookController = [[BookController alloc] init]; [bookController bind:@"anAuthor" toObject:book withKeyPath:@"author" options:nil]; // Manipulating the binding [bookController setAnAuthor:@"Bill Gates"]; Now, when updating from the perspective of bookController, things don't work quite right: // Testing the binding from the bookController's perspective [bookController setAnAuthor:@"Bill Gates"]; // Prints: "bookController's anAuthor: Bill Gates" NSLog(@"bookController's anAuthor: %@", [bookController anAuthor]); // OK! // ERROR HERE - Prints: "bookController's anAuthor: (null)" NSLog(@"Book's author: %@", [book valueForKey:@"author"]); // DOES NOT WORK! :( When updating from the perspective of the Book entity, things work fine: // ------------------------------ // Testing the binding from the Book's (Entity) perspective (this works perfect) [book setValue:@"Steve Jobs" forKey:@"author"]; // Prints: "bookController's anAuthor: Steve Jobs" NSLog(@"bookController's anAuthor: %@", [bookController anAuthor]); // OK! // Prints: "bookController's anAuthor: Steve Jobs" NSLog(@"Book's author: %@", [book valueForKey:@"author"]); // OK! It appears that the binding is partially working. I can update it on the side of the Model and it propagates up to the Controller via KVO, but if I update it on the side of the Controller, it doesn't trickle down to the Model via KVC. Any idea on what I'm doing wrong? Thanks so much for looking! :)

    Read the article

  • jQuery detect current thumb and scroll jCarousel accordingly

    - by steve
    Another thanks to SLaks for helping me get the code this far. I'm not quite sure if my last step is even possible with the way I have things set up. A live version of the gallery can be seen here: http://www.studioimbrue.com/index2.php Currently, everything works appropriately. The image and its thumbnail are currently tied together, but the jCarousel itself is still independent. I've added nextThumb.closest('.thumbscontainer').jcarousel('next'); so that when you click the large image, the carousel scrolls to the next row, but that doesn't actually follow any logic. What I'm attempting to do is for jQuery to detect how far down the thumbnail is and when to appropriately scroll the carousel. Is this even possible?

    Read the article

  • TFS Build Server Cannot find Assembly Reference

    - by Steve Syfuhs
    I looked at this post http://stackoverflow.com/questions/547468/assembly-references-wont-resolve-properly-on-our-build-server but it didn't help the issue. I am (extremely) new to TFS, and just installed 2010 on a VM. I imported a project and got everything working-ish. I went to create a new build through team explorer, and set it up to build on each check-in. It build's locally just fine, but when it's built on check-in it dies on a 3rd party assembly reference. The reference is not in the GAC, but part of the local references. There is only one 3rd party dll, and the projects only reference each other in the solution. I have a feeling I'm missing some important step with regards to TFS and references. Any ideas? EDIT: This a test installation...there is nothing else installed on this box, with the exception of SQL and IIS.

    Read the article

  • Embedded SQL in OO languages like Java

    - by Steve De Caux
    One of the things that annoys me working with SQL in OO languages is having to define SQL statements in strings. When I used to work on IBM mainframes, the languages used an SQL preprocessor to parse SQL statements out of the native code, so the statements could be written in cleartext SQL without the obfuscation of strings, for instance in Cobol there is a EXEC SQL .... END-EXEC syntax construct that allows pure SQL statements to be embedded in the Cobol code. <pure cobol code, including assignment of value to local variable HOSTVARIABLE> EXEC SQL SELECT COL_A, COL_B, COL_C INTO :COLA, :COLB, :COLC FROM TAB_A WHERE COL_D = :HOSTVARIABLE END_EXEC <more cobol code, variables COLA, COLB, COLC have been set> ...this makes the SQL statement really easy to read & check for errors. Between the EXEC SQL .... END-EXEC tokens there are no constraints on indentation, linebreaking etc., so you can format the SQL statement according to taste. Note that this example is for a single-row select, when a multiple-row resultset is expected, the coding is different (but still v. easy to read). So, taking Java as an example What made the "old COBOL" approach undesirable ? Not only SQL, but system calls could be made much more readable with that approach. Let's call it the embedded foreign language preprocessor approach. Would an embedded foreign language preprocessor for SQL be useful to implement ? Would you see a benefit in being able to write native SQL statements inside java code ? Edit I'm really asking if you think SQL in OO languages is a throwback, and if not then what could be done to make it better.

    Read the article

  • Android - Convert Color Resource to Color in Domain Object

    - by Steve
    I have a domain object, where I created a method to return a text color based on the internal state of the domain object. I have defined the colors in a color.xml file as resources. The problem I have now, is that I would like to return a Color object instead of a resource ID from the domain object method. This way I can set the text color of a TextView by just calling textView.setTextColor(domainObj.getTextColor()) since it expects a Color object and not a resource ID. Currently, in an Activity, I can call getResources().getColor(domainObj.getTextColorResource()) to convert a resource ID to a color, but I would like this done in the domain object and I am not sure how I would do this when I do not have access to the getResources method. Are there any cleaner options than passing in a Resource object into the method, or domain object? Thanks

    Read the article

  • Eclipse (Springsource Tool Suite 2.3.1) can't resolve dependencies for classes in the same package

    - by Steve
    This started happening when I upgraded my Springsource Toolsuite from 2.3 to 2.3.1. Essentially whenever I do anything, such as open a file, change a file, etc, I have to do a clean. Everything works fine when I do mvn commands on the command line, which leads me to believe that Eclipse is looking in the wrong place for compiled code or something along those lines, although that is entirely superstitious at this point. Example: I make a change to com.foo.mypackage.MyClass. Suddenly a bunch of tests that excercise MyClass get the red x - for class not found! In src/main/test: com.foo.DbUnitTest com.foo.mypackage.FooTest extends DbUnitTest DbUnitTest gets a class not found. I do a clean, and everything is fine. I touch something, and it breaks again :(. I don't really know where to begin on how to troubleshoot this.

    Read the article

  • DOM Elements with same id and jQuery

    - by Steve
    Hi I have multiple elements with the same structure in my application. Second div element's id varies as per the comment id in the db which is unique. There are elements with the id 'vote_up' and 'vote_down'. This gets repeated for each comment.What happens is that, as I mentioned, there are multiple comments. I want to perform an Ajax request. First of this structure functions properly using ajax, but the rest does an http request. Btw I am developing a rails application and I am using jQuery. <div id="post_comment"> john<i> says </i> Comment<br/> <div id="comment_10_div"> **<form action="/comments/vote_up" id="vote_up" method="post">** <div style="margin:0;padding:0;display:inline"> <input name="authenticity_token" type="hidden" value="w873BgYHLxQmadUalzMRUC+1ql4AtP3U7f78dT8x9ho=" /> </div> <input id="Comment_place_id" name="Comment[post_id]" type="hidden" value="3" /> <input id="Comment_id" name="Comment[id]" type="hidden" value="10" /> <input id="Comment_user_id" name="Comment[user_id]" type="hidden" value="2" /> <input name="commit" type="submit" value="Vote up" /> </form> <label id="comment_10">10</label> **<form action="/comments/vote_down" id="vote_down" method="post">** <div style="margin:0;padding:0;display:inline"> <input name="authenticity_token" type="hidden" value="w873BgYHLxQmadUalzMRUC+1ql4AtP3U7f78dT8x9ho=" /> </div> <input id="Comment_place_id" name="Comment[place_id]" type="hidden" value="3" /> <input id="Comment_id" name="Comment[id]" type="hidden" value="10" /> <input id="Comment_user_id" name="Comment[user_id]" type="hidden" value="2" /> <input name="commit" type="submit" value="Vote Down" /> </form> </div> Can you please help me to solve this Thanks

    Read the article

  • How to use NSString drawInRect to centre text?

    - by Steve Folly
    How can I draw a string centred within a rect? I've started off with: (an extract from the drawRect method of my custom view) NSString* theString = ... [theString drawInRect:theRect withAttributes:0]; [theString release]; Now I'm assuming I need to set up some attributes. I've had a look through Apple's Cocoa documentation, but it's a bit overwhelming and can't find anything for how to add paragraph styles to the attributes. Also, I can only find horizontal alignment, what about vertical alignment? Thanks.

    Read the article

  • Autocompletbox in Silverlight

    - by Steve Daum
    I have a Silverlight 3 project I am trying to convert to Silverlight 4. I use the autocompletebox. I cannot find the correct namespace/reference for this in Silverlight 4. Has it moved? What reference do I need? Thanks in advance.

    Read the article

  • Unit tests only run automatically when active SDK is "simulator"?

    - by Steve Madsen
    I have followed the instructions Apple publishes for unit testing applications on iPhone and things work great when I set the active SDK to "iPhone Simulator". I have it configured to always build and run my tests as part of building the application itself. Apple implies (by omission) that this should work all of the time, but the tests are skipped when I set the active SDK to "iPhone Device". I am also linking with OCMock, and instead of a failing test, this warning is in the build log: ld: warning: in .../build/Debug-iphoneos/OCMock.framework/OCMock, missing required architecture arm in file It's very nice to make the unit test bundle a dependency of the main application, so these tests run at every build, but its utility is greatly diminished if it doesn't work during device builds. Is this a known, but undocumented, limitation?

    Read the article

  • how do you convert a directoryInfo file to string

    - by steve
    Problem is that i cant convert to string Dim path As String = "..\..\..\Tier1 downloads\CourseVB\" If countNumberOfFolders > 0 Then 'if there is a folder then ' make a reference to a directory Dim di As New IO.DirectoryInfo(path) Dim diar1 As IO.DirectoryInfo() = di.GetDirectories() Dim dra As IO.DirectoryInfo 'list the names of all files in the specified directory For Each dra In diar1 Dim lessonDirectoryName() As Lesson lessonDirectoryName(0).lessonName = dra Next 'the the lesson is an object, and lessonName is the property of type string. How do i convert the directoryInfo to string?

    Read the article

  • Weak References and Disposable objects.

    - by Steve Sheldon
    In C# it is possible to create weak references to objects as described here: WeakReference Class In .net some classes also implement the IDisposable interface. Calling the Dispose method of this interface is performed to manually dispose of any managed or unmanaged resources currently being held onto. An example might be a Bitmap object or class. If I assign an object that implements IDisposable to a weak reference, will Dispose be called if the weak reference collects the object?

    Read the article

  • Git - git add in a gitignore directory

    - by Steve
    If my .gitignore file has tmp\ in it and I do a git add file.test from tmp, Git adds file.test to the repository. If file.test never changes, than this is as good as a one time add to the repository, right? Say for static files that I want to be in version control. You want the file in an initial clone and that's it. I assume file.test doesn't get tracked, so if there are updates, Git doesn't see it as modified?

    Read the article

  • CAS authentication and redirects with jQuery Ajax

    - by Steve Nay
    I've got an HTML page that needs to make requests to a CAS-protected (Central Authentication Service) web service using the jQuery AJAX functions. I've got the following code: $.ajax({ type: "GET", url: request, dataType: "json", complete: function(xmlHttp) { console.log(xmlHttp); alert(xmlHttp.status); }, success: handleRedirects }); The request variable can be either to the CAS server (https://cas.mydomain.com/login?service=myServiceURL) or directly to the service (which should then redirect back to CAS to get a service ticket). Firebug shows that the request is being made and that it comes back as a 302 redirect. However, the $.ajax() function isn't handling the redirect. I wrote this function to work around this: var handleRedirects = function(data, textStatus) { console.log(data, textStatus); if (data.redirect) { console.log("Calling a redirect: " + data.redirect); $.get(data.redirect, handleRedirects); } else { //function that handles the actual data processing gotResponse(data); } }; However, even with this, the handleRedirects function never gets called, and the xmlHttp.status always returns 0. It also doesn't look like the cookies are getting sent with the cas.mydomain.com call. (See this question for a similar problem.) Is this a problem with the AJAX calls not handling redirects, or is there more going on here than meets the eye?

    Read the article

  • StyleCop 4.4 works inside VS.NET 2010 but not MSBuild command line

    - by Steve Michelotti
    We are seeing extremely strange results where StyleCop will correctly report violations when run from within Visual Studio 2010. However, when we run msbuild on the command line (e.g., "MSBuild.exe mySolution.sln") it reports "No violations encountered" when clearly there are the same violations as when we ran it within Visual Studio. Is this a bug in the latest release of StyleCop? Or in the 2010 integration? Is there anything you can tell me about possible differences with StyleCop executing from within VS.NET versus MSBuild command line? Thanks.

    Read the article

< Previous Page | 30 31 32 33 34 35 36 37 38 39 40 41  | Next Page >