Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletter Hub
Free Learning
Arrow right icon
timer SALE ENDS IN
0 Days
:
00 Hours
:
00 Minutes
:
00 Seconds
Cross-platform UI Development with Xamarin.Forms
Cross-platform UI Development with Xamarin.Forms

Cross-platform UI Development with Xamarin.Forms:

Arrow left icon
Profile Icon Paul Johnson
Arrow right icon
Mex$963.99
Full star icon Full star icon Full star icon Half star icon Empty star icon 3.7 (7 Ratings)
Paperback Aug 2015 330 pages 1st Edition
eBook
Mex$693.99 Mex$771.99
Paperback
Mex$963.99
Subscription
Free Trial
Arrow left icon
Profile Icon Paul Johnson
Arrow right icon
Mex$963.99
Full star icon Full star icon Full star icon Half star icon Empty star icon 3.7 (7 Ratings)
Paperback Aug 2015 330 pages 1st Edition
eBook
Mex$693.99 Mex$771.99
Paperback
Mex$963.99
Subscription
Free Trial
eBook
Mex$693.99 Mex$771.99
Paperback
Mex$963.99
Subscription
Free Trial

What do you get with Print?

Product feature icon Instant access to your digital copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Redeem a companion digital copy on all Print orders
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Table of content icon View table of contents Preview book icon Preview Book

Cross-platform UI Development with Xamarin.Forms

Chapter 1. In the Beginning…

By virtue of using a mobile device, you will have used a messenger app of some description or the other (as well as any number of other apps). As time has moved on, so have the apps. For the humble messenger software, you can now add sound, video, and audio, and have it extend over many messages (a message was traditionally 160 characters, as it was only used by telecom operatives to send small messages informing others of their progress or a fault in the system). How did the apps metamorphose to the apps we have today? The answer is simple—planned changes.

In this chapter, we will cover the following topics:

  • Application planning

  • Application setup

  • Creating the correct provisioning profile for iOS

  • The database model

Application planning


In the 1990s, there was a piece of software for the Acorn RISC OS range of machines called SBase. The software was one of the most stable, intuitive, and above all simple-to-use applications. I was surprised many years later to find out that this was not down to unit testing, A-B testing, or anything like that. The reason was that before a single line of code had been written, absolutely everything was written by hand first. Not code (this would not be a good plan), but a detailed storyboard and flow.

After a month or so of planning, the work of coding began. However, as the author knew what would go where, the final development time was much less than the time it would have taken, had he just sat down and started coding.

The design templates

There are quite a number of different design templates freely available for download (a quick search on https://images.google.com/ will show them). The following template will be used in this book:

For each new view, a new design will be drawn. While the app will never be a one-to-one representation of the design, it should be close and give an idea of how all sections would work together.

It is also a good idea to use piece of flowcharting software when creating a flow. Again, there are plenty of pieces available, but through trial and error, one of the best that I have found is called the yEd Graph Editor (http://www.yworks.com/en/products/yfiles/yed/).

When creating any piece of software, it's also a good plan to have a shopping list of the features that you would like to see in the final application.

A messenger – a shopping list of features

The shopping list should feature everything that you want in the app rather than everything that you think should be in the app. If you have a large budget, then the shopping list can be longer. Remember, the longer the list, the larger (and more complex) the application.

The basics of any messenger application UI comprises of the following lists:

  • Contacts

  • Add and remove contacts

  • Message composition, add sound, and pictures

  • Message summary

  • Message display or text to speech

  • Message delete

  • Login/register/forgotten password

  • Forced synchronization

The following are a few details about the basics:

  • Contacts can be from Facebook or your contacts, and should also provide a summary of the contact

  • Messages need to be entered via a keyboard or speech to text (STT)

  • Messages need to be able to include pictures (not video) and sound

  • Message notifications (new messages) are required

  • Forced synchronization causes the app to download all messages and contacts from the server

Speech to text and text to speech

Speech to text is a vital addition to most applications to facilitate those who are visually impaired. These facilities are available on all mobile platforms, and the inclusion will greatly improve the scope and range of users who can take advantage of your new app.

Speech to text is not the same as adding sound to a message; adding sound is different.

Other considerations

While Android is a very open platform that allows users to create their own apps for messaging, iOS is very prescriptive over what you can and cannot do. For example, to create a text message, you must use their text message service and software. This is fine, except that it ties you in strongly to what Apple provides, and doesn't give the end user any different an experience; so why should they bother using what you have over what Apple supplies?

To remove this requirement, a web service can be used. The use of the web service gives a number of advantages:

  • No requirement to use the built-in messaging software

  • Offline storage

  • Notifications

  • Large amount of storage

  • Routing facilities

  • Ability to download messages to any device

This final point is of great importance for this application.

Cross-platform considerations

As the name of this book includes Xamarin, and you are reading this, you will be aware that we are using C# for the core language. This will already be giving a massive advantage in terms of code sharing (for example, all the data services, SQL, and core code will be the same, irrespective of the platform), and also by using one of the more recent additions to Xamarin. It also means that the user interface can be shared by using Xamarin.Forms.

We can also swap between devices. On my desk, I have to handle a range of Android devices (tablets and phones), a couple of Windows Phones, a couple of iPhones, and an iPad. At any given time, I may have two of the phones on me, and want to use the app on either of the devices. Not only will the data structure need to be the same but ideally, a similar user interface is needed. This is not to say that each platform version cannot make use of some specific tweak on each platform, but the overall experience needs to be the same.

A secondary aspect to having a cross-platform application is to have a common settings file. All three platforms store user data in a different (and largely incompatible) way meaning that for personal data and app settings, a common profile needs to be established. This can be achieved either online, offline, or both, each having their own advantages and disadvantages:

Method

Advantage

Disadvantage

Offline

Locally stored

App can be used out of network coverage

File can be corrupted

Not portable between devices

Online

Permanently available

Unlikely to become corrupted by app failure

Can be used by any device

Requires connection (updates may therefore not always be in sync)

Both

Portable

App can be used when not in network range

Unlikely to be corrupted

Can be used on any device

Synchronization

Obviously, from a portability and usability point of view, having both as options is the best way forward; however, synchronizing changes may be an issue: which is the newer settings file?

Language considerations

It is no longer acceptable to have apps run in a single language. While it was the norm to say, "Hey! I'm English, so everyone can understand English" a number of years ago, there is no valid reason why that now needs to be the case, as all devices are able to localize given the correct language file.

The issue though is that to have every language covered would cost a fortune—many (human) language translators charge between £50 and £100 per hour (at the time of writing), so unless you're part of a larger organization with deep pockets, this can be ruled out.

Online translation services

The next consideration would be to use the likes of Google Translate for the language files used within one version of the app. This is not a bad idea but has a simple problem: though the likes of Google Translate are getting much better, it fails to recognize the context of a sentence so the translation may be incorrect. That said, if the translation is for a message 3 of 10 (stored as message %0 of %1 in the localization file), the returned translation to German would be correct.

This allows translations to any language covered by Google (or the translation service you choose to use).

The only remaining issues are storage of the translated messages, and having them as usable across all platforms.

Consider how Android and iOS store localized strings:

  • iOS: The text for translation is stored within the language file like the following code:

    "Common.Save"="Save";
  • Android: This is more in line with a standard XML format, as shown in the following code:

    <string name="Common.Save">Save</string>

Android is closer to a standard XML format while iOS as a Dictionary<string,string>. The two are not easily translatable and really, there isn't a simple, cross-platform way to translate text.

However, there is a way around this issue, which also means that should Google add further languages to their system, further language files need no longer be created. The only caveat is that it requires at least one language file to store the translation data in a database on the device and on the server (for others to use).

While this may be initially slow for grabbing the translation file from the server, it won't be slow later on.

The internal data structure

Windows Phone, iOS, and Android all come with an implementation of SQLite (though Windows Phone does require the package to be installed via nuget). This means that we can have the same data structure for all platforms apart from being able to match up to the server with minimal issues. The code for accessing the databases will be covered in Chapter 5, Data, Generics and Making Sense of Information; here we will discuss the data table classes.

Any database can be considered as a series of disparate objects that may or may not be linked. Each of these objects is an entry in a data table.

Consider the following example of a book, author, and publisher:

The Newton-le-Willows Community Library has a hundred books on Android development. For argument's sake, they have only one edition and a single author for each book. Each book has the following information stored on it: the ISBN, price, author, publication date, and publisher.

The ISBN number is unique to each book, so it is never replicated making it perfect as what is known as a Primary Key. The author may have written any number of books (not only on Android, but possibly in Chemistry and the UK Armed Forces between 1960 and 1965, for example). A name is also not unique—I went to school with three people who had the same name as me.

The publisher too, will have a table containing information such as their address.

In terms of a database structure, the publisher and the author will have what is known as a one-to-many relationship with the book (the meaning is literally that—one publisher or author to many books) going FROM the publisher or author table TO the book. Going FROM the book TO the author or publisher shows a many-to-one relationship.

To complete this triangle, there will be a relationship between the publisher and the author. As the publisher is a single entity using multiple authors, it will have a one-to-many relationship with the authors.

The ISBN number will have a one-to-one relationship with the publisher and the author.

The messenger data structure

For each table, the key data stored needs to be defined. We have, in our application, a simple set up:

  • The message

  • Contacts

  • Backend storage

  • The language

Each of these will need defining.

The message

A message contains a number of pieces of information

  • A unique identifier

  • Who it is from (a contact)

  • Date and time sent

  • Attachments (though this will be from a separate table, linked by ID)

  • The previous message Id

The previous message Id is important for message threading. The first message in any thread will have a value of -1. It is then just a case of moving through the message identifiers to correctly thread a message.

Attachments can be either an audio file or an image. It is never a good idea to store these on a device within the database, as it leads to massive slowdown of the application (SQLite was never designed to store BLOB (Binary Large OBject) data types).

Contacts

Contacts are anyone (including you). A contact can be anyone invited to share in the app with you; it can be read from your mobile device directory or obtained via the likes of Facebook. Each contact will have the following information:

  • Contact ID

  • Name

  • E-mail

  • Phone number

  • Last-used date

  • Username

Each message is linked to another message as well as to a contact.

Backend storage

While it is fine to have storage on the device, there needs to be an external server somewhere. Currently, there are two main players when it comes to external servers if you are unable to host things yourself. They are Microsoft Azure and Amazon. Both offer the same sort of facilities, but given that Xamarin uses the .NET framework, it makes slightly more sense to use Azure.

The configuration and setting up of an Azure service is covered extensively in Chapter 14, Bringing It All Together.

Making sure the messages get through

Part of ensuring that messages get through as soon as they are sent is to use a push notification. Essentially, this is sent out from the server to the application. Unfortunately, the procedure for getting this to work is not the same for Android and iOS.

Setting up for Android

For Android, push notifications are a simple affair, as shown in the following steps:

  1. Register the application with Google and obtain an API key.

  2. Once you have this, go into the Azure portal, click on Mobile Services, select the service name, and then select Push.

  3. To obtain the key, go to https://console.developers.google.com/start, and click on Create Project. Enter a new project name. After sometime, the project will appear on the console.

  4. Next, select Add an API and switch on the Google Cloud Messaging for Android option.

  5. Now select the credentials and create a new Public API access key. You will see the following displayed. Over here, select Server Key:

  6. After this point, you will need to just create a new key by selecting Create:

  7. Once the API key has been created, copy and paste it onto the Azure push services page (shown in the following screenshot):

  8. Once complete, select Save and Android is set up, server side, to send a push notification.

Setting up for iOS

For push notifications to work on iOS, you will need a valid iOS developer account with Apple (currently this costs $99 per year). Assuming you have such an account, log in.

If you already have a developer profile set up, skip to the Creating and configuring for push notifications section.

Creating your iOS profile

The certificate is your digital signature that can be used for any application, for any given team. The use of certificates enables developers to work on different teams and still have a valid signing certificate. Creating a certificate is simple enough:

  1. Click on your Applications folder and navigate to Utilities | KeyChain Access.

  2. From the Menu bar, select Certificate Assistant | Request a Certificate From a Certificate Authority… (as shown in the following screenshot):

  3. Once this has been clicked, you will be presented with the following window:

  4. Fill in the User Email Address using the address that the Apple developer account is registered with.

  5. Click the Saved to disk radio button.

  6. When these have been filled in, select Continue. After a few moments, you will be asked where to save the certificate. Give the certificate a meaningful name and save. You can now minimize the Keychain Access application.

You now need to upload the certificate. Again, this is simple enough. Log into your Apple developer console (https://developer.apple.com/):

  1. Click on Certificates, Identifiers and Profiles, and select Certificates.

  2. Click on the Add icon.

  3. You will be presented with the options shown in the following screenshot:

  4. You will need to create at least an iOS App Development and an App Store and Ad Hoc certificate.

  5. The process for creating either of these certificates is the same. Select the certificate type, and click on Continue.

  6. You will be presented with an information page that covers how to create your certificate (performed in the preceding steps). Click on Continue.

  7. The next page allows you to upload the certificate you previously created to the Apple Developer portal. Click Choose File, navigate to where you saved the certificate, and click on OK to upload.

  8. Once the file has been selected, click on the Generate button. After a while, the certificate can be downloaded. Download and double click on the certificate to install.

  9. You can check whether the certificate has been installed by checking the Keychain Access application.

Creating and configuring for push notifications

We now have to create a profile for our application. On the developer portal, select Identifiers.

  1. Select the + button to create a new app.

  2. Fill in the App ID description (this is just a name for the app).

  3. Add an explicit app ID. This is recommended to be a reverse, domain-style string (for example, com.packt-pub.messenger).

  4. Towards the bottom of the page, you will need to select Push Notifications.

  5. Once complete, you will be presented with something similar to the following screenshot:

  6. Once you are happy with all the selections, click on Submit.

  7. Next, a certificate has to be generated for the notifications. If you're used to creating a certificate, generate two—one for development and one for distribution. If you're not, follow the instructions used for generating your initial certificate.

  8. Select the app created from the App IDs page on the developer site (as seen in the following screenshot):

  9. Select Edit.

  10. Go to the section marked Push Notifications.

  11. Starting with the Development SSL certificate, click on Create Certificate and follow the on-screen instructions. When requested, select the development certificate created in step 7.

  12. Once generated, download the certificates and double-click to install.

Exporting the certificate for Azure

The final step for creating the push notifications for Azure is to export what is known as a .p12 file. The steps for exporting the certificate are given as follows:

  1. To access this, start the Keychain Tool, and locate the freshly installed development push notification entry (highlighted in the following screenshot):

  2. Select File | Export and give the file a name. Then click Save, as shown in the following screenshot:

  3. This needs to be imported into Azure. As with Android, go to Mobile services | Push, and move to the Apple section:

  4. Click on upload, and upload the .p12 file you have just exported from the keychain tool. Ensure that Sandbox is selected when requested. When complete, you will see the following screen:

Azure, iOS and Android push notifications are now set correctly on the server side.

Adding packages to your application

For the application to be able to access the Azure services, it requires an additional package. You can manually create it, but it is easier to use the NuGet package. I will cover this in detail in Chapter 3, Making It Pretty and Logging In.

Summary


We've covered quite a lot of information in this chapter, from enabling push notifications to registering your app with Google and Apple, and by now you should have at least an appreciation for what is involved in even the simplest of applications.

In the next chapter, we will start looking at the user interface and at using Xamarin forms for the application UI.

Left arrow icon Right arrow icon
Estimated delivery fee Deliver to Mexico

Standard delivery 10 - 13 business days

Mex$149.95

Premium delivery 3 - 6 business days

Mex$299.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Aug 26, 2015
Length: 330 pages
Edition : 1st
Language : English
ISBN-13 : 9781784391195
Vendor :
Microsoft
Category :
Languages :
Tools :

What do you get with Print?

Product feature icon Instant access to your digital copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Redeem a companion digital copy on all Print orders
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Estimated delivery fee Deliver to Mexico

Standard delivery 10 - 13 business days

Mex$149.95

Premium delivery 3 - 6 business days

Mex$299.95
(Includes tracking information)

Product Details

Publication date : Aug 26, 2015
Length: 330 pages
Edition : 1st
Language : English
ISBN-13 : 9781784391195
Vendor :
Microsoft
Category :
Languages :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just Mex$85 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just Mex$85 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total Mex$ 2,645.97
Mastering Xamarin.Forms
Mex$676.99
Mastering Cross-Platform Development with Xamarin
Mex$1004.99
Cross-platform UI Development with Xamarin.Forms
Mex$963.99
Total Mex$ 2,645.97 Stars icon

Table of Contents

14 Chapters
In the Beginning… Chevron down icon Chevron up icon
Let's Get the Party Started Chevron down icon Chevron up icon
Making It Look Pretty and Logging In Chevron down icon Chevron up icon
Making Your Application Portable Chevron down icon Chevron up icon
Data, Generics, and Making Sense of Information Chevron down icon Chevron up icon
A View to a Kill Chevron down icon Chevron up icon
Connect Me to Your Other Services Chevron down icon Chevron up icon
What a Bind! Chevron down icon Chevron up icon
Addressing the Issue Chevron down icon Chevron up icon
This is the World Calling… Chevron down icon Chevron up icon
A Portable Settings Class Chevron down icon Chevron up icon
Xamarin Forms Labs Chevron down icon Chevron up icon
Social Media into the Mix Chevron down icon Chevron up icon
Bringing It All Together Chevron down icon Chevron up icon

Customer reviews

Top Reviews
Rating distribution
Full star icon Full star icon Full star icon Half star icon Empty star icon 3.7
(7 Ratings)
5 star 42.9%
4 star 14.3%
3 star 28.6%
2 star 0%
1 star 14.3%
Filter icon Filter
Top Reviews

Filter reviews by




Enaut Manterola Mar 01, 2018
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Great!
Amazon Verified review Amazon
ANH QUAN HOANG Sep 22, 2015
Full star icon Full star icon Full star icon Full star icon Full star icon 5
This is a good books for anyone looking to get started in using Xamarin platform. It corners many topics from the most basic, creating a simple button, to getting you app set up for push notifications. This book also discussed "delegates" and "customrenderer" which allow Xamarin a certain degree of flexibility. If you are family with C# and are interested in mobile development, then this book is a must read.
Amazon Verified review Amazon
Taskos George Oct 06, 2015
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Another great delivery from Paul F Johnson, this is a great book to start and get familiar with all the aspects of Xamarin Forms, even if you are already started using the technology an intermediate mobile developer will find many topics that will take him to the level needed. Great explanations in all related technologies involved.
Amazon Verified review Amazon
Sparagis Elias Sep 24, 2015
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
As a Xamarin Certified Mobile Developer, I have been with Xamarin.Forms since its first stable version and I can tell for sure, that it is very difficult to fit in one book the required knowledge for starting building cross-platform applications.The book Cross-platform UI Development with Xamarin.Forms by Paul F.Johnson, is a book that simply touches the great aspects and concerns of of starting building apps with the Xamarin.Forms. It is not a cookbook or a walkthrough (step-by-step) guide for Xamarin.Forms and it is quite certain that proper knowledge of the platform is advised in order to follow each chapter.I really enjoyed every chapter, because it really contains practical and useful knowledge not only for constructing a better UI but also to fully understand the cross-platform constructing process.I surely recommend it to native android or ios developers that want to find some quick answers for the Xamarin.Forms and its capabilities, before diving deeper in the platform.
Amazon Verified review Amazon
Amazon Customer Oct 07, 2015
Full star icon Full star icon Full star icon Empty star icon Empty star icon 3
A pretty good book that does a good job of introducing Xamarin Forms. He even covers the limitations of using PCL's (i.e. pointing out how some IO classes are not available) - little things like that can be very confusing when you're first starting out and expecting them to be there. He also covers setting up IOS provisions, push notifications and using maps. Features such as this involve a lot of knowing-where-to-go-just-to-point-and-click-a-checkbox and identifying those paths on your own can be quite frustrating so its nice to have a guide. Also covers a bit of Azure and a quick intro on Xamarin Labs. I could've done without the brief foray into his forensics past and building the time of death app but thats just my own personal idiosyncrasies. Overall a good intro book doesn't go deep like Petzold's book but you'll definitely walk away know a few things.
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the digital copy I get with my Print order? Chevron down icon Chevron up icon

When you buy any Print edition of our Books, you can redeem (for free) the eBook edition of the Print Book you’ve purchased. This gives you instant access to your book when you make an order via PDF, EPUB or our online Reader experience.

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela