Xamarin.Forms CarouselView with image indicators

Download source code

Most of us when we are very familiar with Bootstrap carousel, we expect the same output in mobile CarouselView either. But the problem with Xamarin.Form CarouselView doesn’t provide us such CarouselView with Image Indicators. 

So this article will help the crazy professionals

Step1: Create a Mobile App (Xamarin.forms) project

Open Visual Studio 2017    File    New    Project    Choose Cross-Platform template    choose Mobile App (Xamarin.Forms)    Name it as CarouselViewApp    Click on OK    choose .Net Standard    Click OK


Step2: Install CarouselView NuGet Package

Right click on CarouselViewApp    Manage NuGet Packages    type CarouselView.FormsPlugin and Install the package


Step3: Create a Model for Images as ImageModel.cs

Before that add the images in CarouselViewApp.Android    Resource    drawable

File: ImageModel.cs


Step4: Create ViewModel for MainPage.xaml

Right click on CarouselViewApp    Add    NewItem    Visual C#    Add new class MainPageViewModel.cs

File: MainPageViewModel.cs


Step5:  Adding namespace in the MainPage.xaml


Step6: Assign BindingContext for MainPage.xaml.cs

File: MainPage.xaml.cs


Step7: Creating UI for MainPage.xaml

File: MainPage.xaml

  1. By using Image.GestureRecognizers, we are firing click events using MVVM Architecture
  2. Rotation property for ListView helps us to set or get the current rotation of the element. Here we are rotating ListView to 270 deg
  3. Here the indicators row in Grid is build using RelativeLayout.
  4. RelativeLayout is used here to turn the ListView in Horizontal Direction
    1. At first we move ListView into RelativeLayout, and maintaining the RelativeLayout HeightRequest.
    2. Now we need to fit the ListView in RelativeLayout bounds, this we can do it by using RelativeLayout Constraints.
    3. RelativeLayout.XConstraint, RelativeLayout.YContraint  are used to fix the x,y positions. And then RelativeLayout.WidthConstraint is to set the width for image, RelativeLayout.HeightContraint is to set the height for image.
    4. And the final step is to rotate the ContentView. This will first rotate the cell and the fit image into it.


output: Now run the application


Tips to become Experienced Programmer

 “Experience is just a number”, in fact there is nothing difference between a Fresher and Experience. Every experience person also feels the same. When you are Fresher it doesn’t mean that you are less Intelligent / Skilled than Experience, you just need some time to stabilize your skills, intelligence, logical thinking and patience. Time will teach you everything. Most important difference is “Patience”, experience people will always show patience in any work. If you are a Fresher just keep some key points into your mind while coding, “That’s it”. Those key points will make you very closer to an Experience programmer/developer.

Key points to change you to an Experience programmer/developer:

  1. Learn how to Google
  2. Grip on OOPS
  3. Code Reuse
  4. Code comments
  5. Follow Standards


Learn how to Google:

  • Most of the Experience developers in IT sector are surviving because of If you know how to Google for a solution no doubt you can survive anywhere in IT sector. But need to remember is “Compromise nowhere until find the solution”.
  • Experience Developer:
    • Analyze the problem first
    • Google with the exact keywords
    • Picks up the popular forum sites like (stack overflow, Code project, Code Guru etc…)
    • start applying the up voted answers first
    • If not working, go for the all the other solutions and keep trying
    • if not working till, now he/she will start learning that new concept from technical content sites.

Note: As you have seen from the above process, “No where the person give up“. Just keep on trying till you find the solution, if not take your colleagues help.

Google API’s working formula

Minimum and simple words     Maximum results

For Example:

  • Who is the author of C (many words) gives few results
  • Author of C (few words)  good results

  • Prefer stack overflow first (Note: if it’s a known concept for you)
    • Some of the popular discussion forum sites (stack overflow, Code project, Code Guru etc…)
    • In the stack overflow the very first step search for the “Most up voted answer”.
    • “Read all the solutions”. Many solutions will work even if it’s not an up voted and vice versa.
  • Prefer site which has easy slang according to your terminology. If you pick the toughest slang of technical terminology you will never understand that topic in depth.


Grip on OOPS:


Strong in OOPS       you will argue with someone

Weak in OOPS         you will listen to someone

Confused wright!!

Yes when you are strong at something (For example: You know very well HTML). If your colleague doesn’t follow standards then what will be your reaction, sure you will argue with him and teach him the right way.

  1. Concentrate more and more on Loops (for, while, do while).
    1. If you are not confident on loops write every iteration on paper for some days.
    2. Iterate loops in your mind once you are confident.
  2. Use all oops concepts in every module if it’s not even required. So that you will not forget it.
  3. Teach someone who doesn’t know OOPS, teaching is the best-way to remember the basics all the time.
  4. Concentrate on unknown topics and learn at least one topic a day.


Code reuse

Most of the Experience Developers follow Code Reusing techniques all the time. Few techniques are using

  • Inheritance
  • Libraries (DLL’s)
  • Web Services & Web API’s


  1. Don’t ever write every piece of code in the same file
  2. Create libraries (or) Packages and Reuse them for Business Logics.
  3. Always prefer multi-layered architecture in all the Tiers of project. So that presentation of your code will be very clean.
  4. Create API’s for the Repositories (Repositories are noting but your Data Access Layer).
  5. Always try to maintain Loose coupling e., use Dependency Injection. This will be very helpful to test the application.
  6. Use Inheritance as much as you can.


Code Comments:

Few places where you should write comments:

  • File level / Class level comments
  • Method level comments
  • Code level comments


  1. Your code behind file (or) JavaScript file should look more green (or) red in color (color of comment depends on the language).
  2. Write a brief description on the top about complete file (Class file / script file) with Block Comment.
  3. Write XML comments on every method about the inputs, output, exception handling, date modified, and modified by.
  4. Write comments for every two or three lines, and for every code block in a function/ method.

Block Comment

XML comments

Follow Code Standards:

  1. Always use Pascal case (or) Camel case
  2. Don’t use names begin with numeric characters.
  3. Do not use Hungarian Notation!

Example: strName or nCount

  1. Don’t include the parent class name within a property name.

Example: Use Employee.Name NOT Employee.EmployeeName

  1. Give prefixes to Boolean variables using “IS”, “Has”, “Can”.
  2. Every developer has their own coding style.
  3. Don’t give more than one empty line in any piece of code
  4. Don’t write multiple classes in same file.

Differences between Java and DotNet

  • Java and .Net are two incomparable guided, but by fact that .Net is Framework of simply platform and supports for almost 63 languages and java is just a programming language.
  • These two technologies have different syntax but gives the same result.
  • Let’s look at some basic imports and usings used in java and .Net.

  • Now let’s look at some application based differences.

  • Now let’s look at some basic differences.

How to Improve Coding Skills


The best way of improving your coding skills is firstly “Throw your fear on coding in the dustbin” and stop thinking about whether I’m doing correct (or) wrong. Because the best programmers are the people who makes lot of mistakes and wrong coding in the beginning. So if you are doing wrong coding now then you must feel great that you’re going to become the best programmer soon.

Everyone may have their own definitions on improving coding skills. In my definition following are the characteristics:

  1. Practice
  2. Analyse
  3. Optimize
  4. Share knowledge.



  1. Practice all the basic programs like even-odd number, prime numbers, Fibonacci series etc.…..
  2. Don’t just copy and paste the code from your material that will never improve your logical thinking.
  3. Write program with your hands.
  4. Debug the code ‘N’ number of times until you understand the logic behind that program.
  5. Take own requirements and try to get expected outputs.
  6. Follow all the naming conventions.
  7. Write comments for every 3 line of code or for every block of code.
  8. Do hard work first smart work next.
  9. Think out of the bounds.


  1. Imagine picture of work before start programming.
  2. Proper planning is required before implementing the code.
  3. Choose tools which are required for your requirement.
  4. Think like an End User, to make your application more efficient.
  5. Commitment before starting the application and take a deadline, unless you take some deadlines you will never finish the program/ application.
  6. Understand the error before searching for solution.
  7. Don’t just copy and paste the unknown code from internet, understand the flow of the code first. And learn the unknown topics from that.



  1. Think for the alternate ways for implementing the code.

Ex: Think like what is the fastest way to compute the Nth Fibonacci number. In the formal case there is a simple formula. In later case the recursive definition allows for an iterative approach which only requires an addition and variable shuffling at each stage.

Binet’s formula corresponding to the nth Fibonacci number,

  1. Take your friends or colleagues advice on how you can code in other way.
  2. Diagnose performance problems and measure the speed impact of your code changes.
  3. Remove unnecessary declarations.
  4. Avoid using nested iterations as many, instead try with other solution.


Sharing Knowledge:

  1. Participate in group discussions and Seminars or Webinars.
  2. Review others code so you can learn some new concepts and their way of writing.
  3. Read blogs, forums and articles regularly and try to answer their questions.







Manual Testing Syllabus

  1. SDLC and SDLC Phases
  • Requirements Phase
  • Analysis Phase
  • Design phase
  • Coding Phase
  • Testing phase
  • Installation


  1. SDLC Models
  • Waterfall Model.
  • V Model
  • Agile Model.
  • Prototype Model.
  • Spiral Model
  • Hybrid Model


  1. Software Testing Methodologies
  • White Box Testing
  • Black Box Testing
  • Grey Box Testing


  1. White Box Testing.
  • Path Testing
  • Loop Testing
  • Condition Testing
  • Performance Testing WBT
  • Memory Testing WBT


  1. Black Box Testing
    1. Functional Testing
      • Component Testing
      • Integration Testing
      • System Testing
      • User Acceptance Testing.
      • Sanity/Smoke Testing.
      • Regression Test.
    2. Non Functional Testing
      • Performance Testing.
      • Compatibility Testing.
      • Security Testing.
      • Recovery Testing.
      • Installation Testing.
      • Adhoc Testing.
    3. Globalization Testing
      • I18N Testing.
      • L1ON Testing.


  1. Software Testing Life Cycle
  • Understand the requirements/System study
  • Write Test Plan
  • Write Test Cases
  • Traceability Matrix
  • Test Execution
  • Defect Tracking
  • Prepare test execution report(TER)
  • Retrospect Meeting


  1. Testing Techniques
  • ECP
  • BVA
  • Error Guessing


  1. Defect Tracking Tools (Learn & Implement)
  • TFS