w3hello.com logo
Home PHP C# C++ Android Java Javascript Python IOS SQL HTML videos Categories
Can you set a Max iOS version for an iPhone App?
I think if you do this you will get bad reviews anyway, but it may be your only option if you can't revise in time. You need to take a look at this SO answer and use a condition with a macro like if(SYSTEM_VERSION_LESS_THAN_OR_EQUAL_TO(@"6.1.3")) { // work normally } else { // fail gracefully } to disable any part of your app that is broken post that version number. I don't think there is a way to restrict users with later versions installing and trying to use your app as there is with users with versions earlier than you require. The reason is probably that while it's OK to use new features and lock out older devices it generally isn't OK to not support new devices indefinitely.

Categories : Iphone

Changes coming in Version 1.1 of the Twitter API in iPhone
Visit https://dev.twitter.com/docs/ios/making-api-requests-slrequest https://dev.twitter.com/docs/oauth/xauth u can get the authentication using following method: NSString *base64 = @"Basic NFRLWGlZY3l1aHJ4OVJaUWI5RW5BOmdVMXlvcVV6YzBNZUhUQmFXdVRZU2NtZHlIWDFOZXhwZmxqRE16bm01aw=="; //oauth_consumer_secret,oauth_consumer_key NSURL *urlAPI = [NSURL URLWithString:[NSString stringWithFormat:@"https://api.twitter.com/oauth2/token"]]; ASIFormDataRequest *request = [ASIFormDataRequest requestWithURL:urlAPI]; [request setDelegate:self]; [request setRequestMethod:@"POST"]; [request addRequestHeader:@"Authorization" value:base64]; [request addRequestHeader:@"Content-Type" value:@"application/x-www-form-urlencoded;charset=UTF-8"]; [request setPostValue:@"client_credentials" forKey:@"gran

Categories : Iphone

iPhone / iPad IOS How To Get Framework Bundle Version
NSArray *ar = [NSBundle allFrameworks]; for (NSBundle *b in ar) { NSLog(@"%@",[b objectForInfoDictionaryKey:@"CFBundleName"]); NSLog(@"%@",[b objectForInfoDictionaryKey:@"CFBundleShortVersionString"]); }

Categories : IOS

Append Application(Andriod/Iphone/Windows) version in HTTP Request?
Here is an example for an android client. First you need to get the version from your app. Here is an exemple with the version name (you can also recover the version code if needed). String vName = null; try{ vName = getPackageManager().getPackageInfo(getPackageName(),0).versionName; } catch(NameNotFoundException e){ } Then just add your version to http header when you request your server from the client app. HttpClient httpclient = new DefaultHttpClient(); HttpPost httppost = new HttpPost("https://myserver.com/postrequest"); if(vName != null){ httppost.addHeader("ClientAppVersion", vName); } ...

Categories : Android

Three Images Aren't fully displayed on iPhone ( using meta viewport ) , not a custom version
Add this in your body css: min-width:1024px and make sure your viewport is: <meta name="viewport" content="width=device-width" />

Categories : HTML

iPhone 4 app displays as support for iPhone 5 not for iPhone 4
There is a strong reasons of it , let us understand it :- In Build setting of a iOS Project , there is a option of Target Devices. Where we have to set minimum supported device of iOS. That means if you want it to support for iPhone 4S (iOS 5) then you have to select Deployment Target as 5.0. Which means that your app can support iOS 5 and above. Hope this information helps you.

Categories : IOS

Is a library ,created in .net version 4.0, access with in the lower version from its version
Create a library in .Net 2.0 Framework so there will be no issue with higher versions, you can set the version from project properties (right click the project and select properties in visual studio) Select Application tab from properties window and select Target Framework combobox select .Net Framework 2.0

Categories : C#

receiving memory warning issue in iphone when taking picture from iphone camera
What you can do is you can decrease the size of the photo.Because the photo you are taking has high resolution and big in size so first you scale down the size like below. - (void)imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info { CGSize sizeCropped = CGSizeMake(602, 450);//you can give any size UIImage *theimage = nil; theimage = [yourclassname imageWithImage:image scaledToSize:sizeCropped]; //you can do here whatever you want with theImage [imgPicker dismissViewControllerAnimated:YES completion:nil]; } + (UIImage*)imageWithImage:(UIImage*)image scaledToSize:(CGSize)newSize; { UIGraphicsBeginImageContext( newSize ); [image drawInRect:CGRectMake(0,0,newSize.width,newSize.height)]; UIImage* newImage = UIG

Categories : Iphone

iOS Tabbed Application switches back to iPhone 4 resolution on iPhone 5 when switching tabs
jettplaine.. 1.First add the add the iPhone Retina(4-inch) and Retina(3.5-inch) images as a launch images.. Add a splash image named Default-568h@2x.png. That will identify your app as one that supports iPhone 5 metrics

Categories : Iphone

Web page (made with twitter bootstrap) zoomed in on iphone, how to force it to fit iPhone screen?
I am amazed that you said that in POINT 1, you solved your proble by using min-width Instead of min-width you should write max-width as you want to restrict it to a certain width.

Categories : HTML

CSS3 Media Queries for targeting landscape on both iphone 4 and iPhone 5 sized sceens
Yeah, you can target landscape on both using: // Iphone 5 @media screen and (orientation:landscape) { .test { width: 50% } } // Iphone 4 and below, from @Danield's example @media only screen and (min-device-width : 320px) and (max-device-width : 480px) and (orientation : landscape) { .test { width: 30% } } Where the first is for iPhone 5, and the second is for iPhone 4 and below. Although, I think the second one should work for both in itself. But I can't confirm it since I don't own a 5. http://www.w3.org/TR/css3-mediaqueries/#orientation

Categories : HTML

I purchased iOS developer license for iPhone and I am not able to add Profile to my iPhone 5. Request Timed Out
Server is down, but: Create profile in portal Download profile from portal open Xcode switch to device organizer click profiles (not sure about the name though) import profile Done.

Categories : Iphone

Calculate the distance between the iPhone and an object, knowing their physical widths (of the iPhone as well)
I assume you mean that there is some outside image capturing device (be it a human eye or another camera) and the image capturing device, the phone, and the door are all in a line such that the phone appears to be the same width as the door. In this case, you still need a) the distance between the image capturing device and the phone and b) the optical information (such as focal length) of the image capturing device. Just sit down with a pen and paper and draw out the geometry for a little bit and you'll see that.

Categories : Iphone

System Sound plays in iPhone simulator but on iphone not playing
Here's a small detail that many developers have wasted hours upon: Case Sensitivity Really, it all boils down to: iPhone Simulator: Case-Insensitive iOS device: Case-Sensitive So, you might have 'waterfall' in your code, but the actual sound name is 'Waterfall'. It might even be something like 'wAtErFaLl'. This will work fine on the simulator, but not on the device - the device simply won't find the sound. This has happened to me for everything from sounds to images to plists. Check your Cases! Also, AudioServices has some guidelines on what can play in the device and what can't: Sound files that you play using this function must be: - No longer than 30 seconds in duration - In linear PCM or IMA4 (IMA/ADPCM) format - Packaged in a .caf, .aif, or .wav file

Categories : Iphone

How to embed the Google Maps iPhone app within my own native iphone application?
For iOS 6.1.1 and lower, use the openURL method of UIApplication. It will perform the normal iPhone magical URL reinterpretation. so [someUIApplication openURL:[NSURL URLWithString:@"http://maps.google.com/maps?q=London"]] should invoke the Google maps app. From iOS 6, you'll be invoking Apple's own Maps app. For this, configure an MKMapItem object with the location you want to display, and then send it the openInMapsWithLaunchOptions message. To start at the current location, try: [[MKMapItem mapItemForCurrentLocation] openInMapsWithLaunchOptions:nil]; You'll need to be linked against MapKit for this (and it will prompt for location access, I believe). You can also use UIApplication *app = [UIApplication sharedApplication]; [app openURL:[NSURL URLWithString: @"http://maps.google

Categories : Iphone

How to Send and Receive Live audio from one iPhone mic to the another iPhone speaker?
To use the NSData just use the NSData writeToFile:atomically: method. Pass in the NSTemporary() path and append a path component like "temp.mp4". At that point you have a filePath with valid data that you can use to load the audio asset. AVAudioPlayer can support loading from a URL. OR with iOS 7.0+ You can initialize the AVAudioPlayer directly with the NSData object. init(data data: NSData, fileTypeHint utiString: String?) throws et. al...

Categories : Iphone

How to get my iPhone app listed in iPhone's native Photos app share menu?
Apple has made a special exception for Facebook and Twitter because of their integration with iOS. Any other apps cannot do that. UPDATE: Share extensions were introduced in iOS 8, which allow developers to add their apps to the list of sharing options in the system menu.

Categories : Iphone

How to position a container view so it's the same distance from top of screen on iPhone 4 & iPhone 5?
If you're using layout constraints, just give the container view a fixed constraint to the top and bottom of the main view, and no fixed height. This will cause the view to expand and contract depending on the screen size. Depending where your scroll view is, one of the constraints might have to be to it, rather than the top or bottom of the screen (So, if the scroll view were on top, it would have a constraint to the top, a fixed height, and a spacing constraint to the container view below it. The container view would then just need one to the bottom of the superview).

Categories : IOS

Reading from file works in iPhone 6.1 Simulator, but not in iPhone device (iOS 6.1.3)
Try to diagnose whether the file exists when you try to read from it. You can do this with NSFileManager. Also check whether the file has the right size (or at least a non-zero size). Also, have you checked whether stringWithContentsOfFile actually returns a string? If an error occurs it will return nil and not raise an exception. If you get nil you can pass an NSError object to stringWithContentsOfFile and it will let you know what went wrong.

Categories : IOS

iphone - uitableview cell did not update on iPhone but on iPad yes
OK, I got it... You must have declared that UItableview in header file for use [tableView reload] outside configure part of UITableView... So easy - I have declared tableView as table and than, I call [table reloadData] :-)

Categories : IOS

Sending Message iPhone to Any iPhone over Wi-fi ( Data) across world
From my little Knowledge, You can't do it through WiFi. When a screen lock happened, device will automatically OFF the wifi connection for increasing battery life.Thats why socket connection getting disconnected. In iOS, apps can’t do a lot in the background. Apps are only allowed to do limited set of activities so battery life is conserved. But what if something interesting happens and you wish to let the user know about this, even if they’re not currently using your app. For example, maybe the user received a new chat. Since the app isn’t currently running, it cannot check for these events. Luckily, Apple has provided a solution to this. Instead of your app continuously checking for events or doing work in the background, you can write a server-side component to do this instea

Categories : Iphone

Is there any difference between iPhone 4 and iPhone 5 when I use media queries?
According to this site, the difference is with the max-device-width: In iphone4 it's 480px In iphone5 it's 568px iphone4 @media only screen and (min-device-width : 320px) and (max-device-width : 480px) { /* STYLES GO HERE */} iphone5: @media only screen and (min-device-width : 320px) and (max-device-width : 568px) { /* STYLES GO HERE */ } ...and both have Device-pixel-ratio: 2 so iphone4 has screen height= 960px (Actual Pixels) and iphone5 has screen height= 1136px (Actual Pixels)

Categories : CSS

Best Route to Stream Music from iPhone to iPhone
To capture and play the streamed audio you can use Audio File Stream Services To stream the audio data to another Iphone, you want to take a look at the new Multipeer Connectivity framework in ios7. It allows you to stream data to nearby peers through a multipeer connectivity session.

Categories : Iphone

UIWebView and Top Bar Iphone 5 Iphone 4 Scaling issue
I think the answer lies with auto layout. That seems like something really easy to do with it. Are you limited to a version of iOS that doesn't support auto layout? If not, here's how to do it: Using this method, no matter what size of screen you have, you'll always have a 44 pixel margin at the top.

Categories : IOS

Make UIView move down if iPhone is iPhone 5
Add The following line of code: #define IS_IPHONE_5 ( fabs( ( double )[ [ UIScreen mainScreen ] bounds ].size.height - ( double )568 ) < DBL_EPSILON ) At yourProjectName-perfix.pch file This is useful for recognize that device is iPhone4 or iPhone5. by give condition such like if (IS_IPHONE_5) { //// write code/setFrame for iPhone5; } eles { //// write code/setFrame for iPhone4; } Use it anyWhere in your project:

Categories : Iphone

How do i make an app running on iphone 5 fit the screen of iphone 4 and 3
If your application is thought for iPhone 5, it will be complicated due to the smaller screen size, but here is what you have to do : All your images are supposed to be in two sizes, classic and @2x. The classic size will be used for iPhone 3GS. If you are already using autolayout you're ready, cross your finger and let's go. If not, you should think about using autolayout, read some tutorial about it, but simply it allows you to design a single interface for all your screen sizes. If you don't want to use autolayout (or if you can't), you should place all your elements directly in your code to be sure they aren't "out" the screen.

Categories : Iphone

IOS email works on IOS 6.1.4 (iphone 5) but not on IOS 6.1.3 (iphone 4)
Try this apple doc for complete accurate implementation of email also check your deployement target set while creating build MFMailComposeViewController *picker = [[MFMailComposeViewController alloc] init]; picker.mailComposeDelegate = self;

Categories : Iphone

Inconsistent xib behaviour between iPhone 4 and iPhone 5
You are loading iPhone 5 nib both the time. take a isIpad global flag set it depending upon the device then use this init method in your view controller - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil { NSString *nibName=nil; nibName=isiPad?@"viewController_iPhone5":@"viewController";// isIpad is flag set if device is iPhone5 self = [super initWithNibName:nibName bundle:nibBundleOrNil]; if (self) { // Custom initialization } return self; }

Categories : Iphone

How to distinguish between iPhone 4 and iPhone 4s in javascript
I see these three options for you: 1) use a precooked open source script to check this and based on the result you do a redirect. You can use this for example: http://detectmobilebrowsers.com/ 2) you implement a javascript which do a checking based on the navigator parameters. See this and a quote code from that SO answer. function iOSversion() { if (/iP(hone|od|ad)/.test(navigator.platform)) { var v = (navigator.appVersion).match(/OS (d+)_(d+)_?(d+)?/); return [parseInt(v[1], 10), parseInt(v[2], 10), parseInt(v[3] || 0, 10)]; } } 3.) you can use rewrite rules at Apache side to redirect to the proper page based on user-agent. See this. For all 3 options you have a problem that it is hardly possible to distinguish between iPhone 4 and 4s. See this SO answer. To mention

Categories : Javascript

When we open pdf in iPhone then how to save this pdf in iphone
I hope this it will help you, Saving the pdf into app NSData * imageData = [[NSData alloc] initWithContentsOfURL: [NSURL URLWithString: path]]; NSArray *paths = NSSearchPathForDirectoriesInDomains(NSCachesDirectory, NSUserDomainMask, YES); NSString *filePath = [[paths objectAtIndex:0] stringByAppendingPathComponent:@"pdfname.pdf"]; NSError *writeError = nil; [imageData writeToFile:filePath options:NSDataWritingAtomic error:&writeError]; if (writeError) { NSLog(@"Error writing file: %@", writeError); } Getting the pdf from the NSDocument Directory NSString *stringPath = [NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES)objectAtIndex:0]; NSArray *filePathsArray = [[NSFileManager d

Categories : Iphone

Data txt files work when read in iPhone simulator, but do not work on iPhone device?
Grab the file this way then you can copy it to your doc dir if you wish NSString *filePath = [[NSBundle mainBundle] pathForResource:CURRENTPUZZLENUMBERFILE ofType:@"txt"];

Categories : IOS

Which Linux platfrom required for Installation of ingres database version 9.2 and openROAD version 4.0
If you want answers don't use Stackoverflow as its ridiculous policies prevent me supplying the four links that would have been helpful to you. Google for the Actian community, which you will find far more helpful with fewer egos struggling to rule the world.

Categories : Misc

Calling https version of TYPO3: content (css, js, ..) is blocked because link to http version
I used config { baseURL = https://domain.com } and adapted all links which had a http in the beginning (otherwise the slider stopped working because Chrome didn't load the other ressources ...). Seems to work now.

Categories : Http

VSTO Debug version fine, Installed version doesn't read app.config
You need to add app.Config File to your Setup Project but not from the actual project do it from the ReleaseDebug folder of the ExcelAddIn project. When you build you ExcelAddIn project it will leave App.config File to the ReleaseDebug Folder, piCk the file form there and include it into the dependicies folder of the Setup Project.

Categories : Visual Studio 2010

Debug mode on my RubyMine version 4.0.1 stopped working after upgrade ruby version to 2.0.0
Please update to RubyMine 5.4.2, it will install the correct debug gem version. RubyMine versions before 5.x do not support Ruby 2.0 debugging. 5.x versions install the following gem for Ruby 2.0: ruby-debug-ide (0.4.17) Note that linecache and ruby-debug-base gems are not needed and are not installed by RubyMine 5 when using Ruby 2.0. If ruby-debug-ide gem doesn't install from RubyMine for some reason, please try installing it from the terminal: gem install ruby-debug-ide

Categories : Ubuntu

Detect version of tomcat when WAR file starts (possibly stop it if it is not on the recommended version)
Straight from Tomcat FAQ: How to I get Tomcat's version number? javax.servlet.ServletContext.getServerInfo(); Starting with Tomcat 5.0.28 - there is now a version.sh (or version.bat) program in the bin directory. It will print the version number of Tomcat to Standard output.

Categories : Tomcat

Grails adding version to command object causes id and version from params not to be bound
Seems this is by design per Jeff Brown jira The data binding explicitly avoids binding id or version [if] they both exist and does this by design. This is a shield against potential security problems relevant to data binding as it relates to domain classes. A simple work around for command objects would be to name the properties with something like "idValue" and "versionValue" or anything other than "id" and "version".

Categories : Grails

'dependencies.dependency.version' is missing error, but version is managed in parent
In theory, maven does not allow to use a property to set a parent version. In your case, maven can simply not figure out that the 0.0.1-SNAPSHOT version of your parent pom is the one that is currently in your project, and so it tries to find it in your local repo. It probably finds one since it is a snapshot, but it is an old version that probably not contains your Dependency Management section. There is a workaround though : Simply change the parent section in the child pom with this : <parent> <groupId>com.sw.system4</groupId> <artifactId>system4-parent</artifactId> <version>${system4.version}</version> <relativePath>../pom.xml</relativePath> <!-- this must match your parent pom location --> </parent>

Categories : Java

Attempt to update step execution id=1 with wrong version (2), where current version is 1
I had this same exception. org.springframework.dao.OptimisticLockingFailureException: Attempt to update step execution id=0 with wrong version (2), where current version is 3 In my case, it was caused by a failure the process step, which was being swallowed. Spring Batch activated the writer, even though the processor had failed. Look through your logs to make sure that your process step is completing and returning something.

Categories : Misc

The database cannot be opened because it is version 706. This server supports version 655 and earlier. A downgrade path is not supported
Version 706 is a database file from Sql Server 2012 Version 665 is a database file from Sql Server 2008R2 (post SP1 ?) http://conceptdev.blogspot.com/2009/04/mdf-cannot-be-opened-because-it-is.html

Categories : C#



© Copyright 2017 w3hello.com Publishing Limited. All rights reserved.