Search Results

Search found 713 results on 29 pages for 'barry brown'.

Page 17/29 | < Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >

  • null checking edit textbox android

    - by sara brown
    i want to make empty textbox checking for android. i tried try catch but it was force to close. below is my codes try{ name = (EditText)findViewById(R.id.name); }catch(NullPointerException ex){ new AlertDialog.Builder(KawalanAppXTVT.this).setTitle("Error" ) .setMessage("That's not a number") .setPositiveButton("OK", null).show(); can someone help me?

    Read the article

  • Codeigniter: how should I restructure db schema?

    - by Kevin Brown
    I don't even know if that's the right term. May it be known that I'm a major novice! I have three tables: users, profiles, and survey. Each one has user_id as it's first field, (auto-increment for users), and they're all tied by a foreign key constraint, CASCADE on DELETE. Currently, for each user, let's say user_id 1, they have a corresponding db entry in the other tables. For profiles it lists all their information, and the survey table holds all their survey information. Now I must change things...darn scope creep. Users need the ability to have multiple survey results. I imagine that this would be similar to a comment table for a blog... My entire app runs around the idea that a single user is linked to a constraining profile and survey. How should I structure my db? How should I design my app's db so that a user can have multiple tests/profiles for the test? Please assist! Any advice, information and personal-knowledge is appreciated! Right now the only way I know how to accompany my client is to create a pseudo-user for each test (so unnecessary) and list them in a view table (called "your tests")-- these are obtained from the db by saying: where user_id=manager_id

    Read the article

  • Scala, represent pattern of boolean tuple into something else.

    - by Berlin Brown
    This is a cellular automata rule (input Boolean == Left, Center, Right Cell) and output Boolean . What is a better way to represent this in Scala. trait Rule { def ruleId() : Int def rule(inputState:(Boolean, Boolean, Boolean)) : Boolean override def toString : String = "Rule:" + ruleId } class Rule90 extends Rule { def ruleId() = 90 def rule(inputState:(Boolean, Boolean, Boolean)) : Boolean = { // Verbose version, show all 8 states inputState match { case (true, true, true) => false case (true, false, true) => false case (false, true, false) => false case (false, false, false) => false case _ => true } } }

    Read the article

  • Sum up values in SQL once all values are available

    - by James Brown
    I have events flowing into a MySQL database and I need to group and sum the events to transactions and store away into another table. The data looks like: +----+---------+------+-------+ | id | transid | code | value | +----+---------+------+-------+ | 1 | 1 | b | 12 | | 2 | 1 | i | 23 | | 3 | 2 | b | 34 | | 4 | 1 | e | 45 | | 5 | 3 | b | 56 | | 6 | 2 | i | 67 | | 7 | 2 | e | 78 | | 8 | 3 | i | 89 | | 9 | 3 | i | 90 | +----+---------+------+-------+ The events arrive in batches and I would like to create the transaction by summing up the values for each transid, like: select transid, sum(value) from eventtable group by transid; but only after all the events for that transid have arrived. That is determined by the event with the code e (b for the beginning, e for the end and i for varying amount of intermediates). Being a novice in SQL, how could I implement the requirement for the existance of the end code before the summing?

    Read the article

  • Java static source analysis/parsing (possibly with antlr), what is a good tool to do this?

    - by Berlin Brown
    I need to perform static source analysis on Java code. Ideally, I want the system to work out of the box without much modification from me. For example, I have used Antlr in the past, but I spent a lot of time building grammar files and still didn't get what I wanted. I want to be able to parse a java file and have return the character position of say: Character position start and end of a Java block comment Character position start and end of a Java class file Character position start and end of a Java method declaration, signature, and implementation. It looks like Antlr will do that, but I have yet to finish a grammar that actually gives me the positions of the code I need. Does anyone have that complete Antlr grammar and Java code to give the character positions of the parts in the Java source.

    Read the article

  • Codeigniter: how to track activity w/o using multiple db rows?

    - by Kevin Brown
    I need to track the completion of tasks for users. I started by having a row called "first_login", "profile_complete", "other_thing_complete", etc... I'd like to combine these all into one row "activity_state". I just don't know how to properly store data in this field, and how to retrieve it. What kind of field should it be, and how should I read/write to it?

    Read the article

  • Codeigniter: State Machine how to

    - by Kevin Brown
    I created a db row called "activity_state" to denote which things a user has and hasn't completed. The problem is, I don't know how to use it... How can I use this single row to determine what a user has done? ie. have they completed their profile?, have they completed an assignment? Someone mentioned using it as a bitfield, but I'm unfamiliar with that. Is that a good idea? Any ideas?

    Read the article

  • Paged UIScrollView with UIImageViews only showing first UIImageVIew

    - by Jonathan Brown
    I am working on a paged UIScrollView, but it only wants to show the first UIImageView within it. I add each UIImageView at an offset of the width of the scroll view, so that should create each page. When run, it says the scroll view is the right number of pages, but the images don't show. Any help would be much appreciated! int numSlides = NUM_TUTORIAL_SLIDES; NSString *fileName; UIImageView *slideImageView; CGRect slideFrame; for (int i = 1; i <= numSlides; i++) { slideFrame.origin.x = self.tutorialScrollView.frame.size.width * (i-1); slideFrame.origin.y = 0; slideFrame.size = self.tutorialScrollView.frame.size; slideImageView = [[UIImageView alloc] initWithFrame:slideFrame]; if([[AppManager sharedManager] is4inchScreen]) { fileName = [NSString stringWithFormat:@"Slide%[email protected]", i]; } else { fileName = [NSString stringWithFormat:@"Slide%[email protected]", i]; } slideImageView.image = [UIImage imageWithContentsOfFile:[[NSBundle mainBundle] pathForResource:fileName ofType:nil]]; [self.tutorialScrollView addSubview:slideImageView]; [slideImageView release]; } self.tutorialScrollView.contentSize = CGSizeMake(self.tutorialScrollView.frame.size.width * numSlides, self.tutorialScrollView.frame.size.height); self.tutorialScrollView.delegate = self;

    Read the article

  • HTML/CSS Design for Report

    - by Kevin Brown
    I'm looking for some resources that demonstrate good graphic design for generated (PHP/HTML/CSS) reports. The website I'm designing is essentially a long test. Everything is finished except the report generation, and this part needs to look good! I'd appreciate any advice/resources you can point me to! I know this isn't directly programming related, but my purposes do encompass coding and output.

    Read the article

  • Codeigniter: Using data in a controller

    - by Kevin Brown
    I'm new to php and CI, and I'm having some trouble in my controller. I feel that I'm doing this the wrong way, and it could be easier, I just don't know the syntax: $data['members'] = $this->home_model->getUser($id); $credit = $this->home_model->getCredit($id); if ($credit == '0'){stuff...} So I'm getting the user's data that has their the same information as "getCredit" does, but I don't know how to get the single variable that I need for my if statement... How can I just use the "getUser" function so that I'm not pulling redundant information?

    Read the article

  • C# Delegate under the hood question.

    - by Ted
    Hi Guys I was doing some digging around into delegate variance after reading the following tquestion in SO. "delegate-createdelegate-and-generics-error-binding-to-target-method" (sorry not allowed to post more than one hyperlink as a newbie here!) I found a very nice bit of code from Barry kelly at https://www.blogger.com/comment.g?blogID=8184237816669520763&postID=2109708553230166434 Here it is (in a sugared-up form :-) using System; namespace ConsoleApplication4 { internal class Base { } internal class Derived : Base { } internal delegate void baseClassDelegate(Base b); internal delegate void derivedClassDelegate(Derived d); internal class App { private static void Foo1(Base b) { Console.WriteLine("Foo 1"); } private static void Foo2(Derived b) { Console.WriteLine("Foo 2"); } private static T CastDelegate<T>(Delegate src) where T : class { return (T) (object) Delegate.CreateDelegate( typeof (T), src.Target, src.Method, true); // throw on fail } private static void Main() { baseClassDelegate a = Foo1; // works fine derivedClassDelegate b = Foo2; // works fine b = a.Invoke; // the easy way to assign delegate using variance, adds layer of indirection though b(new Derived()); b = CastDelegate<derivedClassDelegate>(a); // the hard way, avoids indirection b(new Derived()); } } } I understand all of it except this one (what looks very simple) line. b = a.Invoke; // the easy way to assign delegate using variance, adds layer of indirection though Can anyone tell me: how it is possible to call invoke without passing the param required by the static function. When is going on under the hood when you assign the return value from calling invoke What does Barry mean by extra indirection (in his comment)

    Read the article

  • Silverlight Cream for March 22, 2010 -- #817

    - by Dave Campbell
    In this Issue: Bart Czernicki, Tim Greenfield, Andrea Boschin(-2-), AfricanGeek, Fredrik Normén, Ian Griffiths, Christian Schormann, Pete Brown, Jeff Handley, Brad Abrams, and Tim Heuer. Shoutout: At the beginning of MIX10, Brad Abrams reported Silverlight 4 and RIA Services Release Candidate Available NOW From SilverlightCream.com: Using the Bing Maps Silverlight control on the Windows Phone 7 Bart Czernicki has a very cool BingMaps and WP7 tutorial up... you're going to want to bookmark this one for sure! Code included and external links... thanks Bart! Silverlight Rx DataClient within MVVM Tim Greenfield has a great post up about Rx and MVVM with Silverlight 3. Lots of good insight into Rx and interesting code bits. SilverVNC - a VNC Viewer with Silverlight 4.0 RC Andrea Boschin digs into Silverlight 4 RC and it's full-trust on sockets and builds an implementation of RFB protocol... give it a try and give Andrea some feedback. Chromeless Window for OOB applications in Silverlight 4.0 RC Andrea Boschin also has a post up on investigating the OOB no-chrome features in SL4RC. Windows Phone 7 and WCF AfricanGeek has his latest video tutorial up and it's on WCF and WP7... I've got a feeling we're all going to have to get our arms around this. Some steps for moving WCF RIA Services Preveiw to the RC version Fredrik Normén details his steps in transitioning to the RC version of RIA Services. Silverlight Business Apps: Module 8.5 - The Value of MEF with Silverlight Ian Griffiths has a video tutorial up at Channel 9 on MEF and Silverlight, posted by John Papa Introducing Blend 4 – For Silverlight, WPF and Windows Phone Christian Schormann has an early MIX10 post up about te new features in Expression Blend with regard to Silverlight, WPF, and WP7. Building your first Silverlight for Windows Phone Application Pete Brown has his first post up on building a WP7 app with the MIX10 bits. Lookups in DataGrid and DataForm with RIA Services Jeff Handley elaborates on a post by someone else about using lookup data in the DataGrid and DataForm with RIA Services Silverlight 4 + RIA Services - Ready for Business: Starting a New Project with the Business Application Template Brad Abrams is starting a series highlighting the key features of Silverlight 4 and RIA with the new releases. He has a post up Silverlight 4 + RIA Services - Ready for Business: Index, including links and source. Then in this first post of the series, he introduces the Business Application Template. Custom Window Chrome and Events Watch a tutorial video by Tim Heuer on creating custom chrome for OOB apps. 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

  • Silverlight Cream for December 18, 2010 - 2 -- #1013

    - by Dave Campbell
    In this Issue: Michael Washington, Pete Brown, Robby Ingebretsen, Bill Reiss, Jordan Knight, Mike Taulty, Justin Angel, Jeff Blankenburg. Above the Fold: Silverlight: "Creating the Silverlight View Model (MVVM) Control: Calendar Icon" Michael Washington WP7: "United Nations News for Windows Phone 7" Justin Angel Silverlight, WP7/WPF: "CameraPanel: A Parallax Panel for Silverlight, WP7 or WPF" Robby Ingebretsen Shoutouts: Michael Scherotter produced a Silverlight Webcam photo app that he's providing as a free install: A Free Webcam Photo Application in Silverlight From SilverlightCream.com: Creating the Silverlight View Model (MVVM) Control: Calendar Icon Michael Washington has a stunning Calendar Control/Icon up on his blog... walking through how he built it and how you can easily use it in your Silverlight or WP7 app. Strategies for Improving INotifyPropertyChanged in WPF and Silverlight Pete Brown takes a look at INPC and some of the ways this is dealt with to avoid some of the tedius code-reuse errors we all make. CameraPanel: A Parallax Panel for Silverlight, WP7 or WPF Robby Ingebretsen gives up the code for that cool panel he's got on his homepage where the small panels move about seemingly in space. Writing a Windows Phone 7 game? Have a fallback plan Bill Reiss, who has a great WP7 game up - Popper 2 - has a very well-thought-out post up about WP7 'indie' games and the future thereof... great comments from reader/authors as well Automatic template selection – marrying a view to a view model Jordan Knight has the 2nd post of his series on MVVM up... he's talking about it in context of their XamlingCore, but concepts are all good. Rebuilding the PDC 2010 Silverlight Application (Part 5) Mike Taulty's next episode in describing the development of the PDC10 app he wrote is up ... again lots of Blend goodness in this one where he's adding buttons to let the user (us) download whatever is available for the chosen session. United Nations News for Windows Phone 7 In a munificent gesture, Justin Angel not only made his United Nation News app free on the marketplace, but he's posted the source to CodePlex! Justin had sent me a XAP a couple weeks ago, but for some reason, I can no longer sideload so wasn't able to try it until now... too cool, Justin! What I Learned In WP7 – Issue #6 Jeff Blankenburg has his latest "What I learned in WP7" tip up ... and this is one about the marketplace written by someone that's been there and back a few times... 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

  • Team Review @ TSUG

    - by dmckinstry
    In case you haven’t heard, JB Brown is going to be presenting online at the Team System User Group this Thursday.  This month’s presentation will explain how Team Review (freely available) can be used with Team Foundation Server 2005, 2008 and even 2010! Meeting Date: Thursday, March 18th, 2010 Time: 5:00PM Pacific {Add to Calendar} {Join Meeting}

    Read the article

  • Silverlight Cream for May 17, 2010 -- #863

    - by Dave Campbell
    In this Issue: Christian Schormann, Vladimir Bodurov, Pete Brown, Justin Angel, John Papa(-2-), Fons Sonnemans, Miroslav Miroslavov, and Jeremy Likness. Shoutouts: Jeff Brand has been doing WP7 presentations and posted Windows Phone 7 Presentation and Sample Code Mark Tucker posted about his Windows Phone 7 Presentation at Desert Code Camp 2010 John Allwright discusses 4 New case Studies on Silverlight at the Winter Olympics From SilverlightCream.com: New Video by Jon Harris: Blend 4 for Windows Phone in 90 Seconds Christian Schormann is discussing a second 90-second Expression Blend video tutorial by Jon Harris... this second one is about Blend 4 for WP7. XmlCodeEditor – Silverlight 4 control for editing XML and HTML on the browser Vladimir Bodurov has a post up extending the RichTextBox control to add coloring for HTML and XAML ... it colors as you type, and he plans on adding Intellisense! Creating a Simple Report Writer in Silverlight 4 While working on his book, Pete Brown decided to share some Silverlight 'Report Writer' work with us... check out that list of goals near the top that are all met... looks great to me! Windows Phone 7 - Unlocked ROMs Justin Angel has a good long post about a subject I've stayed away from until now that someone of Justin's level of knowledge has approached it: WP7 ROMs. Silverlight 4 Tools for Visual Studio 2010 Launch: New Designer Capabilities (Silverlight TV 27) John Papa has Silverlight TV 27 up today and is talking about the Silverlight 4 Tools for VS2010 launch with Mark Wilson-Thomas ... the video would be a great place to pick up some of the new features (hint, hint) WCF RIA Services v1.0 Launch! (Silverlight TV 28) John Papa also has Silverlight TV 28 up, talking with Nikhil Kothari and Dinesh Kulkarni about the v 1.0 release of WCF RIA Services. RightMouseTrigger Fons Sonnemans updated his MineSweeper game and has it posted at Silver Arcade, this version supports right mouse click via RightMouseTrigger code that he is sharing. Smoke effect The 'Smoke Effect' menus at the CompleteIT site are awesome, and this time out, Miroslav Miroslavov discusses how that was done and gives up the code...! WebClient and DeploymentCatalog gotchas in Silverlight OOB Jeremy Likness has a post up to give you some relief if you hit the same MEF/Silverlight gotcha he did when running OOB... like not running in OOB for instance. 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

  • Is Nick Clegg a man or a mouse?

    - by BizTalk Visionary
    Well we got the hung election so many of us wanted! I believe it really is time for electoral change. Why? Consider: the ConMen under Cameroon have polled 36% of the great British voting public – well those that got to vote!! That means 64% of us don’t want him as PM. So what gives him the right to govern? Well an ancient voting system ideal for two party politics. But for the last 30 years we’ve had multi-party politics and going forward we may see 4 or 5 parties stepping up. We have to set in place a system that makes this work! So what does that mean today: Nick has a golden chance to push forward the case and in fact the absolute right for the change. He needs to keep this in mind when he discusses coalition with both Labour and the ConMen. So the mouse approach: Decides it is only fair to side with the ‘biggest’ vote and team up with the ConMen. Chances of electoral change? Big fat zero. Chance of achieving any of his other targets. Big fat zero. Why? Simple (as the Meer Kat would say). Cameroon needs to become PM by hook or crook. Once PM he holds the whip hand. Labour will dump Brown and head off into Leadership race land, Clegg will be knocking on number 10, having meaningless meetings and seeing no reward. Finally while Labour is at 6‘s and 7’s  the ‘new’ PM will call a new election, gain the majority they need and dump luckless Nick!! So the man approach: Team up with Labour. As one of the conditions – Brown to go. Run referendum for PR. Get PR through then force Labour to have new election under PR. Nick now hero and should be in a much better place following a PR election!! The man bit is standing up to the media attack for supporting Labour. Come Nick – be a man for a better Britain!!

    Read the article

  • Is Nick Clegg a man or a mouse?

    - by BizTalk Visionary
    Well we got the hung election so many of us wanted! I believe it really is time for electoral change. Why? Consider: the ConMen under Cameroon have polled 36% of the great British voting public – well those that got to vote!! That means 64% of us don’t want him as PM. So what gives him the right to govern? Well an ancient voting system ideal for two party politics. But for the last 30 years we’ve had multi-party politics and going forward we may see 4 or 5 parties stepping up. We have to set in place a system that makes this work! So what does that mean today: Nick has a golden chance to push forward the case and in fact the absolute right for the change. He needs to keep this in mind when he discusses coalition with both Labour and the ConMen. So the mouse approach: Decides it is only fair to side with the ‘biggest’ vote and team up with the ConMen. Chances of electoral change? Big fat zero. Chance of achieving any of his other targets. Big fat zero. Why? Simple (as the Meer Kat would say). Cameroon needs to become PM by hook or crook. Once PM he holds the whip hand. Labour will dump Brown and head off into Leadership race land, Glegg will be knocking on number 10, having meaningless meetings and seeing no reward. Finally while Labour is at 6‘s and 7’s  the ‘new’ PM will call a new election, gain the majority they need and dump luckless Nick!! So the man approach: Team up with Labour. As one of the conditions – Brown to go. Run referendum for PR. Get PR through then force Labour to have new election under PR. Nick now hero and should be in a much better place following a PR election!! The man bit is standing up to the media attack for supporting Labour. Come Nick – be a man for a better Britain!!

    Read the article

  • Daily tech links for .net and related technologies - Apr 8-10, 2010

    - by SanjeevAgarwal
    Daily tech links for .net and related technologies - Apr 8-10, 2010 Web Development Using RIA DomainServices with ASP.NET and MVC 2 - geekswithblogs Using AntiXss As The Default Encoder For ASP.NET - Phil Haack New Syntax for HTML Encoding Output in ASP.NET 4 (and ASP.NET MVC 2) - Scott Gu Multi-Step Processing in ASP.NET - Dave M. Bush MvcContrib - Portable Area – Visual Studio project template - erichexter Encoding/Decoding URIs and HTML in the .NET 4 Client Profile - Pete Brown Jon Takes Five...(read more)

    Read the article

  • Silverlight Cream for April 20, 2010 -- #842

    - by Dave Campbell
    In this Issue: Zoltan Arvai, Svetla Stoycheva, Alexey Zakharov, Chris Rouw, David Anson(-2-), Bill Reiss, John Papa and Adam Kinney, Chris Klug, CorrinaB, and Mike Snow. Shoutouts: Pete Brown interviewed David Kelley at MIX10: Pete at MIX10: David Kelley on the Prototype WPF and Silverlight Retail Experience Pete Brown also interviewed Emil Stoychev at MIX10: Pete at MIX10: Emil Stoychev on the CompletIT Silverlight Site SilverlightShow has a MIX10 Review by SilverlightShow Live Reporter Cigdem Patlak SilverlightShow also has an Interview with SilverlightShow Article Author Andrej Tozon From SilverlightCream.com: Implementing Push Notifications in Windows Phone 7 Zoltan Arvai has a post up on SilverlightShow discussing Push Notification on WP7 ... what it is, and how to use it. Completit.com - the challenges behind building a corporate website in Silverlight Svetla Stoycheva shows off the new CompleteIT corporate website which is pretty darn cool... and disucusses some of the challenges and solutions Introducing to Halcyone - Silverlight Application Framework: Silverlight Rest Extensions Alexey Zakharov has a tutorial up on a Silverlight application framework he's working on called Halcyone which is available on CodePlex Using the Tag Property during Silverlight Binding Chris Rouw details his SL3 to SL4 conversion and some issues he had, and how he was able to resolve a binding problem using the tag property. Using ContextMenu to implement SplitButton and MenuButton for Silverlight (or WPF) David Anson has a cool discussion up of using the ContextMenu code he put up previously to build a Split button, and includes all the code as usual. Silverlight/WPF Data Visualization Development Release 4 and Windows Phone 7 Charting sample! David Anson updated his Data Visualization because of the new releases, and this time he's including WP7... charting in WP7... ! Space Rocks game step 10: More fun with rocks In episode 10, Bill Reiss shows how to deal with multiple asteroids and all the interaction. Silverlight Training Course (Silverlight 4) Get your serious Silverlight 4 Mojo on with a new SL4 Training kit on Channel 9 ... buncha folks, spearheaded (it looks like) by John Papa and Adam Kinney... Plug-ins and composite applications in Silverlight – pt 3 Chris Klug is back with part 3 of his series on extensions and plug-in loading. So far he's covered a roll-your-own concept and MEF, now he digs into Prism. Transitions, Animations, and Effects with Blend - Part One How cool to have CorrinaB speak at your User Group meeting! ... She did just that in Portland, and instead of simply dropping a deck and some code in her blog, she's giving the run-down on her presentation... always good stuff, Corrina! Tip of the Day #110 – Using Static Resources in Class Libraries Mike Snow's latest tip is about how to create and use a Resource Dictionary. 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 21 22 23 24  | Next Page >