Following the previous WPdev quick tip how to initiate Email Compose from your app, here is another API that developer often need:
- Navigate to Rate and Review dialog for the current app – if you want to initiate app rating from the current user
- Navigate to Windows/Phone Store to the currently running app – if you want the user to purchase full version of current app or upgrade to a new version
- Navigate to Windows/Phone Store to all apps published by the current developer – if you want to encourage the user to download other of your apps
Unfortunately all these tasks require different type of API in Windows Phone 7.5/8/8.1 Silverlight apps, in Windows 8.1 apps and another one in Windows Phone 8.1 WinRT apps and since I needed all these methods in my recent Windows Universal App NASA TV Live, I decided to put it all into short article for future use, so here it is:
When developing Windows Phone or Windows Store app it’s often useful to give your user option to send you feedback email or feature request. In this short #WPdev article I’ll cover all three different approaches you could use in all current Windows Store platforms.
Windows Phone 7, 7.5, 8 and 8.1 (Silverlight)
Sending emails from original Windows Phone 7+ Silverlight apps is done using the EmailComposeTask:
string to = "email@example.com";
string subject = "Idea for your app";
string body = "Hi, here's an idea for your cool app...";
EmailComposeTask emailTask = new EmailComposeTask
To = to, Subject = subject, Body = body,
//Cc = , Bcc = , CodePage = ,
When the Show method is called the system dialog appears where you can choose the mail account that will be used for sending the email.
As you can see the usage is really simple, one class and one method is all you need. Note there is no way how to send emails with attachments using this API.
Another problem also is that this API is no longer available when developing Windows 8/8.1 or Windows Phone 8.1 WinRT apps. So what is the alternative?
The Windows Phone 8.1 SDK was released with a bang at the beginning of April 2014 and the OS update arrived later that year. It brought lot of new to the Windows Phone ecosystem, but also caused a noticeable disarray to the Windows Phone community and to the community of developers as well. Some features in WP8.1 are definitely great and improving, some are just worrisome, and some features in WP8.1 SDK are simply missing, even though they were in WP8.
Let’s take a look on the WP8.1 SDK nine months after the original release, what improvements it brought and also what’s still not there.
In this dev article about Windows Phone 8.1 SDK, 9 month later I’ll summarize in few bullet points the most interesting features of this OS update and especially what’s new for developers.
Let’s imagine this typical scenario: You are an indie developer or a company developing apps in Visual Studio. You have already developed and use several own useful libraries across various projects. Right now you are maintaining each of these libraries in separate Git/TFS repository and adding these libraries as submodules to your projects. Because these libraries are hierarchically dependent one on another, it’s quite hard to maintain the dependencies and changes properly. You’ve thought about packaging these libraries as separate NuGet packages, but adding them to public nuget.org gallery is not an option since these libraries contain private knowhow.
In this article I’ll demonstrate, how to deploy your own NuGet Server on free instance of Azure Website, secure it with Basic HTTP Authentication, setup this new server so it can be used from Visual Studio, easily create automatic PowerShell scripts for deploying these libraries as NuGet packages to your server, use these NuGet packages in your projects and also how to achieve all this in just couple of minutes!
As a part of the “Preview for Developers” program Microsoft just recently released the first larger update for Windows Phone 8.1 called just “Windows Phone 8.1 Update” with OS version number 8.10.14147.180. The original Windows Phone 8.1 was 8.10.12359.845.
According to MSDN blog article this update brings primarily these new end user features:
- Cortana is now available for couple of new countries
- Live Folders – native implementation of app folders on the Start screen
- Option to simply select multiple SMS messages for deleting/forwarding
- Apps Corner, Private VPN, Store Live Tile, Internet sharing via Bluetooth, customizable snooze time for Alarms and more.
But probably the most interesting feature, that might be part of this update as well, is is the support for notification on accessories, typically on smart watches and other wearables. The best hint for this functionality is already in the phone settings – the new “accessory apps” section.
The second hint is the new available API, that’ll be shown in the rest of this article.
Working with files is one of the most common tasks when developing any Windows Phone or Windows apps. In this mini-series of articles I’ll show you available APIs in all Windows Phone and Windows versions, caveats when doing task such as checking if specific file exists, getting target file, reading writing data from/to files and also how to effectively extract data from ZIP files, and more.
In the first part of this series I’ll discuss available File IO APIs in Windows Phone 8, 8.1 Silverlight, 8.1 XAML, Windows 8 and 8.1 platforms and benchmark all available methods for testing, if target file in Local Folder exists, or not. To my great surprise, the performance of methods in StorageFolder API is dramatically different across different platforms and it’s not a good idea to use single approach everywhere.
In Windows Store apps for Windows 8.1 there are four basic input methods – touch, mouse, stylus and keyboard. In most of scenarios these input methods are all you need, but in case you want to offer more natural experience for controlling games on Windows 8.1, you can also add support for Xbox 360 and Xbox One controllers.
In this dev article I’ll show you, how to use in any C#/XAML app or game for Windows 8.1 the Xbox 360 Controller API, how to detect presence of such controller and how to poll for current state of all buttons.
In my previous article I’ve shown a new way, how can we use Json file as a data source for design-time data in new Windows 8.1 apps. Luckily, it’s possible to use similar approach in Windows Phone 8 apps as well!
When designing Windows 8.1 apps it’s essential to have design-time data available in some way, so we can actually see how the app will look like.
Iris Class described in this great article, that there are several ways, how to achieve this:
- Using XAML – Design time data source set in XAML
- Using a ‘standalone’ data source class – Design time data source set in XAML
- Conditional data source – Design time data source set in code
But what I missed in this aticle is probably the most interesting way, how to use design-time data in Windows 8 apps – using external Json files. Here’s a short guide, how to do it:
Just today I’ve published one of my first Windows Phone application Bugemos as Open Source on GitHub.
The app, that I created and published to Windows Phone Store back in late 2011, is just a simple RSS reader displaying latest comic strips from the web http://www.bugemos.com. The reason I’m publishing it as Open Source is that I think it might give a helpful insight to starting WP developers and to the community as well. Note the published source code is not the exact one, that was used in the currently published app. The app was updated from WP7.5 to WP8 and also instead of original AsyncCTP it now uses current Microsoft.Bcl.Async NuGet package.
So let’s see, how is the application designed and what it does.