Search Results

Search found 165 results on 7 pages for 'srikanth naidu'.

Page 5/7 | < Previous Page | 1 2 3 4 5 6 7  | Next Page >

  • Can we send an two dimensional array as input for a function in Objective C.

    - by srikanth rongali
    I have data stored in two dimensional array. I want it to send in to a function in this way, I have written the following in another class. // do if( array[iTemp][1] != 10 ) { Enemy *enemyXX = [[Enemy alloc] init]; [enemyXX EnemyXXTarget: array[iTemp][1]]; iTemp++; }while( iTemp != 9); // -(void)EnemyXXTarget:(id)sender; is function declared in Enemy class. But is giving me an error error: incompatible type for argument 1 of 'EnemyXXTarget:' Where I am wrong ? Please help me. Thank You.

    Read the article

  • In cocos2D how to write a selector for a sprite.

    - by srikanth rongali
    Hello, I got problem in cocos2D application. I have a sprite and text in one screen. The text should be able to move up/down when we swipe. And when we select on the sprite it should take to next scene. So, both should have the istouchEnabled to YES. But text should take the touchesMoved and sprite should take touchesEnded. But my problem is either one is working. If am able to swipe the text, I am not able to select the sprite.( touchesEnded for sprite is not called). Please guide me, I am stuck here.

    Read the article

  • Managed C++ prospects

    - by Srikanth
    Has anyone tried coding in managed C++? I have a few questions : How productive is the language compared to C#? Is there any restriction on type of projects that can be written? Can we write a web application in managed C++? Is it possible to mix managed and unmanaged C++ code in one application? Is MFC still valid in managed C++? Will it be the best option when considering migration of a VC++ application?

    Read the article

  • How to set the the height of cell progamatically without using nib file ?

    - by srikanth rongali
    This is my program - (void)viewDidLoad { [super viewDidLoad]; // Uncomment the following line to display an Edit button in the navigation bar for this view controller. self.title = @"Library"; self.navigationItem.rightBarButtonItem = [[UIBarButtonItem alloc] initWithTitle:@"Close" style:UIBarButtonItemStyleBordered target:self action:@selector(close:)]; // self.tableView.rowHeight = 80; } -(void)close:(id)sender { // } - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *CellIdentifier = @"Cell"; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithFrame:CGRectZero reuseIdentifier:CellIdentifier] autorelease]; UILabel *dateLabel = [[UILabel alloc]init]; dateLabel.frame = CGRectMake(85.0f, 6.0f, 200.0f, 20.0f); dateLabel.tag = tag1; [cell setAccessoryType:UITableViewCellAccessoryDisclosureIndicator]; cell.contentView.frame = CGRectMake(0.0f, 0.0f, 320.0f, 80.0f); [cell.contentView addSubview:dateLabel]; [dateLabel release]; } // Set up the cell... //[(UILabel *)[cell viewWithTag:tag1] setText:@"Date"]; cell.textLabel.text = @"Date"; return cell; } I am setting the frame size of cell in tableView: but the cell is in default size only. I mean the height I set was 80 but it was not set as 80 height. How can I make it. Thank You

    Read the article

  • How we should load theMFMailComposeViewController in cocos2d ?

    - by srikanth rongali
    I am writing an app in using cocos2d. This method I have written for the selector goToFirstScreen: . The view is in landscape mode. I need to send an email. So, I need to launch the MFMailComposeViewController. I need it in portrait mode. But, the control is not entering in to viewDidLoad of the mailMe class. The problem is in goToScreen: method. But, I do not get where I am wrong ? -(void)goToFirstScreen:(id)sender { CCScene *Scene = [CCScene node]; CCLayer *Layer = [mailME node]; [Scene addChild:Layer]; [[CCDirector sharedDirector] setAnimationInterval:1.0/60]; [[CCDirector sharedDirector] pushScene: Scene]; } Thank you .

    Read the article

  • Integrate variable data with div tag in asp.net

    - by Srikanth Mattihalli
    Hi all, I have this code: I need to replace 800px and 300px from database value; I tried both of the below. But still i am not getting the answer. Method 1: <div id="container" style="width:'<% Response.Write(width);%>'px; height:'<% Response.Write(height);%>'px; margin: 0 auto;overflow:hidden;"></div> Method 2: <div id="container" style="width:'<%# Eval("width");%>'px; height: <%# Eval("height");%>'px; margin: 0 auto;overflow:hidden;"></div> The value of height and width variables are defined in page_load() function int height=300; int width= 800; This is not affecting the resulting web page. Can anyone help me on this.

    Read the article

  • can I use NSDictionary values as [@"[array abjectAtIndex:value]", key1,nil] ?

    - by srikanth rongali
    I have a string of comma separated values in this way (0.2,0.3,0.4,1.0). I used componentsSeperatedByString to store the values in an NSArray. Now I need to store them in NSDictionary as (1st value from NSArray), key1, (2nd Value of NsArray), key2,..nil]; My program is in this way NSArray *split1; NSDictionary *enemy1; float value1; for(id line in lines) { string1 = line; split1 = [string1 componentsSeparatedByString:@","]; numberOfValues = [split1 count]; for(id value in split1) { enemy1 = [NSDictionary dictionaryWithObjectsAndKeys:@"[[split1 objectAtIndex:0]flaotValue]", @"A1", nil]; } } value1 = [enemy1 objectForKey:@"A1"]; Here lines is an NSArray consisting of CSV strings of number 10. I am getting error as error: incompatible types in assignment Should I do not write my code in this way? Where I doing wrong ? Please tell me my mistakes. Thank You.

    Read the article

  • loading table view on click of button

    - by srikanth
    hi all, i have created an iPhone application with a view based .. the problem is i want to load a table view on click of button how can i do it? i tried.. initWithNibName:@"xibfile" bundle:[NSBundle mainBundle]... but table view is not loading wat to do?

    Read the article

  • Io exception: There is no process to read data written to a pipe.

    - by Srikanth
    I'm using Hibernate3.2+Websphere6.0+struts1.3.. After deploying ,application works fine. After some idle time ,i will get this type of error repeatedly,am not able to login at all. Im not using any connection pooling. i feel after idle time its not able to connect to the database again..if i restart the server everything works fine for some time...after that same story.. please help me out

    Read the article

  • How to delete a cell in UITableView by using custom button in cell ?

    - by srikanth rongali
    I have UITableView. I customized the cell height (increased). I have 4 labels(UILabel) and 1 image(UIImage) and 3 buttons (UIButton). one of the button is delete button. By touching the cell or button(play button) on the image a video is loaded and played. I need to delete the cell by touching delete button. If I touched the delete button the corresponding video is deleted from library . But, how to delete the cell and all remaining data in it ? I am not able to delete the cells or the data in the cells. How to do it ? I used these. But the control is not entering in to second method committedEditingStyle: - (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath { return YES; } - (void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath { if (editingStyle == UITableViewCellEditingStyleDelete) { } } Thank you. The following image shows the delete button of my program.

    Read the article

  • How can I retain the data stored in plist from UITextField when application is restarted ?

    - by srikanth rongali
    I am using the plist to store the data entered in the UITextFields. But, when I restart my application all the data entered previously was deleted. How can I retain the data in the Plist. I have a UITableView and when a cell is touched a view appears with two UITextFields. nameField and descriptionField. I stored the data in this way. My code is. -(void)save:(id)sender { indexOfDataArray = temp; //the cell selected in table view. NSString *string1 = [[NSString alloc]init]; NSString *string2 = [[NSString alloc]init]; string1 = nameField.text; string2 = descriptionField.text; NSDictionary *myDict = [[NSDictionary alloc] initWithObjectsAndKeys:string2, string1, nil]; [myArray addObject:myDict]; //myArray is NSMutableArray declared in tableViewController class. //[myArray insertObject:myDict atIndex:indexOfDataArray]; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *path = [documentsDirectory stringByAppendingPathComponent:@"tableVideoData.plist"]; [myArray writeToFile:path atomically:YES]; UIAlertView *alertMesage = [[UIAlertView alloc] initWithTitle: @"Save Alert" message:@"The data entered is saved" delegate:nil cancelButtonTitle:@"cancel" otherButtonTitles:nil] ; [alertMesage show]; [alertMesage release]; } When I am using the [myArray insertObject:myDict atIndex:indexOfDataArray]; It is giving the error *** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[NSCFArray insertObject:atIndex:]: index (2) beyond bounds (1)' So I used [myArray addObject:myDict]; Please help me, how can I retain the data in plist. Thank You.

    Read the article

  • How can I send email from my application ?

    - by srikanth rongali
    I want to attach a video and send email from my application. I downloaded apples example code MailComposer. I compiled it. I did not get any errors or warnings. I sent the mail to my mail id. But, I could not see any mail in my inbox. I am working on simulator. I did not set any senders email id in simulator. How can I know whether the code is working or not ? Thank You.

    Read the article

  • How can we show the preview image of the video in table view cell ?

    - by srikanth rongali
    I have a table view and if we touch a cell a video plays. I need to show the preview image of the video in the UITableViewCell. I have kept some dummy image in the cell at image place and remaining space ion cell is with some labels and buttons. I need the image preview of the video with play symbol on it. How can I make this ? Should I use any photoshop type of things or any programable things. I do not know photoshop. Thank You.

    Read the article

  • Cocos2d on iPhone: Using Sprites Defined in Separate Class Files.

    - by srikanth rongali
    I'm trying to draw two sprites on the same screen. I have defined the two sprite objects in two separate class files. If I comment out two lines (see "item 1" comment below) then I get a display as [a backgroundimage[background2.jpg] with a sprite[grossini.png] on the left side. If I uncomment the two lines I do not get the background image and sprite of (gameScreen.m). I get only the sprite [grossinis_sister1.png] defined in (enemy.m). But what I need is a [backgroundimage[background2.jpg]], sprite[grossini.png] and sprite [grossinis_sister1.png] in one screen. This is implementation file of my first class: #import "gameScreen.h" #import "enemy.h" @implementation gameScreen -(id)init { if((self = [super init])) { CCSprite *backGroundImage = [CCSprite spriteWithFile:@"background2.jpg"]; backGroundImage.anchorPoint = ccp(0,0); CCParallaxNode *voidNode = [CCParallaxNode node]; [voidNode addChild:backGroundImage z:-1 parallaxRatio:ccp(0.0f,0.0f) positionOffset:CGPointZero]; [self addChild:voidNode]; CGSize windowSize = [[CCDirector sharedDirector] winSize]; CCSprite *player = [CCSprite spriteWithFile:@"grossini.png"]; player.position = ccp(player.contentSize.width/2, windowSize.height/2); [self addChild:player z:0]; //eSprite = [[enemy alloc]init]; //<-- see item 1 //[self addChild:eSprite]; } return self; } This is my implementation file of my second class: #import "enemy.h" #import "gameScreen.h" @implementation enemy -(id)init { if ((self = [super init])) { CGSize windowSize = [[CCDirector sharedDirector] winSize]; CCSprite *enemySprite = [CCSprite spriteWithFile:@"grossinis_sister1.png" ]; enemySprite.position = ccp(windowSize.width/2, windowSize.height/2); [self addChild:enemySprite]; } return self; } @end

    Read the article

  • How can we add scrolling text in cocos2d by using UITextView ?

    - by srikanth rongali
    I want a UITextView in cocos2d. I used in init method I wrote the code, UITextView *textView = [[UITextView alloc] initWithFrame:CGRectMake(0,0, windowSize.height/2,windowSize.width/2)]; textView.backgroundColor = [UIColor clearColor]; textView.text = @"I am First enemy"; [textView setEditable:NO]; [[[CCDirector sharedDirector]openGLView]addSubview:textView]; the orientation is [[CCDirector sharedDirector] setDeviceOrientation:CCDeviceOrientationLandscapeLeft]; I need the text to appear in landscape mode, but I am getting the text in following way. How can I make the text to appear in the landScape mode. I am working in cocos2d. CanOI scroll the text ? What should i add to make the text scroll up and down. Thank you.

    Read the article

  • .NET on Windows to Mono on Ubuntu

    - by Srikanth
    I am looking at a possibility to change my ASP.NET 2.0 application to the Mono framework. I have used the Mono Migration Analyzer tool and it does detect some P/Invoke and interop dependencies. For example: 1) We use Excel interops and on Linux we are looking to use StarOffice/OpenOffice instead. Is there an easy way of substituting Excel with StarOffice? (I know it sounds bizarre, but I just don't want to miss out in case anyone has done it already.) 2) LDAP authentication: What could be the best alternative in Ubuntu (or an other flavour of Linux)? 3) Is there an Ajax framework for Mono? Preferably with similar controls as Atlas? I hope I am not too ambitious here..

    Read the article

  • When we should use NSThreads in a cocoa Touch ?

    - by srikanth rongali
    I am writing a small game by using cocos2d. It is a shooting game. Player on one side and enemy on other side. To run the both actions of player shooting and enemy shooting do we should use threads ? Or can we do without using them. At present I am not using threads. But I can manage to do both actions of player and enemy at same time. Should I use threads compulsory good performance ? Or am I doing wrong without using threads ? Please help me from this confusion. Thank you.

    Read the article

  • How to use the variable declared in one class in another class in Obj C.

    - by srikanth rongali
    I have a NSDate *date1 in class1 implementation file(I initialized it as Global variable). I have NSDate *date2 in class 2 implementation file (initialized it as Global variable). I need to calculate the NSTimeInterval between the two dates in class 2. But I could not do it. I could not access date1 in this class. It is giving error as (date2 undeclared). Please give me help in how to call other class variables in this class. Thank you.

    Read the article

  • How can we make the text to appear in landscape mode in cocos2d by using UITextView ?

    - by srikanth rongali
    I want a UITextView in cocos2d. I used in init method UITextView *textView = [[UITextView alloc] initWithFrame:CGRectMake(0,0, windowSize.height/2,windowSize.width/2)]; textView.backgroundColor = [UIColor clearColor]; textView.text = @"I am First enemy"; [textView setEditable:NO]; [[[CCDirector sharedDirector]openGLView]addSubview:textView]; the orientation is [[CCDirector sharedDirector] setDeviceOrientation:CCDeviceOrientationLandscapeLeft]; I need the text to appear in landscape mode, but I am getting the text in following way. How can I make the text to appear in the landScape mode. I am working in cocos2d. CanOI scroll the text ? What should i add to make the text scroll up and down. Thank you.

    Read the article

< Previous Page | 1 2 3 4 5 6 7  | Next Page >