Search Results

Search found 492 results on 20 pages for 'stefan dunn'.

Page 17/20 | < Previous Page | 13 14 15 16 17 18 19 20  | Next Page >

  • Stupid java question: Is it a method?

    - by Stefan
    Hello, I'm no Java guy, so I ask myself what this means: public Button(Light light) { this.light = light; } Is Button a method? I ask myself, because it takes an input parameter light. But if it was a method, why would it begin with a capital letter and has no return data type? Here comes the full example: public class Button { private Light light; public Button(Light light) { this.light = light; } public void press() { light.turnOn(); } } I know, this question is really trivial. However, I have nothing to do with Java and haven't found a description for the Button thing above. I'm just interested.

    Read the article

  • Database design: How should I add an information which can apply to several tables

    - by Stefan
    I am constructing a database System using Mysql, this will be an application of about 20 tables. The system contains information on farmers, we work with organic certification and need to record a lot of info for that. In my system, there are related parent-child tables for farmers, producing years and fields/areas - it's a simple representation of the real world in which farmers farm crops on their fields. I now need to add several status flags for each one of these levels: a farmer can be certified, or his field can be, or the specific year can be; each of these flags has several states and can occur a number of times. The obvious solution to this would be to add a child table to every one of these tables, and define the states there. What I wonder if there is an easier way to do this to avoid getting to many tables? Where/how would be best practise to keep that data?

    Read the article

  • What font and size is used in Windows 7 File Explorer Tree

    - by Stefan Koell
    I am having a hard time to find out which font is used by the Win 7 File Explorer in the tree view on the left hand side. Better, of course, would be if I can programmatically find out which the right font is (C#). I searched the Windows 7 design guidelines but this particular scenario is not listed (at least I couldn't find it). So anyone good with fonts?

    Read the article

  • Google Chrome is doing things wrong again

    - by Stefan Liebenberg
    Chrome is wrongly reporting width and height values for images during, or just after, load time. Jquery is used in this code example: <img id='image01' alt='picture that is 145x134' src='/images/picture.jpg' /> <script> var img = $( 'img#image01' ) img.width() // would return 145 in Firefox and 0 in Chrome. img.height() // would return 134 in Firefox and 0 in Chrome. </script> If you put the script in a onload function, the result is the same. but if you run the code a few seconds after the page has loaded, chrome returns the correct result. <script> function example () { var img = $( 'img#image01' ); img.width() // returns 145 in both Firefox and Chrome. img.height() // returns 134 in both Firefox and Chrome. } window.setTimeout( example, 1000 ) </script> Also if you specify the width and height values in the img tag, the script seems to work as expected in both Firefox and Chrome. <img id='image01' src='/images/picture.jpg' width=145 height=134 /> But as you cannot always control the html input, this is not an ideal workaround. Can jQuery be patched with a better workaround for this problem? or will I need to specify the width and height for every image in my code?

    Read the article

  • Collision Detection for arbitrarily sized, positioned and rotated rectangles in XNA

    - by Stefan
    I'm working with xna in C# and in my game I will have a variety of space ships flying all over the place. They will each have an arbitrary rotation, size and position in space and I need a method to determine when they collide. Ideally the method would take two Rectangles, two doubles and two Vector2s for size, rotation and position respectively and return a boolean that indicates whether they have intersected or not.

    Read the article

  • Checkout Control Panel that updates pricing???

    - by Stefan
    Hello all, my first post here. I am not much of a programmer, I can tailor some things for my personal needs but thats about it. I am looking for a script (jQuery preferred I suppose) which is easy to incorporate and bind to a few DIVs to be updated dynamically. Nothing too deep, just something that can updated price at check-out... Could I get some recommendations on a solid and simple widget for this? I appreciate any help/suggestions!

    Read the article

  • Bug in Safari: options.length = 0; not working as expected in Safari 4

    - by Stefan
    This is not a real question, but rather an answer to save some others the hassle of tracking this nasty bug down. I wasted hours finding this out. When using options.length = 0; to reset all options of a select element in safari, you can get mixed results depending on wether you have the Web Inspector open or not. If the web inspector is open you use myElement.options.length = 0; and after that query the options.length(), you might get back 1 instead of 0 (expected) but only if the Web Inspector is open (which is often the case when debugging problem like this). Workaround: Close the Web Inspector or call myElement.options.length = 0; twice like so: myElement.options.length = 0; myElement.options.length = 0; Testcase: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <title>Testcase</title> <script type="text/javascript" language="javascript" charset="utf-8"> function test(el){ var el = document.getElementById("sel"); alert("Before calling options.length=" + el.options.length); el.options.length = 0; alert("After calling options.length=" + el.options.length); } </script> </head> <body onLoad="test();"> <p> Make note of the numbers displayed in the Alert Dialog, then open Web inspector, reload this page and compare the numbers. </p> <select id="sel" multiple> <option label="a----------" value="a"></option> <option label="b----------" value="b"></option> <option label="c----------" value="c"></option> </select> </body> </html>

    Read the article

  • Download button that send application to blackberry and asks everyone else to register???

    - by Stefan
    Hello all I would like to know your opinions on how to handle this. I need to create a link or advertisement that offers a phone app to be downloaded. I need that users who are viewing the page with their blackberry receive the download when they click the button but everyone else who would be viewing the page would get a form which asks that they insert a phone number to send the application to. Has anyone else already tackled this or something similar?

    Read the article

  • Where to store frequently used functions in a OOP correct way

    - by Stefan Kuijers
    I'm working on a project which I want to build up OO. Now I came with a function that checks or a value is valid. private function valid(value:*, acceptedValues:Array):Boolean { for(var i:uint = 0; i < acceptedValues.length; i++) { if (value == acceptedValues[i]) { return true; } } return false; } As you can see, the function is very general and will be accessed across different classes. Now my question is; where do I store it in a OO correct way? Thanks in advance!

    Read the article

  • find on page neighbouring siblings jquery?

    - by Stefan
    ok i've been searching for an answer to this (if there even is one) with no luck i have a succession of div elements as shown in the pic bellow: http://i61.photobucket.com/albums/h46/DrAcOliCh_2006/untitled-1.jpg?t=1300520458 the blue background is the absolute parent of the orange divs which are also siblings the DOM is not quite organized according to how the orange elements appear on the page because they are all draggable (i used jquery UI) and i moved them around inside the parent, yet, as some know, the DOM doesn't get reorganized when i move draggable elements around, so basically the siblings structure remains the same inside the DOM what i kinda need (again if that is even possible) is to determine the immediate on page neighbouring siblings of eachother; in other words, say we take that "FlashBanner" element which, on page, has the "Logo", the "Search" and the "ShoppingBasket" elements as immediate top siblings and the "Categories" and "Content" elements as immediate bottom siblings (and no left or right siblings) i have a manual solution to this, that is to pre-specify the on page neighbouring siblings for each element through a series of form fields and stuff (another story and another wall of text to explain), but that is not important atm as i want to know if it can be done automatically (i.e tell jquery to find them for me) appreciate any help, even an "it can't be done automatically", and thank you for your time hope this doesn't sound to ambiguous (or silly for that matter) and why i need to do that don't ask :P wall of text to explain cheers :)

    Read the article

  • c++ scrollbar to window

    - by stefan
    hey, here im creating a window: _hWnd = CreateWindowEx( WS_EX_CLIENTEDGE, //dwExStyle (LPCWSTR) _wndClass, //lpClassName L"", //lpWindowName WS_CHILD | WS_HSCROLL | WS_VSCROLL , //dwStyle CW_USEDEFAULT, //X CW_USEDEFAULT, //Y 200, //nWidth 150, //nHeight hWndParent, //hWndParent NULL, //hMenu hInstance, //hInstance NULL //lpParam ); i added the scrollbars (WS_HSCROLL | WS_VSCROLL), but how can i control them?

    Read the article

  • How do you get the client size in a Silverlight Application?

    - by Stefan
    I want to get the size of the browser window running my Silverlight Application? I've tried the following lines, but it always returns zero! public Page() { InitializeComponent(); Initialize(); } public void Initialize() { WorldLimits.Y = Application.Current.Host.Content.ActualHeight; WorldLimits.X = Application.Current.Host.Content.ActualWidth; gameCore = new GameCore(this); gameTime = DateTime.Now.TimeOfDay.TotalMilliseconds / 1000; }

    Read the article

  • Objective-C: alloc of object within init of another object (memory management)

    - by Stefan Klumpp
    In my .h file I have: NSMutableArray *myArray; @property (nonatomic, retain) NSMutableArray *myArray; My .m file looks basically like this: @synthesize myArray; - (id) init { self = [super init]; if (self != nil) { self.myArray = .... ? // here I want to create an empty array } return self; } - (void) dealloc { [self.myArray release]; [super dealloc]; } What I'm not sure about is what do to in the init. 1) self.myArray = [[NSMutableArray alloc] init]; 2) NSMutableArray *tmp = [[NSMutableArray alloc] init]; self.myArray = tmp; [tmp release]; Solution 1 doesn't seem right to me, because of my @property (retain) setting I automatically increase the retain counter when setting self.myArray, but additionally I have already a "+1 retain" due to the [NSMutableArray alloc]. Thus the second solution seems more correct to me, even though it is cumbersome. Also am I wondering if self.myArray = ... is actually the same as [self setMyArray:...] and thus does increase the retain count.

    Read the article

  • jQuery to bind input value to span or div???

    - by Stefan
    Please excuse me if this is a newbie question. I am new to this. I would like that a user fill out a form with their info and, just before clicking submit, there to be a summary of details area where they confirm their details are correctly entered. So is it possible for me to "bind" specific inputs to specific spans or divs and as they type (or maybe onBlur?) the span would reflect what is written in the respective input???

    Read the article

  • The Scala way to use one actor per socket connection

    - by Stefan
    I am wondering how it is possible to avoid one socket connection pr. thread in Scala. I have thought a lot about it, but I always end up with some code which is listening for incoming data for each client connection. The problem is that I want to develop an application which should simultanously handle perhaps a couple of thousand connections. However I will of course not want to create a thread for each connection because of the lack of scalability and context switching. What would be the "right" way to do this. In my world it should be possible to have one actor for each connection without the need to block one thread per actor.

    Read the article

  • Sql Server related question

    - by stefan
    Hi guys, I have this thing that i need to do and some advices will be greatly appreciated. I have a Sql server table with some phone calls.For each phone call i have the start and end time. What i need to accomplish: a stored procedure which for a certain period of time, let's say 5 hours at a x interval, lets say 2 minutes returns the number of connected calls. Something like: Interval Nr of Calls Connected 01-01-2010 12:00:00 - 01-01-2010 12:05:00 30 01-01-2010 12:05:01 - 01-01-2010 12:10:00 10 ............. Which will be the fastest way to do that? Thank you for your help

    Read the article

  • C++ int vector to c#

    - by Stefan Koenen
    I'm doing a C# project and I want to call next_permutation from the algorithm library in C++. I found the way to call c++ functions in c# but i dont know how to get vectors from c++ and use it in c# (cause next_permutation require a int vector...) this is what I'm trying at the moment: extern void NextPermutation(vector<int>& permutation) { next_permutation (permutation.begin(),permutation.end()); } [DllImport("PEDLL.dll", CallingConvention = CallingConvention.Cdecl)] private static extern void NextPermutation(IntPtr test);

    Read the article

  • Mobile: Wrox Cross Platform Mobile Development - iPhone, iPad, Android, and everything with .NET & C#

    - by Wallym
    Wrox has produced a bundle of their 3 best selling mobile development books and it is available as of Today (March 16). A bundle of 3 best-selling and respected mobile development e-books from Wrox form a complete library on the key tools and techniques for developing apps across the hottest platforms including Android and iOS. This collection includes the full content of these three books, at a special price: Professional Android Programming with Mono for Android and .NET/C#, ISBN: 9781118026434, by Wallace B. McClure, Nathan Blevins, John J. Croft, IV, Jonathan Dick, and Chris Hardy Professional iPhone Programming with MonoTouch and .NET/C#, ISBN: 9780470637821, by Wallace B. McClure, Rory Blyth, Craig Dunn, Chris Hardy, and Martin Bowling Professional Cross-Platform Mobile Development in C#, ISBN: 9781118157701, by Scott Olson, John Hunter, Ben Horgen, and Kenny Goers Remember, go buy 8-10 copies of the 3 book set for the ones you love. They will make great and romantic gifts!!

    Read the article

  • Are you ready for the needed changes to your Supply Chain for 2013?

    - by Stephen Slade
    With the initiation of the Dodd-Frank Act, companies need to determine if their products contain 'conflict materials' from certain global markets as the Rep of Congo. The materials include metals such as gold, tin, tungsten and tantalum. Compaines with global sourcing face new disclosure requirements in Feb'13 related to business being done in Iran. Public companies are required to disclose to U.S. security regulators if they or their affiliates are engaged in business in Iran either directly or indirectly.  Is your supply chain compliant?  Do you have sourcing reports to validate?  Where are the materials in your chips & circuit boards coming from? In the next few weeks, responsible companies will be scrutinizing their supply chains, subs, JVs, and affiliates to search for exposure. Source: Brian Lane, Atty at Gibson Dunn Crutcher, as printed in the WSJ Tues, Dec 11, 2012 p.B8

    Read the article

  • Silverlight Cream for April 29, 2010 -- #851

    - by Dave Campbell
    In this Issue: Carlos Figueira(-2-), Subodh Pushpak, Gergely Orosz, John Papa, Mike Snow(-2-), Rishi, Tim Heuer, Stefan Olson, and David Anson. Shoutouts: Josh Holmes blogged about a cool app the City of Miami has up: Miami 311: Built on Windows Azure Gergely Orosz reports on the state of a bug he found pre SL4: Silverlight 4 still displays large elements incorrectly Laura Foy and Charlie Kindel discuss WP7 on Channel 9: Windows Phone 7 Developer Tools Refresh Announced Charlie Kindel has an announcement, good instructions, and what's new notes on the Windows Phone Developer Tools CTP Refresh! Tim Heuer mentioned the workaround for this in his post (below), but I thought you might like to read Brandon Watson's debrief of what it's all about: Signed Assemblies Bug in the Windows Phone Tools CTP Refresh Laurent Bugnion posted about interrelations between versions of Blend and WP7 code... read it closely: Be careful when installing the Blend Windows Phone 7 Add-In From SilverlightCream.com: Consuming REST/POX services in Silverlight 4 Carlos Figueira has a pair of posts up about consuming services in Silverlight 4. This first one is about consuming REST/POX services. He provides a Service Contract that can be used with either and the full project code is available as well. Consuming REST/JSON services in Silverlight 4 In the second post, Carlos Figueira provides the code to allow WCF and Silverlight 4 to consume strongly-typed REST/JSON... and again, all the code is available. Silverlight and WCF caching Subodh Pushpak has a post up discussing caching in WCF, and has code demonstrating turning caching on at run-time. Detecting Silverlight Version Installed Gergely Orosz said it right when he said "Detecting the Silverlight version installed on a client machine isn’t entirely straightforward." ... and after reading this post, if you take the link to his ScottLogic blog, you'll get a full break-out of how it's done. Silverlight TV 22: Tim Heuer on Extending the SMF It's Thursday, and that means Silverlight TV! ... this week, John Papa has on Tim Heuer who has always been out there pushing media... and he's talking about SMF or Silverlight Media Framework for the uninitiated, and also extending it. Silverlight Tip of the Day #7 – Localized Resources Mike Snow has Tip Number 7 up and it's about localization... good end-to-end discussion and demonstration. Just thought I should use that to prove to my daughter that the tatoo she had put on the back of her neck actually reads "Eat More Broccoli" :) Silverlight Tip of the Day #8 – Detecting Alt, Shift, Control, Window & Apple Keys Combinations I just realized Mike Snow's site logo reads "Silverlight Tips of the Day" (bolding mine) ... that answers why I'm seeing more than one -- sorry Mike, couldn't pass it up :) ... Mike's second tip today and number 8 in the series is on detecting all the mouse button and ctl/alt/shift combinations in Silverlight. nRoute: More Wholesomeness, with SL 4 and .NET 4.0 Rishi has a post up announcing a new nRoute release for Silverlight 4 and .NET 4.0 He's tweaked the code to take advantages of enhancements in the new platforms, so check it out. Windows Phone 7 Developer Tools April 2010 Refresh Booya... Tim Heuer announced the release of the next drop in the WP7 tools ... dang wish I was at home today :) ... be sure to read the post for info such as the notes about Authenticode Assemblies and the release notes. Updates to Silverlight Multi-binding support Stefan Olson points up a SL4 change to Multi-binding support that he had previously blogged about. He shows the previous non-working example, and what you have to do to make it work now. Using XAML to create a custom wallpaper image for your mobile device David Anson has a solution for those pesky lost devices, and let me go on the record right now saying if anyone finds a WP7 phone laying around, just call me, it's mine :) [think that'd work??] ... ok, David's solution is a WPF app "MobileDeviceHomeScreenMaker" that you get the info set and it produces a png you then put on your device. But seriously about that lost phone... Stay in the 'Light! Twitter SilverlightNews | Twitter WynApse | WynApse.com | Tagged Posts | SilverlightCream Join me @ SilverlightCream | Phoenix Silverlight User Group Technorati Tags: Silverlight    Silverlight 3    Silverlight 4    Windows Phone MIX10

    Read the article

< Previous Page | 13 14 15 16 17 18 19 20  | Next Page >