Search Results

Search found 30080 results on 1204 pages for 'iframe app'.

Page 130/1204 | < Previous Page | 126 127 128 129 130 131 132 133 134 135 136 137  | Next Page >

  • Printing Stdout In Command Line App Without Overwriting Pending User Input

    - by Chris S
    In a basic Unix-shell app, how would you print to stdout without disturbing any pending user input. e.g. Below is a simple Python app that echos user input. A thread running in the background prints a counter every 1 second. import threading, time class MyThread( threading.Thread ): running = False def run(self): self.running = True i = 0 while self.running: i += 1 time.sleep(1) print i t = MyThread() t.daemon = True t.start() try: while 1: inp = raw_input('command> ') print inp finally: t.running = False Note how the thread mangles the displayed user input as they type it (e.g. hell1o wo2rld3). How would you work around that, so that the shell writes a new line while preserving the line the user's currently typing on?

    Read the article

  • Error Domain=SKErrorDomain Code=3 UserInfo=0x2a5a00 "Cannot connect to iTunes Store"

    - by SKk
    I am trying to implement InApp purchase in my application. I have implemented it as per Apple's programming guide and it(code) was working fine until I created new application, appid, provisioning profile and in-app products @ another developer account. Now, it gives me following error. Error Domain=SKErrorDomain Code=3 UserInfo=0x2a5a00 "Cannot connect to iTunes Store" Same code works fine if I use previous developer account's appid, pro-certificate and product ids. This is very strange issue, I double checked product id names and other things still facing same error. Any clue..?

    Read the article

  • osx run app on every file in folder

    - by Charles
    I want to use jsmin to minify every js file in a directory, and js files in subfolders as well. I would want to use the compiled vers of jsmin found here: http://www.ejeliot.com/blog/73 What is the osx equivalent of a batch file? Looking for something like this for OSX: http://superuser.com/questions/116417/run-a-batch-command-for-every-file-in-a-directory Thanks.

    Read the article

  • Problem in In-App purchase-consumable model

    - by kunal-dutta
    I have created a nonconsumable in app purchase item and now I want to create a consumable in-app purchase by which a user to buy it every time he uses it,and also I want to create a subscription model In-App purchase. Everything works as expected except when I buy the item more than one time, iPhone pop ups a message saying "You've already purchased the item. Do You want to buy it again?". Is It possible to disable this dialog and proceed to the actual purchase?And what will have to change in following code with different model:- in InApp purchase manager.m: @implementation InAppPurchaseManager //@synthesize purchasableObjects; //@synthesize storeObserver; @synthesize proUpgradeProduct; @synthesize productsRequest; //BOOL featureAPurchased; //BOOL featureBPurchased; //static InAppPurchaseManager* _sharedStoreManager; // self (void)dealloc { //[_sharedStoreManager release]; //[storeObserver release]; [super dealloc]; } (void)requestProUpgradeProductData { NSSet *productIdentifiers = [NSSet setWithObject:@"com.vigyaapan.iWorkOut1" ]; productsRequest = [[SKProductsRequest alloc] initWithProductIdentifiers:productIdentifiers]; productsRequest.delegate = self; [productsRequest start]; // we will release the request object in the delegate callback } pragma mark - pragma mark SKProductsRequestDelegate methods (void)productsRequest:(SKProductsRequest *)request didReceiveResponse:(SKProductsResponse *)response { //NSArray *products = response.products; //proUpgradeProduct = [products count] == 1 ? [[products firstObject] retain]: nil; if (proUpgradeProduct) { NSLog(@"Product title: %@", proUpgradeProduct.localizedTitle); NSLog(@"Product description: %@", proUpgradeProduct.localizedDescription); NSLog(@"Product price: %@", proUpgradeProduct.price); NSLog(@"Product id:%@", proUpgradeProduct.productIdentifier); } /*for (NSString invalidProductId in response.invalidProductIdentifiers) { NSLog(@"Invalid product id: %@" , invalidProductId); }/ //finally release the reqest we alloc/init’ed in requestProUpgradeProductData [productsRequest release]; [[NSNotificationCenter defaultCenter] postNotificationName:kInAppPurchaseManagerProductsFetchedNotification object:self userInfo:nil]; } pragma - pragma Public methods /* call this method once on startup*/ (void)loadStore { /* restarts any purchases if they were interrupted last time the app was open*/ [[SKPaymentQueue defaultQueue] addTransactionObserver:self]; /* get the product description (defined in early sections)*/ [self requestProUpgradeProductData]; } /* call this before making a purchase*/ (BOOL)canMakePurchases { return [SKPaymentQueue canMakePayments]; } /* kick off the upgrade transaction*/ (void)purchaseProUpgrade { SKPayment *payment = [SKPayment paymentWithProductIdentifier:@"9820091347"]; [[SKPaymentQueue defaultQueue] addPayment:payment]; } pragma - pragma Purchase helpers /* saves a record of the transaction by storing the receipt to disk*/ (void)recordTransaction:(SKPaymentTransaction )transaction { if ([transaction.payment.productIdentifier isEqualToString:kInAppPurchaseProUpgradeProductId]) { / save the transaction receipt to disk*/ [[NSUserDefaults standardUserDefaults] setValue:transaction.transactionReceipt forKey:@"proUpgradeTransactionReceipt" ]; [[NSUserDefaults standardUserDefaults] synchronize]; } } /* enable pro features*/ (void)provideContent:(NSString )productId { if ([productId isEqualToString:kInAppPurchaseProUpgradeProductId]) { / enable the pro features*/ [[NSUserDefaults standardUserDefaults] setBool:YES forKey:@"isProUpgradePurchased" ]; [[NSUserDefaults standardUserDefaults] synchronize]; } } (void)finishTransaction:(SKPaymentTransaction )transaction wasSuccessful:(BOOL)wasSuccessful { // / remove the transaction from the payment queue.*/ [[SKPaymentQueue defaultQueue] finishTransaction:transaction]; NSDictionary *userInfo = [NSDictionary dictionaryWithObjectsAndKeys:transaction, @"transaction" , nil]; if (wasSuccessful) { /* send out a notification that we’ve finished the transaction*/ [[NSNotificationCenter defaultCenter]postNotificationName:kInAppPurchaseManagerTransactionSucceededNotification object:self userInfo:userInfo]; } else { /* send out a notification for the failed transaction*/ [[NSNotificationCenter defaultCenter] postNotificationName:kInAppPurchaseManagerTransactionFailedNotification object:self userInfo:userInfo]; } } (void)completeTransaction:(SKPaymentTransaction *)transaction { [self recordTransaction:transaction]; [self provideContent:transaction.payment.productIdentifier]; [self finishTransaction:transaction wasSuccessful:YES]; } (void)restoreTransaction:(SKPaymentTransaction *)transaction { [self recordTransaction:transaction.originalTransaction]; [self provideContent:transaction.originalTransaction.payment.productIdentifier]; [self finishTransaction:transaction wasSuccessful:YES]; } (void)failedTransaction:(SKPaymentTransaction )transaction { if (transaction.error.code != SKErrorPaymentCancelled) { / error!/ [self finishTransaction:transaction wasSuccessful:NO]; } else { / this is fine, the user just cancelled, so don’t notify*/ [[SKPaymentQueue defaultQueue] finishTransaction:transaction]; } } (void)paymentQueue:(SKPaymentQueue *)queue updatedTransactions:(NSArray *)transactions { for (SKPaymentTransaction *transaction in transactions) { switch (transaction.transactionState) { case SKPaymentTransactionStatePurchased: [self completeTransaction:transaction]; break; case SKPaymentTransactionStateFailed: [self failedTransaction:transaction]; break; case SKPaymentTransactionStateRestored: [self restoreTransaction:transaction]; break; default: break; } } } @end in SKProduct.m:- @implementation SKProduct (LocalizedPrice) - (NSString *)localizedPrice { NSNumberFormatter *numberFormatter = [[NSNumberFormatter alloc] init]; [numberFormatter setFormatterBehavior:NSNumberFormatterBehavior10_4]; [numberFormatter setNumberStyle:NSNumberFormatterCurrencyStyle]; [numberFormatter setLocale:self.priceLocale]; NSString *formattedString = [numberFormatter stringFromNumber:self.price]; [numberFormatter release]; return formattedString; }

    Read the article

  • iPhone apps causing battery to drain out

    - by saurabh
    Hi, Recently my iPhone battery started to discharge in just one day. I do not use my iPhone much (less than 1 hour a day). and then while discussing it with couple of colleagues, I heard that there are some apps which even if installed on your iPhone can cause your battery to drain out faster. It does not matter if you are not using those apps, only having them installed was enough to cause battery drain. I have heard this from couple of my techie friends as well and thus had to put some credibility to it. Being an iPhone developer, I don't think that is possible. Do you think if this is possible for an app to cause battery drain just by being installed there on iPhone?

    Read the article

  • App.config for SpecFlow not recognized

    - by INTPnerd
    How do I get my App.config file to be recognized/used? I have tried placing it in the top folder of my project and in the same folder as my feature files. Here are the contents of my App.config file: <?xml version="1.0" encoding="utf-8" ?> <configuration> <configSections> <section name="specFlow" type="TechTalk.SpecFlow.Configuration.ConfigurationSectionHandler, TechTalk.SpecFlow"/> </configSections> <specFlow> <runtime detectAmbiguousMatches="true" stopAtFirstError="false" missingOrPendingStepsOutcome="Error" /> </specFlow> </configuration> Specifically I am trying to tell NUnit to have a fail result when there is a missing or pending step which is why I am specifying "Error" for this.

    Read the article

  • android.app.Application subclass, onTerminate is not being called

    - by synic
    From the documentation for android.app.Application: "Base class for those who need to maintain global application state" I am using my own subclass to maintain an object that I'm using to query a server. Also from the documentation: "onTerminate() Called when the application is stopping." However, onTerminate() in my class is never called. I press the back button while viewing my main activity, and everything seems to shut down. My main Activity's onDestroy() method is called and isFinishing() returns true, but my android.app.Application's onTerminate() method is never called. Why is this? What am I missing? Is there something that is keeping it open?

    Read the article

  • Custom UISwitch & App Store approval

    - by pix0r
    After doing some reading, I've found that you can customize the text and color on a UISwitch control. I'm curious if these methods will cause problems trying to get my app approved and included in the App Store. Sample code taken from iPhone Developer's Cookbook Sample Code: // Custom font, color switchView = [[UICustomSwitch alloc] initWithFrame:CGRectZero]; [switchView setCenter:CGPointMake(160.0f,260.0f)]; [switchView setLeftLabelText: @"Foo"]; [switchView setRightLabelText: @"Bar"]; [[switchView rightLabel] setFont:[UIFont fontWithName:@"Georgia" size:16.0f]]; [[switchView leftLabel] setFont:[UIFont fontWithName:@"Georgia" size:16.0f]]; [[switchView leftLabel] setTextColor:[UIColor yellowColor]];

    Read the article

  • UIImagePickerController Causes my app to crash!

    - by Flafla2
    In my app, a user can select an image, change the picture of a UIImageView to the new imge, and save the image to NSUserDefaults using NSKeyedArchiver. When the user selects the image the app immediately crashes! Here is my code - - (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info { [picker dismissModalViewControllerAnimated:YES]; if ([[NSUserDefaults standardUserDefaults] integerForKey:@"PictureKey"] == 1) { UIImage *previmage = [info objectForKey:@"UIImagePickerControllerOriginalImage"]; [prevbutton setImage:previmage]; NSData *previmagedata = [NSKeyedArchiver archivedDataWithRootObject:previmage]; [[NSUserDefaults standardUserDefaults] setObject:previmagedata forKey:@"PrevImage"]; } else if ([[NSUserDefaults standardUserDefaults] integerForKey:@"PictureKey"] == 2) { UIImage *nextimage = [info objectForKey:@"UIImagePickerControllerOriginalImage"]; [nextbutton setImage:nextimage]; NSData *nextimagedata = [NSKeyedArchiver archivedDataWithRootObject:nextimage]; [[NSUserDefaults standardUserDefaults] setObject:nextimagedata forKey:@"NextImage"]; }else { UIImage *optionsimage = [info objectForKey:@"UIImagePickerControllerOriginalImage"]; [moreoptionsbutton setImage:optionsimage]; NSData *optimagedata = [NSKeyedArchiver archivedDataWithRootObject:optionsimage]; [[NSUserDefaults standardUserDefaults] setObject:optimagedata forKey:@"OptionsImage"]; } } Thanks in advance!

    Read the article

  • iPhone Settings app and keyboard control?

    - by randallmeadows
    So I'm putting my app's preference settings into the Settings app. One of the settings is an edit text field (PSTextFieldSpecifier). When touched, the keyboard dutifully appears, I can make the edits, but when I press Return....nothing. Well, the editing is completed, but the keyboard remains. I see no way to make the keyboard go away. I also notice this same behavior in other Settings panes, including those from Apple. Do I assume correctly that this is just standard behavior and I need to just accept the fact that my Settings table has now been reduced to half size, and just deal? Furthermore, I gather there is no approved way to have a "rich" child pane display, such as that seen in Settings-General-About-Legal? Or a way to do what appears to be a -presentModalViewController, a la Settings-General-Passcode Lock?

    Read the article

  • "Symbol not found" error for UIPopoverController in an iPhone/iPad Universal App

    - by alexbw
    In a universal binary iPhone/iPad app of mine, users are able to adjust preferences in a view controller that's presented modally. On the iPhone, the settings panel is presented with presentModalViewController:animated:, and on the iPad, I use a UIPopoverController. I'm having a heck of a time completely isolating the UIPopoverController code away from the iPhone code. Everytime I compile for the iPhone, I get the following error: dyld: Symbol not found: _OBJC_CLASS_$_UIPopoverController Referenced from: /var/mobile/Applications/CBB37F87-AA6D-47E2-823A-E259E3268A32/MyApp debug.app/MyApp Expected in: /System/Library/Frameworks/UIKit.framework/UIKit This is of course because UIKit on the iPhone doesn't have a UIPopoverController class. Does anybody have advice for how to effectively isolate the iPad API includes from the iPhone code, so I can actually run my code?

    Read the article

  • Python decoding issue with hashlib.digest() method

    - by Sorw
    Hello StackOverflow community, Using Google App Engine, I wrote a keyToSha256() method within a model class (extending db.Model) : class Car(db.Model): def keyToSha256(self): keyhash = hashlib.sha256(str(self.key())).digest() return keyhash When displaying the output (ultimately within a Django template), I get garbled text, for example : ?????_??!`?I?!?;?QeqN??Al?'2 I was expecting something more in line with this : 9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08 Am I missing something important ? Despite reading several guides on ASCII, Unicode, utf-8 and the like, I think I'm still far from mastering the secrets of string encoding/decoding. After browsing StackOverflow and searching for insights via Google, I figured out I should ask the question here. Any idea ? Thanks !

    Read the article

  • Server cost for smartphone app with web service

    - by FrankieA
    Hello, I am working on a smartphone application that will require a backend web service - but I have absolutely clueless to how much it will cost. Web Service will handle: - login of users - cataloging of our user base - holding minimal profile information for users (the only binary data is a display picture which will be < 20k each) - performing some very minor calculation/algorithm before return results - All the above will be communicated to server from a smartphone (iPhone/BlackBerry/Android) Bandwidth Requirements: - We want to handle up to 10k users throughout the day. - I predict 10k * 50 HTTP requests a day = 500,000 requests a day * 30 = 15 million requests a month Space Requirements: - Data will be in SQL database. - I predict 1MB/user * 10k = 10GB + overhead. In other words - space is not a big issue. Software Requirements: (unless someone knows an alternative) - Windows Server 2008 + IIS - MSFT SQL Server Note: This is 100% new to me, so please hit me with all you got. Do I need Windows Server or are there alternative? Is it better to get multiple cheap servers to distribute load? Will Amazon S3 work for me? How about Windows Azure? Thank you!!

    Read the article

  • jpa IllegalArgumentException exception

    - by Bunny Rabbit
    i've three entity classes in my project public class Blobx { @ManyToOne private Userx user; @Id @GeneratedValue(strategy = GenerationType.IDENTITY) private Key id; } public class Index { @Id private String keyword; @OneToMany(cascade = CascadeType.PERSIST) private List<Blobx> blobs; } public class Userx { @Id private String name; @OneToMany(mappedBy = "user") private List<Blobx>blobs; } while running the following lines app engine throws an exception em.getTransaction().begin(); em.persist(index); em.getTransaction().commit();//exception is thrown em.close(); as Caused by: java.lang.IllegalArgumentException: can't operate on multiple entity groups in a single transaction. found both Element { type: "Index" name: "function" } and Element { type: "Userx" name: "18580476422013912411" } i can't understand what's wrong?

    Read the article

  • tabIndex fails in an AS3 swf loaded into a flex app

    - by quoo
    I feel like I'm missing something really simple here. I'm loading a AS3 swf containing a form (created by one of our designers) into a flex app. The swf's tabIndex properties work fine when the swf is viewed by itself, however, once it's loaded into the flex app: <mx:SWFLoader source="form.swf" top="20" horizontalCenter="0" id="formSwf" complete="swfCompleteHandler(event)"/> the form fields stop receiving focus on tab. I've been looking at the FocusManager in flex, for some sort of solution, but I can't seem to find any examples, and I'm not entirely sure I'm looking in the right place. Am I stuck redoing this form in flex?

    Read the article

  • Loading an external SWF App in a new Air window with resize functionality

    - by t.stamm
    Hello everyone, i'm trying to load a local SWF Application in my Air Application via the SWFLoader class. The SWFLoader class is displayed in a new Window. Therefore, i'm trying to resize the window automatically, when the Flash Application is resizing. But here's the problem. The SWFLoader does not get any events when the loader App has been resized. The Problem seems to be the Sandbox Restrictions. I'm able to call methods in the childSandboxBridge and parentSandboxBridge Objects that i've set in the LoaderInfo of the SWFLoaders content (the loaded SWF Application). But i cannot listen to any ResizeEvents or something like that when i'm resizing the loaded App. I'm aware of the workaround with the Loader Class and the codeExecution Property, but i don't want to bypass the Air Sandbox - if possible. Can anyone help me with this? Thanks in advance

    Read the article

  • Improving terminal server performance for a specfic app

    - by Matt
    We have a windows 2003 terminal server running 2X application load balancign that is hosting a client's application that is accessed by around 50 users. Each user has there own database. The database is a file based database. The application is developed under Delphi so I think the database may be BDE based. As you can imagine, there is probably quite a lot of disk i/o. Here are some of the perfmon settings. Logged in users (average) 20 - 25 CPU Utilization (average) 80 - 100% Disk Queue Length (average) 1.6 % Disk time (average) 111 Page faults/sec (average) 1400 The application takes on average about a minute to load up. As usual, the budget is tight. Is there basic windows performance tuning tips that people can recommend to improve things before we fork out on more RAM etc. Server is a 2.8GHz Xeon with 3GB of RAM.

    Read the article

  • Microphone audio streaming from Cocoa mac app to iPhone

    - by Benzamin
    Hi devs, I'm trying to build a microphone audio streamer to iPhone. The server software will be a mac desktop app and the client will be iPhone, and they are connected via tcp port. I've successfully connected the mac app and iPhone, and tried to send a fixed test.m4a audio file first. But at the iPhone i grabbed the data well, when tried to play it i used AVAudioPlayer and its returning OSStatus error. I played around with the audio queue service but its very tricky and i only got some example for fixed length audio playing like http://cocoawithlove.com/2009/06/revisiting-old-post-streaming-and.html Now i need help on two things, how can i continuously grab audio data from Mac desktop microphone? And then after grabbing the data how i can play this unfixed length audio data in the iPhone. What exactly i need to do? Please please help me on this......

    Read the article

  • Does business logic belong in the service layer?

    - by antony.trupe
    I've got a set of classes, namely, a data transfer object, a service implementation object, and a data access object. I currently have business logic in the service implementation object; it uses the dao to get data to populate the dto that is shipped back to the client/gui code. The issue is that I can't create a lightweight junit test of the service implementtion object(it's a servlet); I think the business logic should be elsewhere, but the only thing I can think of is putting business logic in the dao or in yet another layer that goes between the dao and the service implementation. Are there other options, or am I thinking about this the wrong way? It's a GWT/App Engine project.

    Read the article

  • Windows and Linux applications to show cumulative uploads/downloads for each app, at a glance

    - by jontyc
    I've read few quite a few other threads on SU, but they have been focused on instantaneous/average bandwidths (B/sec) rather than cumulative download/upload totals for a period. Either that or they don't drill down to application level. Resource Monitor in Windows 7 only shows bandwidth. I've just been trying NetLimiter and whereas it can show total uploaded/downloaded, it's a case of having one stats window open per application, as opposed to a table showing all applications at once. Looking for applications for both Windows and Linux (Ubuntu), but they don't need to be the same.

    Read the article

  • Tutorials for .NET database app using SQLite

    - by ChrisC
    I have some MS Access experience, and had a class on console c++ apps, now I am trying to develop my first program. It's a little C# db app. I have the db tables and columns planned and keyed into VS, but that's where I'm stuck. I'm needing C#/VS tutorials that will guide me on configuring relationships, datatyping, etc, on the db so I can get it ready for testing of the schema. The only tutorials I've been able to find either talk about general db basics (ie, not helping me with VS/C#), or about C# communications with an existing SQL db. Thank you. (In case it matters, I'm using the open source System.Data.SQLite (sqlite.phxsoftware.com) for the db. I chose it over SQL Server CE after seeing a comparison between the two. Also I wanted a server-less version of SQL because this little app will be on other people's computers and I want to to do as little support as possible.)

    Read the article

  • Handling Junk Email with Apple Mail.app and Gmail

    - by Axeva
    I've just setup my Apple Mail client to work with Google Apps through IMAP. One lingering question is how to best handle SPAM (Junk Mail), however. In their Help section, Google recommends that we disable junk filtering on the client. http://mail.google.com/support/bin/answer.py?answer=78892 This leads me to wonder what we should do when a junk message makes it past Google's filter? Do I just delete the message? If I do, the Google spam filter will never improve and "learn" that the message was junk. Do I have to log in to the web interface at Google to mark the message as spam? That seems a bit arduous for every spam email I get. What's the best way to handle this? Thanks!

    Read the article

< Previous Page | 126 127 128 129 130 131 132 133 134 135 136 137  | Next Page >