Search Results

Search found 276 results on 12 pages for 'stewart robinson'.

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

  • Infinite scrolling in Silverlight

    - by shannon.stewart
    I've found a few questions about infinite scrolling already posted, but none were about Silverlight, so I thought I'd ask. I've done some initial searching, but haven't been able to find any reference material on how to implement infinite scrolling in Silverlight. This is more of a brain-storming exercise so I can get some thoughts on different ways to implement this.

    Read the article

  • Possible bug in ASP.net UpdatePanel control?

    - by Ben Robinson
    I have come across what seems to be an annoying bug with asp.net UpdatePanels in 2 seperate projects. If you have some kind of autopostback enabled control that can cause all of the controls in the update panel to have visible=false set, resulting in an empty update panel. When you change the autopostback control back to the postion that would re enable all of the controls in the update panel, it simply does not make a call back to the server and the update panel does not update. If you do anything else that makes a call back on the same page, then the update panel contents magically appear. It is as if asp.net has decided the update panel is empty so there is no point maikng a callback, even though making the call back would fill the updatepanel with content. The only way round this is to add a style of display:none to the controls instead of setting visible=false property. Then it works fine. Has anyone else encountered this problem? Is it a bug as i suspect or is it likely i am doing soemthing wrong? I haven't got time to post example code at the moment as the code i am using is too wrapped up in other unrealted things, if people think it would help i will create a simple example and post it when I get time.

    Read the article

  • Looking for a good text parsing library for C#

    - by Chris Stewart
    Has anyone run across a quality library that will parse, line by line, CSV, tab-delimited, and Excel files? I've started to do it manually but have noticed some of the intricacies in parsing a comma-delimited file. Such as situations where a cell has a comma in it as part of the data (blah,\"LastName, Jr.\",blah,blah).

    Read the article

  • I'm having trouble with using std::stack to retrieve the values from a recursive function.

    - by Peter Stewart
    Thanks to the help I received in this post: http://stackoverflow.com/questions/2761918/how-do-i-use-this-in-a-member-function I have a nice, concise recursive function to traverse a tree in postfix order: void Node::postfix() { if (left != __nullptr) { left->postfix(); } if (right != __nullptr) { right->postfix(); } cout<<cargo<<"\n"; return; }; Now I need to evaluate the values and operators as they are returned. My problem is how to retrieve them. I tried the std::stack: #include <stack> stack <char*> s; void Node::postfix() { if (left != __nullptr) { left->postfix(); } if (right != __nullptr) { right->postfix(); } s.push(cargo); return; }; but when I tried to access it in main() while (!s.empty()) { cout<<s.top<<"\n"; s.pop; } I got the error: 'std::stack<_Ty::top': function call missing argument list; use '&std::stack<_Ty::top' to create a pointer to member' I'm stuck. Another question to follow shortly.

    Read the article

  • Pushing to a UITable inside a UIView from a UITableview

    - by Michael Robinson
    I can firgure out how to push a UIView from a Tableview and have the "child" details appear. Here is the view I'm trying to load: Here is the code that checks for children and either pushes a itemDetail.xib or an additional UITable, I want to use the above .xib but load the correct contents "tableDataSource" into the UItable: - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { //Get the dictionary of the selected data source. NSDictionary *dictionary = [self.tableDataSource objectAtIndex:indexPath.row]; //Get the children of the present item. NSArray *Children = [dictionary objectForKey:@"Children"]; if([Children count] == 0) { ItemDetailViewController *dvController = [[ItemDetailViewController alloc] initWithNibName:@"ItemDetailView" bundle:[NSBundle mainBundle]]; [self.navigationController pushViewController:dvController animated:YES]; [dvController release]; } else { //Prepare to tableview. FirstTab *rvController = [[FirstTab alloc] initWithNibName:@"FirstView" bundle:[NSBundle mainBundle]]; //Increment the Current View rvController.CurrentLevel += 1; //Set the title; rvController.CurrentTitle = [dictionary objectForKey:@"Title"]; //Push the new table view on the stack [self.navigationController pushViewController:rvController animated:YES]; rvController.tableDataSource = Children; [rvController release]; } } Thanks for the help. I see lots of stuff on this but can't find the correct push instructions.

    Read the article

  • Should I Return "500" or "404" if a Requested Image is not Found?

    - by Michael Robinson
    I work with code written by other people, occasionally I am left somewhat confused and at these times Stack Overflow saves me. Please, save me again. Our site allows people to upload images and later embed them within text in our site like so: <img src="http://site.com/image_script.php?p=some_image_identifier"/> My question is: If the identifier, "p", does not lead us to an image should the server return "500" or "404"? I would have thought it should be "404", but that's not what is happening right now.

    Read the article

  • How do I write an IF ELSE to check string contents of an array?

    - by Michael Robinson
    I'm trying to write an IF ELSE statement to enable shipping, If user doesn't add an address the array contents remain as "-" & "-" for the two items in the array. I want to check to see if those are in the array, if they are then I want to enableshipping. Here is the code for getting the array: NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *fullFileName = [NSString stringWithFormat:@"%@/arraySaveFile", documentsDirectory]; NSMutableArray *array = [[NSMutableArray alloc] initWithContentsOfFile:fullFileName]; How do I write this first line to look for the "-" & "-"? if ([fullFileName isEqualToString:@"-","-"]) { [nnNEP EnableShipping]; } else { [nnNEP DisableShipping]; } Thanks, michael

    Read the article

  • Random Pairings that don't Repeat

    - by Andrew Robinson
    This little project / problem came out of left field for me. Hoping someone can help me here. I have some rough ideas but I am sure (or at least I hope) a simple, fairly efficient solution exists. Thanks in advance.... pseudo code is fine. I generally work in .NET / C# if that sheds any light on your solution. Given: A pool of n individuals that will be meeting on a regular basis. I need to form pairs that have not previously meet. The pool of individuals will slowly change over time. For the purposes of pairing, (A & B) and (B & A) constitute the same pair. The history of previous pairings is maintained. For the purpose of the problem, assume an even number of individuals. For each meeting (collection of pairs) and individual will only pair up once. Is there an algorithm that will allow us to form these pairs? Ideally something better than just ordering the pairs in a random order, generating pairings and then checking against the history of previous pairings. In general, randomness within the pairing is ok.

    Read the article

  • Verifying existence of name and password in NSUserDefaults to Skip a login/Screen

    - by Michael Robinson
    I have a Tabbar/Tableview App that modally loads a Login/Signup view when the app loads, I have set up a Root.plist in a settings bundle for the name and password and have successfully retrieved the items. I want to be able to do two things: 1) Do a test to see if the NSUserDefault Strings are empty and if so load the Login/Signup view. 2) If the strings are available then use the string contents to login to my Webservice. Thanks in advance. Here is my LoginViewController .m : @synthesize usernameField; @synthesize passwordField; @synthesize loginButton; @synthesize loginIndicator; @synthesize usernameLabel; @synthesize passwordLabel; -(void)refreshFields { NSUserDefaults *defaults = [NSUserDefaults standardUserDefaults]; usernameLabel.text = [defaults objectForKey:kUsernameKey]; passwordLabel.text = [defaults objectForKey:kPasswordKey]; } - (void)viewDidAppear:(BOOL)animated { [self refreshFields]; [super viewDidAppear:animated]; } - (void)viewDidLoad { [super viewDidLoad]; [self refreshFields]; [self.navigationController setNavigationBarHidden:YES animated:NO]; } - (IBAction) login: (id) sender { { NSString *post =[NSString stringWithFormat:@"username=%@&password=%@",usernameField.text, passwordField.text]; NSString *hostStr = @"http:~iphone_login.php?"; hostStr = [hostStr stringByAppendingString:post]; NSData *dataURL = [NSData dataWithContentsOfURL: [ NSURL URLWithString: hostStr ]]; NSString *serverOutput = [[NSString alloc] initWithData:dataURL encoding: NSASCIIStringEncoding]; NSLog(@"Site: %@",hostStr); NSLog(@"Site: %@",serverOutput); if([serverOutput isEqualToString:@"Yes"]){ UIAlertView *alertsuccess = [[UIAlertView alloc] initWithTitle:@"Congrats" message:@"You are authorized " delegate:self cancelButtonTitle:@"OK" otherButtonTitles:nil, nil]; [alertsuccess show]; [alertsuccess release];

    Read the article

  • Apache Rewrite - put parts of query string in replacement string

    - by Rangi Robinson
    Hello, I'd like to rewrite: www.example.com/file.html?username=john&number=1234 To: www.example.com/users/john But I can't figure out how to extract the "username" value from the query string. I've been Googling this all morning and reading the official docs but no luck. I need to solve this problem with a rewrite, rather than changing the application. Any help much appreciated! Rangi

    Read the article

  • Visual Basic Speech Recognition Examples?

    - by Cody.Stewart
    I am looking for some good examples of Speech Recognition using VB. I am looking for recent examples, everything I have found is several years old. I am running Visual Studio 2010 with the most recent SDK. I was able to figure out text to speech but I am chasing my tail on speech to text.

    Read the article

  • Get Angle to Tangent that Intersects Point

    - by Christian Stewart
    I have a circle around a given point, call this point (x1, y1). I know the radius of the circle around this point. I also have a second point (x2, y2), that is a distance away, outside the radius of the circle. I need a algebraic way through code to calculate the heading (angle from vertical) needed to intersect the circle at 90* to the center point (I.E. get the angle of the tangent intersecting line 2) around the point (x1, y1) from the second point (x2, y2) A bit of background: Essentially the two points are GPS coordinates on a 2D map, I need to know the target heading to intersect the circle in order to follow its path around the center point. Thanks! Christian

    Read the article

  • Modifying NSMutableDictionary from a single index format into nested (array within array)

    - by Michael Robinson
    I need to take the member ID off the top of this and create an array inside that contains the rest of the JSON return. Here is my JSON return. [{"F_Name_VC":"Frank", "L_Name_VC":"Johnson", "userid":"18", "age":"23", },] After it is json-deserialized it looks like this: I need convert it to be transformed into this, with children sub-array: Someone else posted a similar question but without the fact that it was coming from a JSON deserialization. There were two answers but no conclusion to the question. (Answer 1): NSDictionary *item1 = [NSDictionary dictionaryWithObjects:[NSArray arrayWithObjects:@" member",[NSNumber numberWithInt:3],nil] forKeys:[NSArray arrayWithObjects:@"Title",@"View",nil]]; Answer (2): NSMutableArray *Rows = [NSMutableArray arrayWithCapacity: 1]; for (int i = 0; i < 4; ++i) { NSMutableArray *theChildren = [NSMutableArray arrayWithCapacity: 1]; [theChildren addObject: [NSString stringWithFormat: @"tester %d", i]]; NSString *aTitle = [NSString stringWithFormat: @"Item %d", i]; NSDictionary *anItem = [NSDictionary dictionaryWithObjectsAndKeys: aTitle, @"Title", theChildren, @"Children"]; [Rows addObject: anItem]; } NSDictionary *Root = [NSDictionary withObject: Rows andKey: @"Rows"]; Here is my JSON return and save code: NSData *jsonData = [jsonreturn dataUsingEncoding:NSUTF32BigEndianStringEncoding]; NSError *error = nil; NSDictionary * dict = [[CJSONDeserializer deserializer] deserializeAsDictionary:jsonData error:&error]; if (dict) { rowsArray = [dict objectForKey:@"member"]; [rowsArray retain]; } Thanks in advance. Every tutorial on JSON only shows a simple array being returned, never with children..It's driving me crazy trying to figure this out.

    Read the article

  • Blackberry User Interface Design - Customizable UI?

    - by John Stewart
    I am trying to design a Blackberry Application and I am wondering if there are any resources on how to create custom user interface elements, skin existing ones and what other possibilities are there? I have developed a few iPhone applications with custom UI and stuff, so not sure what BB world offers in terms of UI development. Any tips, suggestions or ideas would be great.

    Read the article

  • Entity-attribute-value model using codeigniter / php

    - by John Stewart
    SO I am trying to create a way to structure my database to be able customize forms. I looked into EAV pattern and here is my db structure: Table form - form_id - form_name - form_added_on - form_modified_at Table: form_fields - field_id - form_id - field_type (TEXT, RADIO etc..) - field_default_value - field_required Table: form_data - data_id - field_id - form_id - field_value so now I can store any custom form into the database and if I want to get the values for an individual form I can simply join it by "form_id" .. the problem: I want to be able to search through all the forms for a specific field value. How can I do that with EAV model? Also, I thought about just storing the custom data as a serialized (JSON) object but then I am not sure how can I query that data. Please note that I am using Codeigniter with MYSQL. So if conversation can use Codeigniter libraries if needed.

    Read the article

  • How would one use Cocos2d to create a game like this.

    - by John Stewart
    http://itunes.apple.com/us/app/angry-birds/id343200656?mt=8&ign-mpt=uo%3D6 So I am getting started with this all game dev thing on iphone and I decided that I will start playing with Cocos2d as my starting engine. Now just so i have a goal in mind, I picked angry birds as my initial target of what sort of game play would I like to learn to build. This is not going to be a market release game. This is totally going to be learning purposes only. So to start off my question is: Would something like this be achievable using Cocos2d? How would I go about building the physics for this? How can one do a screen scroll like the way they do in cocos2d? (any example code would be great) This is just to start off. If you have any particular questions please do add to this question.

    Read the article

  • mySql table returning JSON that needs formatting for a iPhone UITableview

    - by Michael Robinson
    I have a php query the returns the following JSON format from a table. [{"memberid":"18", "useridFK":"30", "loginName":"Johnson", "name":"Frank", "age":"23", "place":"School", }, It needs the following format: [{"memberid":"18" { "useridFK":"30", "loginName":"Johnson", "name":"Frank", "age":"23", "place":"School",} }, I can figure out where/how to convert this, Where would I create the formatting following: (1) In the php return? (2) the JSON instructions for deserialization? or (3) Some kinb of Obj-C coding instruction? My end use is a simple Drill Down table using the NSObject, so when I select "memberid" row, I'll get the child/detail list on the next UITableview. My Data.plist will look like the following: Root: Dictionary V Rows: Array V Item 0: Dictionary Title: String 18 V Children Array V Item 0 Dictionary Title String 30 etc. Thanks in advance, this site rocks.

    Read the article

  • Copying (or recovering) a .PFX password to another machine?

    - by Adam Robinson
    First things first, I'm aware of all of the finger-wagging potential that this question provides. However, I'm attempting to help out a friend with a project so I haven't been part of the decision making process thus far. I'm attempting to set up a new development machine, but one of the projects is signed with a .PFX key that's password protected and the original developer does not remember the password. The current development machine can open and build the project just fine, so I'm wondering if there is any way either to copy or to recover the saved password that Visual Studio is using on the original box so that the file can be used on the new box. Signing with a new file is obviously an option, but one that we'd prefer to avoid. Does anyone know of a way either to recover or copy the credentials for this file to a new machine?

    Read the article

  • Invoking a PL/SQL function from EclipseLink

    - by Mark Robinson
    I'm trying to execute a PL/SQL function in EclipseLink which uses Oracle Specific types(eg. Boolean). I've tried using PLSQLStoredProcedureCall which complains that I'm not executing a procedure and I have tried using StoredFunctionCall but that returns PLS-00382: expression is of wrong type Has anyone developed a solution to invoke functions in EclipseLink with Oracle Types? I have heard that it would be possible to extend StoredFunctionCall but I'd rather leverage existing functionality as much as possible.

    Read the article

  • How can a large number of developers write software together without either a cumbersome process or

    - by Mark Robinson
    I work at a company with hundreds of people writing software for essentially the same product. The quality of the software has to be high because so many people depend on it (not least the developers themselves). Because of this every major issue has resulted in a new check - either automated or manual. As a result the process of delivering software is becoming ever more burdensome. So that requires more developers which... well you can see it is a vicious circle. We now have a problem with releasing software quickly - the lead time even to change one line of code for a very serious issue is at least one day. What techniques do you use to speed up the delivery of software in a large organization, while still maintaining software quality?

    Read the article

  • Reporting Services Matrix Order

    - by James Stewart
    I've got a reporting services report which display data in a matrix. The matrix rows are ordered by the report on a specific field's value. Trouble is I want a particular value to always appear last in the matrix even though it won't naturally be ordered there. Is there a way I can do this using an expression? Thanks.

    Read the article

  • Why do software engineers hate writing documentation?

    - by Stewart Johnson
    I ask because I quite enjoy it! I'm talking about design documentation and implementation notes (NOT user manuals), which are non-existent in most of the codebases I've been handed. I can understand why a developer wouldn't want to write requirements (that's the analyst's job) or the user documentation (that's a technical writer's job) but I don't get why developers hate writing design docs. I don't think I would feel as if I'd finished the job if I only wrote the code and walked away -- mainly because when I've been introduced to code-only situations I've seen how hard it is to figure out what's been done and what the software does. I would hate for people to suffer the same situation when inheriting my code. What makes you loath writing supporting documentation for your code?

    Read the article

  • Iterative / Additive MD5

    - by Andrew Robinson
    I need to generate a checksum over a dictionary. Keys and Values. Is there any simple way to accomplish this in an iterative way. foreach(var item in dic.Keys) checksum += checksum(dic[item]) + checksum(item); In this case, keys and values could be converted to strings, concatinated and then a single checksum applied over these but is there a better way? Ideally MD5 but other options could work. Using this to validate data that is passed over a couple of storage methods. The checksum is then encrypted along with some other information (using AES) so I am not horribly worried about an ideal, unbreakable checksum.

    Read the article

  • Efficient Method for Preventing Hotlinking via .htaccess

    - by Michael Robinson
    I need to confirm something before I go accuse someone of ... well I'd rather not say. The problem: We allow users to upload images and embed them within text on our site. In the past we allowed users to hotlink to our images as well, but due to server load we unfortunately had to stop this. Current "solution": The method the programmer used to solve our "too many connections" issue was to rename the file that receives and processes image requests (image_request.php) to image_request2.php, and replace the contents of the original with <?php header("HTTP/1.1 500 Internal Server Error") ; ?> Obviously this has caused all images with their src attribute pointing to the original image_request.php to be broken, and is also the wrong code to be sending in this case. Proposed solution: I feel a more elegant solution would be: In .htaccess If the request is for image_request.php Check referrer If referrer is not our site, send the appropriate header If referrer is our site, proceed to image_request.php and process image request What I would like to know is: Compared to simply returning a 500 for each request to image_request.php: How much more load would be incurred if we were to use my proposed alternative solution outlined above? Is there a better way to do this? Our main concern is that the site stays up. I am not willing to agree that breaking all internally linked images is the best / only way to solve this. I refuse to tell our users that because of something WE changed they must now manually change the embed code in all their previously uploaded content.

    Read the article

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