This document provides an overview of the Force.com user interface and its model-view-controller (MVC) architecture. It describes the key components of the MVC pattern used in Visualforce pages, including controllers, views, and view components. It also explains standard controllers, controller extensions, and custom controllers, as well as common view components for data, actions, and user interface styling.
Reuse in ADF application. By using specialized java beans and declarative components you can easily implement reuse en object oriiented programming patterns.
Reuse in ADF application. By using specialized java beans and declarative components you can easily implement reuse en object oriiented programming patterns.
Overview of ASP.Net by software outsourcing company indiaJignesh Aakoliya
This presentation provides overview of ASP.NET for software development - by software outsourcing company India, iFour Technolab Pvt. Ltd. - http://www.ifourtechnolab.com
• Create a new ADF Skin and check Skin values being used
• Change the page background and font family
• Update the look and feel for table headers and links
• Change the pane body and shape of tabs
• Implement dynamic skin change
The tutorial describes the following topics in detail
CREATING AN ADF APPLICATION
DEPLOYING & RUNNING ADF APPLICATION ON WEBLOGIC SERVER
ADF DATA VISUALIZATION COMPONENTS
CREATING MORE COMPLEX BUSINESS COMPONENTS
CREATING MULTIPLE PAGE WEBSITES – PAGE FLOWS
CREATING JEE5 STATELESS SESSION EJBS
CREATING JAX-WS WEB SERVICES
ADDING THE NEW SERVICES INTO THE ADF APPLICATION
DATA VALIDATION (OPTIONAL)
Advanced SharePoint Web Part DevelopmentRob Windsor
Web Parts are the foundation of user interfaces in SharePoint. As a developer, it's relatively easy (particularly with the Visual Web Part) to build something simple and get it deployed. But what do you do when you need to add editable properties or when you need to connect two Web Parts together? This fast-paced, demo-heavy session covers the more advanced aspects of building Web Parts for SharePoint on-premises and SharePoint Online. We’ll take a look at creating custom editor parts, constructing connected Web Parts, and how to render Web Parts asynchronously. We’ll also explore how to build JavaScript-only Web Parts that will work with SharePoint Online.
Overview of ASP.Net by software outsourcing company indiaJignesh Aakoliya
This presentation provides overview of ASP.NET for software development - by software outsourcing company India, iFour Technolab Pvt. Ltd. - http://www.ifourtechnolab.com
• Create a new ADF Skin and check Skin values being used
• Change the page background and font family
• Update the look and feel for table headers and links
• Change the pane body and shape of tabs
• Implement dynamic skin change
The tutorial describes the following topics in detail
CREATING AN ADF APPLICATION
DEPLOYING & RUNNING ADF APPLICATION ON WEBLOGIC SERVER
ADF DATA VISUALIZATION COMPONENTS
CREATING MORE COMPLEX BUSINESS COMPONENTS
CREATING MULTIPLE PAGE WEBSITES – PAGE FLOWS
CREATING JEE5 STATELESS SESSION EJBS
CREATING JAX-WS WEB SERVICES
ADDING THE NEW SERVICES INTO THE ADF APPLICATION
DATA VALIDATION (OPTIONAL)
Advanced SharePoint Web Part DevelopmentRob Windsor
Web Parts are the foundation of user interfaces in SharePoint. As a developer, it's relatively easy (particularly with the Visual Web Part) to build something simple and get it deployed. But what do you do when you need to add editable properties or when you need to connect two Web Parts together? This fast-paced, demo-heavy session covers the more advanced aspects of building Web Parts for SharePoint on-premises and SharePoint Online. We’ll take a look at creating custom editor parts, constructing connected Web Parts, and how to render Web Parts asynchronously. We’ll also explore how to build JavaScript-only Web Parts that will work with SharePoint Online.
This lecture presents:
WebSite Design using Master Page and Themes and Skins.
Website Navigation
ADO.NET Fundamentals using Connected Model and Disconnected Models
Getting started with MVC 5 and Visual Studio 2013Thomas Robbins
The ASP.NET MVC Framework provides a powerful Model View Controller (MVC) approach to building web applications and provides separation of concerns, control over HTML output, intuitive URLs, and increased testability. We will start by looking at the what and why of ASP.NET MVC. Then we will explore the various pieces of ASP.NET MVC including routes, controllers, actions, and views. If you are looking to get started with MVC then don’t miss this session.
A simple presentation to understand what is ASP.net MVC4 and its structure.It covers all important features of MVC4 and razor view engine including screenshots
CyberLab Training Division :
ASP.NET is a web application framework developed and marketed by Microsoft to allow programmers to build dynamic web sites. It allows you to use a full featured programming language such as C# or VB.NET to build web applications easily.
This tutorial covers all the basic elements of ASP.NET that a beginner would require to get started.
Audience
This tutorial has been prepared for the beginners to help them understand basic ASP.NET programming. After completing this tutorial you will find yourself at a moderate level of expertise in ASP.NET programming from where you can take yourself to next levels.
Prerequisites
Before proceeding with this tutorial, you should have a basic understanding of .NET programming language. As we are going to develop web-based applications using ASP.NET web application framework, it will be good if you have an understanding of other web technologies such as HTML, CSS, AJAX. etc
ASP.NET supports three different development models:
Web Pages, MVC (Model View Controller), and Web Forms.
For More Details.
Visit: http://www.cyberlabzone.com
Similar to SFDC UI - Introduction to Visualforce (20)
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Tobias Schneck
As AI technology is pushing into IT I was wondering myself, as an “infrastructure container kubernetes guy”, how get this fancy AI technology get managed from an infrastructure operational view? Is it possible to apply our lovely cloud native principals as well? What benefit’s both technologies could bring to each other?
Let me take this questions and provide you a short journey through existing deployment models and use cases for AI software. On practical examples, we discuss what cloud/on-premise strategy we may need for applying it to our own infrastructure to get it to work from an enterprise perspective. I want to give an overview about infrastructure requirements and technologies, what could be beneficial or limiting your AI use cases in an enterprise environment. An interactive Demo will give you some insides, what approaches I got already working for real.
JMeter webinar - integration with InfluxDB and GrafanaRTTS
Watch this recorded webinar about real-time monitoring of application performance. See how to integrate Apache JMeter, the open-source leader in performance testing, with InfluxDB, the open-source time-series database, and Grafana, the open-source analytics and visualization application.
In this webinar, we will review the benefits of leveraging InfluxDB and Grafana when executing load tests and demonstrate how these tools are used to visualize performance metrics.
Length: 30 minutes
Session Overview
-------------------------------------------
During this webinar, we will cover the following topics while demonstrating the integrations of JMeter, InfluxDB and Grafana:
- What out-of-the-box solutions are available for real-time monitoring JMeter tests?
- What are the benefits of integrating InfluxDB and Grafana into the load testing stack?
- Which features are provided by Grafana?
- Demonstration of InfluxDB and Grafana using a practice web application
To view the webinar recording, go to:
https://www.rttsweb.com/jmeter-integration-webinar
Neuro-symbolic is not enough, we need neuro-*semantic*Frank van Harmelen
Neuro-symbolic (NeSy) AI is on the rise. However, simply machine learning on just any symbolic structure is not sufficient to really harvest the gains of NeSy. These will only be gained when the symbolic structures have an actual semantics. I give an operational definition of semantics as “predictable inference”.
All of this illustrated with link prediction over knowledge graphs, but the argument is general.
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...UiPathCommunity
💥 Speed, accuracy, and scaling – discover the superpowers of GenAI in action with UiPath Document Understanding and Communications Mining™:
See how to accelerate model training and optimize model performance with active learning
Learn about the latest enhancements to out-of-the-box document processing – with little to no training required
Get an exclusive demo of the new family of UiPath LLMs – GenAI models specialized for processing different types of documents and messages
This is a hands-on session specifically designed for automation developers and AI enthusiasts seeking to enhance their knowledge in leveraging the latest intelligent document processing capabilities offered by UiPath.
Speakers:
👨🏫 Andras Palfi, Senior Product Manager, UiPath
👩🏫 Lenka Dulovicova, Product Program Manager, UiPath
Let's dive deeper into the world of ODC! Ricardo Alves (OutSystems) will join us to tell all about the new Data Fabric. After that, Sezen de Bruijn (OutSystems) will get into the details on how to best design a sturdy architecture within ODC.
UiPath Test Automation using UiPath Test Suite series, part 4DianaGray10
Welcome to UiPath Test Automation using UiPath Test Suite series part 4. In this session, we will cover Test Manager overview along with SAP heatmap.
The UiPath Test Manager overview with SAP heatmap webinar offers a concise yet comprehensive exploration of the role of a Test Manager within SAP environments, coupled with the utilization of heatmaps for effective testing strategies.
Participants will gain insights into the responsibilities, challenges, and best practices associated with test management in SAP projects. Additionally, the webinar delves into the significance of heatmaps as a visual aid for identifying testing priorities, areas of risk, and resource allocation within SAP landscapes. Through this session, attendees can expect to enhance their understanding of test management principles while learning practical approaches to optimize testing processes in SAP environments using heatmap visualization techniques
What will you get from this session?
1. Insights into SAP testing best practices
2. Heatmap utilization for testing
3. Optimization of testing processes
4. Demo
Topics covered:
Execution from the test manager
Orchestrator execution result
Defect reporting
SAP heatmap example with demo
Speaker:
Deepak Rai, Automation Practice Lead, Boundaryless Group and UiPath MVP
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...DanBrown980551
Do you want to learn how to model and simulate an electrical network from scratch in under an hour?
Then welcome to this PowSyBl workshop, hosted by Rte, the French Transmission System Operator (TSO)!
During the webinar, you will discover the PowSyBl ecosystem as well as handle and study an electrical network through an interactive Python notebook.
PowSyBl is an open source project hosted by LF Energy, which offers a comprehensive set of features for electrical grid modelling and simulation. Among other advanced features, PowSyBl provides:
- A fully editable and extendable library for grid component modelling;
- Visualization tools to display your network;
- Grid simulation tools, such as power flows, security analyses (with or without remedial actions) and sensitivity analyses;
The framework is mostly written in Java, with a Python binding so that Python developers can access PowSyBl functionalities as well.
What you will learn during the webinar:
- For beginners: discover PowSyBl's functionalities through a quick general presentation and the notebook, without needing any expert coding skills;
- For advanced developers: master the skills to efficiently apply PowSyBl functionalities to your real-world scenarios.
Essentials of Automations: Optimizing FME Workflows with ParametersSafe Software
Are you looking to streamline your workflows and boost your projects’ efficiency? Do you find yourself searching for ways to add flexibility and control over your FME workflows? If so, you’re in the right place.
Join us for an insightful dive into the world of FME parameters, a critical element in optimizing workflow efficiency. This webinar marks the beginning of our three-part “Essentials of Automation” series. This first webinar is designed to equip you with the knowledge and skills to utilize parameters effectively: enhancing the flexibility, maintainability, and user control of your FME projects.
Here’s what you’ll gain:
- Essentials of FME Parameters: Understand the pivotal role of parameters, including Reader/Writer, Transformer, User, and FME Flow categories. Discover how they are the key to unlocking automation and optimization within your workflows.
- Practical Applications in FME Form: Delve into key user parameter types including choice, connections, and file URLs. Allow users to control how a workflow runs, making your workflows more reusable. Learn to import values and deliver the best user experience for your workflows while enhancing accuracy.
- Optimization Strategies in FME Flow: Explore the creation and strategic deployment of parameters in FME Flow, including the use of deployment and geometry parameters, to maximize workflow efficiency.
- Pro Tips for Success: Gain insights on parameterizing connections and leveraging new features like Conditional Visibility for clarity and simplicity.
We’ll wrap up with a glimpse into future webinars, followed by a Q&A session to address your specific questions surrounding this topic.
Don’t miss this opportunity to elevate your FME expertise and drive your projects to new heights of efficiency.
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf91mobiles
91mobiles recently conducted a Smart TV Buyer Insights Survey in which we asked over 3,000 respondents about the TV they own, aspects they look at on a new TV, and their TV buying preferences.
The Art of the Pitch: WordPress Relationships and SalesLaura Byrne
Clients don’t know what they don’t know. What web solutions are right for them? How does WordPress come into the picture? How do you make sure you understand scope and timeline? What do you do if sometime changes?
All these questions and more will be explored as we talk about matching clients’ needs with what your agency offers without pulling teeth or pulling your hair out. Practical tips, and strategies for successful relationship building that leads to closing the deal.
2. Overview
• MVC Architecture
• Hello World Example
• Controllers
• View Components
• Native UI
• Security
3. MVC Architecture
• View or Presentation – HTML with VisualForce
specific XML tags.
• Controller – Apex classes with business logic.
• Model (data read and write access) is part of
the Controller.
5. Controllers
• Interaction of the controller with the UI is via
the variables and action methods.
• Action methods perform the processing work
on behalf of the user. Wired up to buttons,
links, and even asynchronous events on the
user interface.
• Variables exposed to the presentation layer
via getters and setters.
6. Types of Controllers
• Standard Controllers - replicate the behavior
of the native UI, such as editing and creating
records, but allow customization without
code.
• Controllers with Extensions – classes written
in Apex that add extend or override behavior
of standard controllers.
• Custom Controllers – implement from scratch.
7. VisualForce Page
• Defines the appearance of the UI using a mixture
of standard HTML and VisualForce-specific XML
markup.
• The XML markup is used to add view components
to the page.
• View components bind the controller to the page,
defining how data and user actions are to be
rendered in the user interface.
• Force.com provides a standard set of view
components to support common HTML UI
patterns and supports user-defined components.
8. Interaction between Page and
Controller
• In the MVC picture, the arrows between the page
and the controller represent expressions.
• Expressions are embedded in view components
to allow the page to reference methods in the
controller or in system classes such as UserInfo.
• Expressions in Visualforce use the same language
as formula fields in the database, with a special
prefix and suffix added.
• For example, {!save} is an expression that invokes
the save method of the controller.
10. Hello World MyPageController
public class MyPageController {
public String name { get; set; }
public String message { get; private set; }
public PageReference hello() {
message = 'Hello, ' + name;
return null;
}
}
11. Standard Controllers
• Every database object, both standard and
custom, has a standard controller.
• Its name is simply the name of the object.
• No Apex code exists for a standard controller.
• The controller implementation is already
provided by Force.com.
• By default, the standard controller operates on a
single record at a time. It receives this record
from the id parameter in the URL.
12. Expressions for Standard Controller
Following expressions are available in a page that uses a standard controller.
Data: {!id} is the unique identifier of the current record, and {!object} is the
current record itself, where object is the lowercase name of the object. All
fields of the object are automatically available, including related child objects
but not parent objects.
Navigation: {!cancel} navigates to the cancel page, {!edit} to the standard edit
page, and {!view} to the standard view page.
Action and Navigation: {!delete} deletes the current record and navigates to
the standard delete page, and {!save} saves the current record and refreshes
the page.
Action Only: {!quicksave} saves the current record without navigation.
13. Standard Set Controller
• Operates on a list of records rather than a
single record. The list is produced by executing
a view, a user-defined set of column names,
filter criteria, and sort criteria for an object.
<apex:page standardController="Proj__c
recordSetVar="projects">
<apex:repeat value="{!projects}" var="p">
{!p.Name}<br />
</apex:repeat>
</apex:page>
14. Standard Set Controller
• The recordSetVar indicates to Force.com that
the standard set controller should be used.
• Can work with up to 10,000 records at a time.
• Supports pagination with a variable page size.
It also supports multiple selection and actions
on a selected set of records.
15. • Data: The variable name you set in recordSetVar is bound to the current list of
records, {!selected} is an array of SObjects that are selected, {!resultsSize} sets or
gets the number of records currently displayed, and {!completeResult} is a Boolean
containing false if more than 10,000 records exist.
• Pagination: Navigate across multiple pages of data using the {!first}, {!last}, {!next},
and {!previous} actions. {!pageNumber} sets or gets the current page number, and
{!pageSize} sets or gets the number of records in a page. {!hasPrevious} returns true
if a previous page exists, {!hasNext} returns true if a subsequent page exists.
• Filters: {!filterId} is the unique identifier of the currently selected filter (list view),
and {!listViewOptions} is an array of SelectOption objects containing the names and
identifiers of the available list views.
• Navigation: {!cancel} navigates to the cancel page, and {!edit} to the standard edit
page.
• Action and Navigation: {!delete} deletes the current record and navigates to the
standard delete page, and {!save} saves the current record and refreshes the page.
• Action Only: {!quicksave} saves the current record without navigation.
16. Controller Extensions
• Extends or Overrides the behavior of a Standard or a Custom
Controller.
• Primarily used to integrate Visualforce more tightly with the native
user interface. Many features of Visualforce integration such as
overriding standard buttons are not supported for pages that use
custom controllers.
• Custom controllers can be easily retrofitted to become controller
extensions.
• Multiple extensions can be used in a single page, enabling a large
monolithic controller to be divided into smaller controllers by
behavior, where some pages might use only a subset of the
behaviors.
17. Controller Extensions (contd…)
• A controller extension is any Apex class containing a
constructor that takes a single argument of type
ApexPages.StandardController or
CustomControllerName, where CustomControllerName
is the name of a custom controller you want to extend.
• Multiple controller extensions can be defined for a
single page through a comma-separated list. This
allows for overrides of methods with the same name.
• Overrides are defined by whichever methods are
defined in the “leftmost” extension, or, the extension
that is first in the comma-separated list.
18. Example: Controller Extensions
• Controller with Extensions
public class MyPageController {
private ApexPages.StandardController controller;
public MyPageController(ApexPages.StandardController controller) {
this.controller = controller;
}
public PageReference doSomething() { return null; }
}
• Page Using Sample Controller Extension
<apex:page standardController="Resource__c“
extensions="MyPageController">
<apex:form>
<apex:commandButton action="{!doSomething}"
value="Do Something" />
</apex:form>
</apex:page>
19. Custom Controllers
• Provide complete control over the behavior of a
page with no default implementation.
• Simply an Apex class designed to be bound to a
Visualforce page. No new syntax to learn.
• Involves defining the data to make available to
the page and the actions that the page can
invoke.
• Page Components use expressions to bind data
exposed in the Controller. This binding is by
reference, so data can be modified in the page or
the Controller.
20. Example Custom Controller
public class MyPageController {
public Proj__c proj { get; private set; }
public MyPageController() {
proj = [ SELECT Name, Account__r.BillingCity
FROM Proj__c
WHERE Name = 'Tim Barr' LIMIT 1 ];
}
}
21. Expression Language
• Expression language allows traversal of an object
through dot notation, so providing separate getters
and setters for every field in a database record, for
example, is not necessary. Expose the object itself and
use dot notation to access its fields.
• you can combine expressions to form more complex
expressions. The expression {!isVisible && isEditable}
invokes both the getIsVisible and getIsEditable
methods on the controller and evaluates to true if they
are both true.
• Conditional expressions are also supported.
22. Action Methods
• Actions on a page are wired up to action methods in the controller, again
by expression language.
• Action methods are public, non-static controller methods.
• Return a PageReference object or null. If null, the current page is
refreshed. If not, the PageReference is used to determine the location of
the new page.
• Use the setRedirect method on a PageReference. A redirect updates the
browser’s URL, resets the view state and prevents problems with the
browser’s reload button.
• Perform custom business logic, like using DML methods to insert a record
to the database.
23. View Components
• View components work with the controller to
define the appearance and behavior of a
Visualforce user interface.
• They connect variables in the controller to input
and output elements such as text boxes and
labels, and methods in the controller to action-oriented
elements such as buttons and links.
• Force.com provides a library of standard view
components to support common Web user
interface design patterns.
24. Types of View Components
• Data Components – move data in/out of the controller
using HTML elements.
• Action Components - invoke methods on the controller,
updating the view state and refreshing the page or
navigating to a new page.
• Primitive Components – similar syntax to HTML elements.
• Force.com Styled Components – allow pages to inherit the
style of the native UI.
• Force.com UI Components - – allow pages to inherit the
style & behavior of the native UI – list Views, enhanced List
Views, related List views, detail views.
• Custom Components
25. View Components Basics
• View components are embedded in a Visualforce page
using XML markup.
• Every user interface page must begin with the page
component.
• All Visualforce components must be declared within
the page component.
• The rendered attribute, present on most components
allows conditional rendering of its HTML. It is a
boolean value that indicates whether the component is
included in the page. Setting rendered to false does not
hide the component using CSS. It omits it entirely from
the rendered page.
26. Example of a View Component
• The XML markup of a view component
consists of three parts: the component name,
an optional set of attributes, and an optional
component body.
<apex:dataList value="{!resources}" var="resource">
<b>{!resource.Name}</b>
</apex:dataList>
27. Page Definition
• Every Visualforce user interface page must
begin with the page component.
• Connect the page to a controller and
optionally override the global appearance of
the page.
• Requires either a standard (standardController
attribute) or a custom controller (controller
attribute) or a controller extension (via the
extensions attribute).
28. Page Definition Style
• By default, pages are styled consistently with
the Force.com native UI.
• include its stylesheet, sidebar, and header
region containing application tabs, banner,
and drop-down list of applications.
• Override this behavior by setting the
standardStylesheets, sidebar, and showHeader
Boolean attributes.
29. Data Components
• Allow DB fields and records to be manipulated within a Visualforce
page. 3 Types:
• Metadata-Aware Components: The HTML rendered by these smart
components varies based on the definition of the field. These
components are valid only when bound to database objects.
• Primitive Data Components: If field data is contained in a variable
in Apex code rather than a database object, use primitive data
components to render input and output HTML elements bound to
their values.
• Repeating Components: If you have a list of any type of object, you
can iterate over it with a repeating component to render its
contents.
30. Metadata-Aware Components
• 2 components: one for input (inputField) and
one for output (outputField).
• inputField must be within a Form component.
• For inputField, the html displayed depends on
the database field it is bound to.
• The outputField formats the value of a field
using the correct pattern for that field’s data
type.
31. Primitive Data Components
• Add Visualforce functionality to standard HTML
tags.
• Use these components when you are working
with data that is not contained in a database
object or when the standard Visualforce
rendering or behavior is not desirable.
• Except outputLabel, all components listed in the
table must be contained in a form component or
else compilation fails.
• Examples: inputText, selectList, selectRadio, etc.
32. Repeating Data Components
• Bound to a list of values, iterate over them,
rendering the component body for each child
in the collection.
• Attributes: value (collection) and var (current
child).
• 3 types: dataList (HTML List), dataTable (HTML
table) and repeat (no HTML, custom HTML
provided by developer).
33. Action Components
• Allow the page to invoke a method on the Controller.
The method on the controller typically issues a DML &
then refreshes the current page or navigates to a new
page.
• Setter methods on Controller used to inject data from
the page.
• 2 basic action components: commandButton and
commandLink.
• Valid only inside a Form Component.
• action attribute specifies the name of the controller
method to invoke or the URL of a new page to navigate
to.
34. Primitive Components
• Very similar to standard HTML tags but PCs can do
server side conditional rendering which standard HTML
cannot.
• Visualforce provides the rendered attribute, that
improves the performance of pages by conditionally
rendering markup based on the state of the controller.
• Additional Primitive Components: includeScript and
stylesheet. These 2 do not have the rendered attribute,
have a val attribute that specifies the URL of the script
or style sheet to load. More efficient & ensure scripts
and stylesheets are not duplicated on the page.
35. Force.com Styled Components
• Force.com’s native UI makes heavy use of CSS and
JavaScript within its Web pages to provide a
consistent look-and-feel across the platform.
• Many Visualforce components deliver this same
styling to developers, without requiring any
knowledge of Force.com’s CSS or other
implementation details.
• 5 Categories based on their function: Page
Structure, Action Containers, Table, Paging
Components, Notifications.
36. Force.com Styled Components -
Categories
• Page Structure: sectionHeader, pageBlock, pageBlockSection, and
pageBlockSectionItem are the native structural elements used by
Force.com to organize a page into a hierarchy of clearly identifiable
sections, subsections, and sets of label/field pairs.
• Action Containers: pageBlockButtons and toolbar / toolbarGroup organize
a series of buttons or links for performing actions on the page.
• Table: pageBlockTable is used like a dataTable but renders rows and
columns in the Force.com native style.
• Paging Components: panelBar / panelBarItem and tab / tabPanel group
components into pages that can be dynamically shown and hidden.
• Notifications: pageMessages displays errors and information.
37. Force.com UI Components
• listViews: rendered by Force.com on the list page
of an object tab when the Enable Enhanced Lists
option is disabled for the organization.
• enhancedList: consists of a drop-down list of view
names and a table of records returned by
executing the view.
• relatedList: renders the records of any one of an
object’s child objects.
• detail: provides a subset of the native user
interface’s detail page for an object.
38. listViews Component
• Capability to create and edit list views, as well
as execute them and render their records.
• The only required attribute of listViews is
type, which binds a database object type to
the component.
39. enhancedList Component
• Enhanced version of the listViews component.
• Same functionality but also includes drag-and-drop
re-orderable columns, sortable columns,
and results pagination with dynamic page
sizes.
• Appears in the native UI only when Enable
Enhanced Lists is enabled for the organization.
• Required attributes: height and (type of the
DB object or the listId of the listView).
40. relatedList Component
• Renders a list of paginated child records.
• Allows related records to be edited, deleted, and
created, depending on the object permissions of
the current user.
• Required attributes: list (the name of the child
relationship to be rendered in the list) and
subject (an expression language reference to the
parent record on the controller , defaults to the id
parameter of the page if not provided).
• Both MDRs and LRs are supported.
41. Detail Component
• Replicates the functionality of the native UI on
the detail page of a record. It respects the page
layout of the record, including page layouts
defined per record type.
• It also supports inline editing for the edit mode of
an object.
• Requires a subject or it attempts to read a record
identifier from the page’s id URL parameter.
• By default, all related lists are rendered below the
detail section unless the relatedList parameter is
set to false.
42. Extensible UI Elements
• The following are extensible using Visualforce.
• Standard Pages
• Standard Buttons
• Page Layouts
• Custom Buttons and Links
• Custom Tabs
43. Extensible UI Elements
• Standard Pages: default UI for maintaining the records.
Can be overridden with Custom Visualforce pages.
• Standard Buttons: navigate the user to standard pages.
Can be remapped to navigate the user to custom
pages.
• Custom Buttons: appear at the top and bottom of
standard pages.
• Custom Links: appear in a detail page.
• Custom Tabs: added to an application and appear at
the top under the application banner. A Visualforce
page can be configured as a custom tab.
44. Standard Pages
• 4 standard pages for working with DB records.
• Tab Page: appears when a custom object tab
is clicked. Shows recently accessed records.
• List Page: shows records in a list. Reach this
page by clicking Go button on the tab page.
• View Page: read-only view of a single record
and it’s related records.
• Edit Page: same layout as the view page but
lets you change and save the record.
45. Overriding Standard Pages
• Tab, view, and edit pages can be overridden
only with Visualforce pages that use a
standard, single record controller.
• The list page must use a standard set
controller.
• Controller extensions are supported in all
pages.
46. Overriding Standard Buttons
• 4 buttons can be overridden.
• New – navigates to edit page of a new record.
• Delete – page navigated to after record is
deleted. Default is the list page.
• Clone -> to edit page of a duplicated record.
• Accept – applies to records owned by a queue
rather than a single user. Enables to transfer
ownership to the user. Appears on a list page
when displaying records owned by a queue.
47. Overriding Page Layouts
• A Visualforce page can be embedded in an
object’s page layout alongside its fields.
• For Visualforce pages to appear in the page
layout editor, they cannot already be in use by
a tab and must use a standard single record
controller, with or without extensions.
48. Custom Buttons and Links
• They can navigate to any VF page.
• Can be added to page layouts.
• Need to be defined on the database object.
• Go to App Setup area, click Create -> Objects,
and then click the object. Scroll to the Custom
Buttons and Links area and click the New
button.
• Can be added to the detail page layout or
related list page layout.
49. Custom Tab
• You can configure any Visualforce page as a
new tab in the Force.com native UI.
• To add a new Visualforce tab, go to the App
Setup area and click Create ->Tabs.
• Click the New button in the Visualforce Tabs
section to create a tab.
• Select a Visualforce page, select a tab label
and style, set tab visibility on profiles and
applications, and click Save.
50. Debugging and Tuning
• Look at the System log first.
• Add System.debug statements in controller.
• Trial & Error – comment out portions of VF page
till you can narrow the error.
• Use Firebug to find client side errors.
• View State is limited to 128k. View State contains
the local variables in the controller.
• Reduce local variables and/or mark some of them
as transient.
51. Visualforce Security
• Obeys the object and field level security
configured in profiles.
• Access to the page itself is granted by user’s
profile.
• Record security handled by controller through
special keywords in Apex.
52. Developer Notes – VF Security
• When developing a controller, check that the
SOQL, SOSL, and DML operations are fully
compatible with the set of profiles expected to
use the page.
• A developer has full visibility to every object and
field, but do not assume that other users have
the same level of access. Test the Visualforce
pages by logging in as a test user or cycling
through profiles on a single test user.
• Write unit tests that run under the privileges of a
specific user using the System.runAs method.
53. Record Level Security
• Standard controllers always honor the record-level
security of the current user.
• Record sharing rules are ignored by code in
custom controllers. These controllers run in a
system context, like a trigger.
• Record sharing rules are honored by the
methods of standard controllers that have
extensions defined, but the code in an
extension class itself still runs in system mode.
54. Record Sharing – Custom Controllers
• Two security modes are available: with
sharing and without sharing.
• Without Sharing is default mode.
• Example of with sharing:
public with sharing class MyController {
// the code in this controller honors record sharing rules
}
55. Page Level Security
• Pages must be explicitly enabled for each profile that
requires access. If this is not done, users will receive an
error page titled Insufficient Privileges when attempting to
view the page.
• To grant a profile access to a page, go to the Administration
Setup and click Manage Users ➝ Profiles. Scroll to the
Enabled Visualforce Page Access section and click the Edit
button. Select pages from the Available Visualforce Pages
list and click the Add button to add them to the Enabled
Visualforce Pages list. Click Save.
• Users with the Customize Application permission can
access all Visualforce pages in the organization.
56. Uncaught Exceptions
• In triggers, good formatted message is shown.
• In VF page, generic error page whose appearance
cannot be controlled or customized.
• Goals of error handling in VF pages – avoid
uncaught exceptions.
• Place a try/catch block around every action
method, or at least those that perform SOSL,
SOQL, or DML operations.
• Catch all exceptions and rollback the transaction
using a savepoint in the controller method.
57. Error Communication
• VF provides page components and corresponding data objects for
communicating errors to the user in a consistent way.
• The page components are messages and pageMessages, which
display the page-level errors returned by a controller.
• These components are placed on pages, typically at the top, and
render the ApexPages.Message objects added to the page.
• Message objects contain a message and optional severity.
• Severity is used to style the message when displayed in the
pageMessages component and can also be filtered on in test
methods.
• Example of code to add an error-severity message to the page. To
be visible, it must be rendered by a messages or pageMessages
component.
ApexPages.addMessage(new ApexPages.Message(
ApexPages.Severity.ERROR, 'Something went wrong'));
58. Governor Limits
• Apply during execution of user-initiated actions and are
not cumulative. When an action is complete, the
governor limits reset.
• Heap => 3MB.
• Apex code => 200,000 lines of code executed.
• SOQL => 100 queries.
• Records from SOQL => 50,000 records cumulatively for
all SOQL queries.
• DML => 150 DML statements.
• Records in DML => 10,000 records cumulatively for all
DML statements.