IntroductionWelcome | 00:03 | Hi! I am Gini Courter, and I'd like
to welcome you to InfoPath 2010
| | 00:08 | Essential Training.
| | 00:09 | In this course, I will show you how to
use Microsoft InfoPath Designer to create
| | 00:13 | powerful forms that are easy to use.
| | 00:16 | The templates we build will be strong
templates that won't waste users' time
| | 00:20 | skipping over sections they don't need,
| | 00:22 | templates that use rules to validate
the data our users enter against schemas
| | 00:28 | that we will create as we build our forms.
| | 00:30 | InfoPath contains over 30 controls, so we can
provide our users with a rich user experience.
| | 00:38 | Many organizations use InfoPath
exclusively with SharePoint, so you will learn
| | 00:42 | how to publish your form in a SharePoint
Library so users can fill it out using a browser.
| | 00:48 | Whether you are new to InfoPath forms
or have some experience but want a more
| | 00:52 | structured way to think about form
development, I am going to provide you with
| | 00:57 | an in-depth look at how to use
Microsoft InfoPath Designer 2010 to create forms
| | 01:03 | that create business solutions.
| | 01:05 | Let's get going.
| | Collapse this transcript |
| What you can do with InfoPath| 00:00 | If you're new to InfoPath form
development, it's helpful to think about what you
| | 00:05 | can do with InfoPath before you
jump in and begin creating forms.
| | 00:09 | While some of us create forms that
we will use, most of us create InfoPath
| | 00:14 | forms for others to use.
| | 00:16 | So before I jump in and say, "What can
InfoPath do for me?" it's helpful to think,
| | 00:20 | what can InfoPath do for my users?
| | 00:23 | Onscreen you're seeing a form that we
actually create in this course, so we'll
| | 00:28 | be creating the Web Post Express
Request and a more detailed request form, and
| | 00:33 | it's just a beautiful form, and this
is the user experience of this form.
| | 00:38 | If they're using the InfoPath Filler,
they have the ability to type text and
| | 00:42 | make sure that they do.
| | 00:43 | So we're doing some basic validation
to choose dates using date pickers, to
| | 00:49 | choose departments from dropdown lists,
to say actually, I want to enter a whole
| | 00:53 | new section in this form, and
insert or delete optional sections.
| | 00:58 | So it's a good-looking form.
| | 01:00 | It's a form that works amazingly well,
that allows users to enters hyperlinks,
| | 01:06 | allows them to attach files, a powerful form.
| | 01:09 | So assuming your users actually want to
provide some data to someone else, this
| | 01:13 | form creates a great mechanism for that.
| | 01:16 | But when you look at the user community
as a whole, there is even more than great
| | 01:21 | form creation available
because they use InfoPath.
| | 01:25 | We already know that users get the right
to fill out a form, but one of the more
| | 01:29 | amazing things is that they don't now
have to print, put it in an envelope for
| | 01:33 | inter-office mail, and send it around.
| | 01:35 | They can actually choose to click the
Submit button, and based on how you've
| | 01:39 | developed the form, have it emailed to
one or more people, to a distribution
| | 01:44 | list, or to post box in Microsoft Exchange.
| | 01:48 | They can submit it to a SharePoint library.
| | 01:51 | They can submit it to a database that
you have provided a connection to, and
| | 01:55 | there are other methods as well.
| | 01:57 | And then finally, that user or another
group of users will have the ability to
| | 02:02 | aggregate form data and do some
analysis if you've used SharePoint as your form-
| | 02:08 | publishing location.
| | 02:10 | So the user community gets to fill out
forms and analyze data, something that
| | 02:15 | they can't easily do in a
form created in Excel or in Word.
| | 02:19 | So what can you do with
Microsoft InfoPath as a developer?
| | 02:24 | Let's go behind the scenes of this form.
| | 02:26 | Then what we see is the design view of the
form that the user was filling out a moment ago.
| | 02:32 | You get to specify the kind of data
that goes into this form, and in doing so,
| | 02:36 | you are creating an XML schema.
| | 02:39 | You get to choose controls for users to
enter data and add rules that indicate
| | 02:45 | how the form will behave when users
omit data or make particular choices.
| | 02:50 | You get to format the form, and you get
to determine its data connections, how the
| | 02:54 | form will be submitted and where it
will go, what kind of external data is
| | 02:59 | available to the form.
| | 03:01 | Finally, not included in this course,
but in your development future potentially,
| | 03:05 | you can actually write some
custom code that this form would use.
| | 03:10 | Before you start developing forms, there
are two broad classifications of forms
| | 03:14 | in InfoPath. You can create forms
that will be completed in a browser.
| | 03:19 | These forms require SharePoint running
InfoPath form services, but this is how
| | 03:25 | many InfoPath forms are
used in enterprises right now.
| | 03:29 | When you create then that browser form
hosted by SharePoint Server, it could be a
| | 03:34 | form that is published and
returns data to a SharePoint library.
| | 03:38 | It could be a more specialized form
that is simply the front end or user
| | 03:43 | interface to a SharePoint list.
| | 03:45 | You could also embed a Microsoft
InfoPath form into a web page in SharePoint.
| | 03:52 | Those are the kinds of things that you
can do. Notice that browser forms though
| | 03:55 | are SharePoint-centric.
| | 03:57 | You can also create a form that is
going to be filled out by somebody using
| | 04:01 | the InfoPath Filler client, in 2010, or even
in 2007, or InfoPath 2003 for that matter.
| | 04:11 | The Filler form could be a form that
we intend to distribute using email, or
| | 04:17 | save on a network share and then email
to users. Or we could have that Filler
| | 04:23 | form be a form that is actually
completed on a SharePoint site.
| | 04:27 | You might wonder why we do that.
Well, there are more controls that InfoPath can
| | 04:32 | host than that a browser can host.
| | 04:35 | So we can create some specialized
forms using the Form Filler client that
| | 04:41 | wouldn't be available in a browser.
And if every person in our enterprise has
| | 04:46 | InfoPath Filler on their computer, they
can open those from a SharePoint site
| | 04:50 | just as easily as they can open them in email.
| | 04:53 | SharePoint is what gives us the ability
to aggregate information that come out
| | 04:57 | of multiple forms created in InfoPath.
| | 05:00 | So, Microsoft InfoPath Designer 2010 is
a powerful design tool, allowing you to
| | 05:07 | connect to a wide range of data sources,
to design specifically themed form
| | 05:13 | document, provide different views for
different numbers of your user group,
| | 05:19 | and use a rich array of controls to
capture data and to present choices and
| | 05:24 | options to your users.
| | 05:26 | Microsoft InfoPath Designer isn't
just a tool to create the most amazing
| | 05:31 | forms you've ever made;
| | 05:33 | it's a tool to help you
create business solutions.
| | Collapse this transcript |
| Using the exercise files | 00:00 | If you are a Premium member of the
lynda.com Online Training Library, or if you
| | 00:05 | are watching this tutorial on a DVD-ROM,
you have access to the exercise files
| | 00:10 | used throughout this title.
| | 00:12 | All of the exercise files are in one
folder called Exercise Files, and if you
| | 00:17 | double-click, you'll notice that there
is a folder for each chapter, followed by
| | 00:23 | two folders, named Materials and Source Files.
| | 00:26 | When you're working in a chapter, you
will open up that chapter's folder and
| | 00:31 | find there the template files that
we're using, or in some cases additional
| | 00:36 | files, such as an XML file that you'll find
here, that are used specifically in that chapter.
| | 00:43 | There are a couple of logos that we
use in forms, and so both of those are in
| | 00:48 | the Materials folder.
| | 00:50 | You can use this one when I
do or this one if you choose.
| | 00:54 | You can also choose to use
your own logo file if you wish.
| | 00:58 | The Source Files folder is empty.
Later in the course, we will be taking the
| | 01:02 | source files that are used to create
an InfoPath template and unpacking them.
| | 01:07 | It's a number of files, about a dozen, and
the Source Files folder will give you a
| | 01:12 | place to put those, so that they're
not scattered about someplace else.
| | 01:16 | For any movie, you'll see a banner that
will scroll across the screen and tell
| | 01:20 | you what file I have opened for that movie.
| | 01:23 | If you want to work along with me,
simply go ahead, open that folder, and
| | 01:28 | open the same file.
| | 01:30 | If you're a Monthly subscriber or Annual
subscriber to lynda.com, you don't have
| | 01:35 | access to the exercise files, but you
can follow along. We build each one of
| | 01:41 | these forms from scratch,
| | 01:42 | so it's easy enough for you to begin
when I do and create the form, saving
| | 01:47 | it after each movie.
| | 01:48 | Let's get started.
| | Collapse this transcript |
|
|
1. Introducing InfoPath 2010Understanding the InfoPath 2010 programs| 00:00 | In Microsoft Office 2010, there
are two separate InfoPath programs.
| | 00:05 | They do two different things. One
is the InfoPath Filler; the second is
| | 00:10 | the InfoPath Designer.
| | 00:12 | The InfoPath Filler which you see
here is used simply to fill in forms.
| | 00:16 | That's all it does.
| | 00:17 | It's a ribbon with two tabs and not a
lot going on here. But for people who want
| | 00:22 | to complete InfoPath forms and have a
rich client experience, this is a really
| | 00:28 | great place to do it, so the user
can simply type information in.
| | 00:32 | I know that, for example, that I can't
format because there is nothing turned on
| | 00:35 | that allows me to format.
| | 00:37 | So I could say that this is an agenda
for a finance group meeting. And as I tab,
| | 00:43 | I will tab through the controls that
are here on the form, using familiar
| | 00:46 | controls like the date picker, rich text
boxes where all of my formatting tools
| | 00:52 | come on, and other types of
controls that I use in Microsoft InfoPath.
| | 00:58 | When I'm done with the form,
I can simply click Save.
| | 01:01 | If it's going to a particular location,
for example a SharePoint site or being
| | 01:06 | returned by email, I can click the Submit button.
| | 01:09 | This is the limit of what I
can do in the InfoPath Filler;
| | 01:12 | just what it says, fill in a form.
| | 01:15 | The InfoPath Designer, on the
other hand, is used to create forms.
| | 01:20 | Here is the form that we were just
filling out in Design mode where we created it.
| | 01:24 | We have a lot of tools here at our disposal.
| | 01:27 | We can look at the fields on the form.
| | 01:29 | We can insert any item you want, design
pages, connect this form to a particular
| | 01:35 | data source, and change the language--
other things that one might choose to do
| | 01:40 | as a developer with an InfoPath Form.
| | 01:43 | So when you go to your Start menu and
you choose Microsoft Office, if you have
| | 01:50 | only the InfoPath Filler then you're
pretty much done with this course because
| | 01:54 | this is a course about the InfoPath
Designer, where we will be creating powerful forms.
| | 01:59 | If you don't yet have the InfoPath
Designer, go ahead and make sure it's
| | 02:02 | installed so that you can join us in design.
| | Collapse this transcript |
| Starting InfoPath Designer 2010| 00:00 | We're ready to create a new form
template, so let's start InfoPath Designer.
| | 00:05 | I'm going to click the Start button,
go to All Programs, and go to Microsoft
| | 00:12 | Office, and I'll find
the InfoPath Designer here.
| | 00:15 | I'll also find the Filler
here, which you also know about.
| | 00:18 | I'm going to be using the Designer a lot,
so I'm going to actually right-click
| | 00:22 | and pin this to my Start menu right now.
And that means the next time I click
| | 00:27 | the Start button, it will appear right here.
| | 00:30 | When you start Microsoft InfoPath
Designer, you end up being in the equivalent
| | 00:34 | of a backstage view.
| | 00:36 | You can open an existing template.
| | 00:40 | You can go to your list of recent
templates, if you had any, but we're going to
| | 00:44 | choose a new template.
| | 00:45 | These are arranged in different sections:
Popular, Advanced, InfoPath 2007 Form
| | 00:52 | Templates, and Template Parts.
| | 00:54 | The Popular types of form templates
start with SharePoint List, then SharePoint
| | 00:59 | Form Library, E-Mail, Blank Form,
and Blank Form InfoPath Filler.
| | 01:04 | Let's dispense with these
first two types right away.
| | 01:08 | If you have a SharePoint list and
people want to add items to it in SharePoint,
| | 01:13 | then there is a form that SharePoint provides.
| | 01:16 | Using InfoPath 2010's new functionality,
you can create a new form to replace
| | 01:23 | that form for that SharePoint list.
| | 01:25 | If I choose SharePoint List, I will
immediately be asked what list I want to put
| | 01:30 | this in. And here I go, where is the
location of my SharePoint site? So I have to
| | 01:35 | be ready to go on that.
| | 01:36 | If I know that I want to create a
template and save it in a SharePoint form
| | 01:42 | library as the way that I distribute it,
I can start by saying, well, let me
| | 01:47 | start with my existing library.
| | 01:49 | Again, when I double-click, I'll
immediately go into a form, but it knows that it
| | 01:53 | is going to a SharePoint form
library. But I don't need to do this way.
| | 01:58 | I can actually close this
and start another new form.
| | 02:02 | The same thing is true with email.
| | 02:04 | I can say, I know I'm willing to
distribute this by email, but note that
| | 02:09 | SharePoint List is a connection to
an existing list, whereas SharePoint
| | 02:13 | Form Library and E-mail are distribution
methods for a form that you're going to create.
| | 02:19 | The two major types of popular
form templates are right here;
| | 02:23 | Blank Form, which you could read in
parentheses 'web browser' underneath, or Blank
| | 02:29 | Form (InfoPath Filler).
| | 02:31 | If I create a form using the InfoPath
Filler then I will again be taken into
| | 02:37 | an area where I can begin designing
the form. And while we haven't talked
| | 02:40 | about this yet, there is a list of
controls that are available that's very
| | 02:45 | extensive and that includes a few
controls--three here and a few more here--
| | 02:51 | that the web can't support;
| | 02:53 | therefore, they only show up when
you choose InfoPath Form Filler.
| | 02:58 | It's an entire list of controls,
some of which are controls or containers
| | 03:02 | that hold other controls, like scrolling regions,
or ink picture controls for tablet PC users.
| | 03:09 | Therefore, if I know that I'm going to
create a form that is most likely to end
| | 03:14 | up on the web, I don't want
to use any of those controls.
| | 03:18 | So my most generous, least restrictive
way to create a form is by choosing Blank
| | 03:24 | Form, which then I could have completed
in a browser, or with InfoPath Filler, in
| | 03:31 | which I could distribute by email,
by saving it in a network share, or by
| | 03:37 | posting it in a SharePoint form library.
| | 03:40 | The only thing here that I can't
easily do with a blank form is to choose to
| | 03:45 | make it the front-end for a SharePoint list.
| | 03:47 | So I will most often here choose Blank Form.
| | 03:51 | The Advanced Form Templates allow us to
create templates in some different ways.
| | 03:55 | In the same way that I can say I'd like
to create a form that is the front end,
| | 04:00 | the user experience, for a SharePoint
list, I can create a form that's the user
| | 04:05 | experience for a SQL Server database, or
a web service that's been created, for
| | 04:10 | example, a SOAP web service that
connects to any kind of a dataset.
| | 04:15 | I can also create a Document
Information panel, again that will be used as
| | 04:20 | the way people enter and view information
about documents in a SharePoint Document Library.
| | 04:26 | I can convert--perhaps well, perhaps
not so well--an existing form that I have
| | 04:31 | in Excel or in Word.
| | 04:34 | In either case, I'm going to get
at least the form's structure, the
| | 04:38 | physicality of the form.
| | 04:40 | If I want to have places for users to
enter data, I might have to rebuild that
| | 04:45 | part of the form, but I will get a
start with the Word or Excel form only.
| | 04:49 | In the same way that my IT department
might have a web service to connect to
| | 04:53 | SharePoint, they might give me a data
connection file to connect to something
| | 04:57 | like SQL Server, and finally I can use
an existing XML file or a schema, which is
| | 05:03 | a data description for an XML file, to
create a new form that I would either use
| | 05:09 | to view some existing XML
or to view and add to it.
| | 05:14 | I could also develop
InfoPath 2007 form templates.
| | 05:18 | I will give up some functionality in either
case, and you might wonder why this is here.
| | 05:23 | The new controls that have been added
to InfoPath 2010 actually require a newer
| | 05:30 | version of SharePoint as well, SharePoint 2010.
| | 05:33 | So if you know you are running on, for
example, SharePoint MOSS server, Microsoft
| | 05:39 | Office SharePoint server, you might
choose to develop using the blank 2007 form
| | 05:45 | so that the functionality
that you have will match up;
| | 05:48 | but mostly you can, again,
simply choose Blank Form.
| | 05:52 | The last section here allows us to
start with an XML schema, or with nothing,
| | 05:57 | and create a reusable template part,
either for web forms or for the InfoPath Filler.
| | 06:03 | So if I choose Template Parts, I can
create reusable building blocks, reusable
| | 06:08 | form sections, that I can use in all of
my forms or some of my forms, and I'll
| | 06:13 | be allowed to add those to our
control list so I can easily get to them.
| | 06:18 | So a typical address block, for example,
or at the bottom, of a block that shows
| | 06:23 | how the work has been completed,
that 'for office use only' block.
| | 06:27 | If you have sections like that that
appear on multiple forms, go ahead and save
| | 06:31 | them as template parts.
| | 06:32 | Regardless of which of these options
you choose, you can simply select and then
| | 06:36 | click Design Form, or double-click, to
jump in to Microsoft InfoPath Designer and
| | 06:42 | begin building your form.
| | Collapse this transcript |
| Using the InfoPath Designer interface| 00:00 | Welcome to the Microsoft InfoPath Designer 2010.
| | 00:04 | This designer is built with the same interface
that you see in other Office 2010 applications.
| | 00:10 | We have our familiar Ribbon here and
we have a Task pane that you'll see far
| | 00:14 | more often here than you do,
for example, in Word or in Excel.
| | 00:19 | So let's take a look at the interface
and see what we've got going on here.
| | 00:22 | First, whenever we choose a document
type, we come in and there is a blank form
| | 00:26 | that may have a little something going on here.
| | 00:29 | The tabs aren't necessarily arranged in
order, and I will tell you that to begin with.
| | 00:34 | For example, we would often, if not
always, want to begin on the Page Design
| | 00:39 | tab, rather than the Home tab,
because this is where we find templates and
| | 00:44 | themes, that sort of thing.
| | 00:46 | But aside from the order, what you
will find is a really nice set of tools.
| | 00:51 | For example, here are our text formatting tools.
| | 00:55 | We have a relatively short
style list, but it works.
| | 00:59 | Then we have controls that we will use
as containers in our form to allow our
| | 01:04 | users to enter data, to enter rich text,
to check a check box, to use a dropdown
| | 01:10 | list, to select an Option button.
| | 01:13 | Then we have rules that are used to
change values in a form, change formatting
| | 01:18 | in a form, based on the value in a field,
| | 01:20 | Spelling, Find, Select All, the Editing
tools that we're familiar with from Word
| | 01:25 | or Excel, and then finally, Preview, which
lets us see how the form will look when
| | 01:30 | it is filled out in the InfoPath Filler.
| | 01:33 | On the Insert tab, you'll find tables.
| | 01:36 | InfoPath relies on layout tables.
| | 01:39 | You'll also find the ability to insert objects.
| | 01:42 | This is how we would insert a picture,
some clip art, a hyperlink, a page break,
| | 01:47 | horizontal line, or a Symbol.
| | 01:50 | On the Page Design tab, which I
mentioned already, we will be able to choose
| | 01:54 | themes and layout tables,
but we will also create views.
| | 01:57 | A view is one way to look at data, so
we might have a view that includes the
| | 02:02 | information the accounting
department needs to process a form.
| | 02:05 | So we might have two views: one,
a view that the user would fill out, and
| | 02:11 | second, a view that was only seen by the
accounting department when they processed the form.
| | 02:17 | Our fifth tab here is the
Data tab, and it's very powerful.
| | 02:20 | This form is not yet
connected to any data source.
| | 02:24 | InfoPath has no idea what I'll want to
do with the data collected in this form.
| | 02:29 | So I have the ability to go get data
from a wide range of places and then to
| | 02:35 | have the data that the user enters be
placed in a SharePoint library, mailed
| | 02:41 | back to me, saved in another location.
| | 02:44 | On the Developer tab, you have the
ability to load COM add-ins, and to do some
| | 02:50 | basic code editing. We won't be working
with code in this course. And because
| | 02:54 | I'm in a table, I see the Table Tools > Layout tab,
which is very powerful here, as it is in Word.
| | 03:01 | You'll work with tables here more than
you do in most other applications, so
| | 03:05 | you'll get very familiar with the Table tools.
| | 03:07 | Finally, if I return here to File, I'm
in Microsoft InfoPath's Backstage View,
| | 03:14 | which lets me see the properties of my
template and some statistics about it,
| | 03:18 | but also allows me to publish my form,
to specify how users will return the form
| | 03:24 | and its data to me, or to
someone else, to check the design.
| | 03:29 | Design Checker here is not about
accessibility; Design Checker here checks to
| | 03:34 | see if this form, as it stands, could be
published and opened and completed in a browser.
| | 03:39 | Then finally, there are some Advanced
form options, which we will be studying
| | 03:43 | later to configure the user
experience with this form.
| | 03:47 | I'm going to return to Home.
| | 03:49 | Now that we've seen how Microsoft
InfoPath Designer's interface works, we're
| | 03:54 | going to take a look at the steps
that we'll use to create a brand-new form
| | 03:59 | from scratch.
| | Collapse this transcript |
|
|
2. The Basics of Template CreationCreating a template from scratch| 00:01 | Before we jump into the InfoPath
Designer, let's take a look at the steps that
| | 00:05 | we need to follow to
create a template in InfoPath.
| | 00:09 | First we need to connect to a data source.
| | 00:12 | You'll recall that as soon as we launch
the InfoPath Designer, InfoPath started
| | 00:16 | asking us, what kind of
data do you want to use here?
| | 00:20 | If we want to create a form to put
data into a SharePoint list then we
| | 00:25 | should choose that now.
| | 00:26 | The same is true if we want to
connect to a database, web service, XML or
| | 00:31 | schema, or a data connection file.
| | 00:34 | If we don't have a data source, that's fine.
| | 00:36 | We can create the data
source as we create our form.
| | 00:40 | When we're done, we can publish that to,
for example, a SharePoint form library
| | 00:44 | and store our data in SharePoint.
| | 00:46 | But if we have a data source,
we should choose it upfront.
| | 00:50 | It's a lot easier than
trying to match up to it later.
| | 00:53 | Once we either have a data source or
know that we'll be creating one, we can
| | 00:57 | then begin to look at the layout of our form.
| | 01:00 | The tools that we'll use for layout
are the familiar table tools that you may
| | 01:03 | have used to lay out web pages or
forms in something like Microsoft Word.
| | 01:09 | The InfoPath Designer has Page Layout
templates, a few of them that we can use
| | 01:14 | as a head start to be able to do layout.
| | 01:16 | So as you think about the form, if you
have an existing manual form, you already
| | 01:21 | have a template that might
give you a look and feel.
| | 01:24 | But you might also decide that you
want to do something totally different.
| | 01:28 | There are a number of different choices here.
| | 01:31 | Here's a title and body, which we've
already seen, but then there's also, for
| | 01:34 | example, titles with headings.
| | 01:36 | We can drop all kinds of controls
into these to make them operate the way
| | 01:40 | we would like them to.
| | 01:41 | Layout is a continuing task.
| | 01:43 | You begin by laying out part of the
form, and then you lay out new sections as
| | 01:47 | you work your way down the form.
| | 01:49 | We'll then add controls to our form, and we
have a fabulous set of controls to choose from.
| | 01:55 | We have text boxes.
| | 01:57 | We have combo boxes.
| | 01:59 | We have a date picker that allows the
user to simply choose from a calendar,
| | 02:03 | rich text boxes which are heavily
formatable, check box controls, and option
| | 02:08 | buttons for singular choices,
| | 02:11 | a new time and date picker, which
allows a user to type a date and a time or
| | 02:16 | choose a date from a calendar display.
| | 02:18 | We have multiple-selection list boxes,
regular list boxes, bullet list, numbered lists.
| | 02:23 | I told you it's a rich group of controls.
| | 02:26 | A person/group picker for a form
that's connected to a SharePoint List
| | 02:31 | that includes users.
| | 02:32 | Then we have the ability to insert
pictures, to calculate values, to insert
| | 02:36 | hyperlinks and attach files,
and finally a simple button that allows a user to
| | 02:41 | initiate some kind of an action.
| | 02:44 | All of these will go within layout
tables and then within containers, and the
| | 02:49 | containers are one of the most
powerful control sets in InfoPath.
| | 02:53 | For example, if you were creating a
form in Word or Excel for something like
| | 02:58 | travel expense and you didn't know how
many trips an average user would take,
| | 03:03 | you'd have to go find out, and then
someone would say, well, you know sometimes
| | 03:07 | they'll need 10 rows in there,
but I've seen people need 20 or 30.
| | 03:11 | And there you are, stuck with creating
a really big form with 20 or 30 rows
| | 03:15 | when some users will only use one or two.
| | 03:19 | In InfoPath, you simply create one row
of the table and tell the form that it
| | 03:24 | can repeat that row.
| | 03:26 | The same thing is true with sections
that repeat, where you can say this group of
| | 03:30 | controls where a user enters information,
| | 03:32 | if they want to do it again, let
them repeat this entire section.
| | 03:37 | We also have the ability to have a
section that only opens if the user needs it,
| | 03:42 | so they would click and enter more information.
| | 03:45 | But it wouldn't appear unless we needed it.
| | 03:48 | Then two sets of controls, a group and
a section, that allow the user to choose
| | 03:54 | from two different options, or three
different options to place in the form.
| | 03:58 | So the user might start with all of the
information that was needed if they were
| | 04:02 | filling out the form for a business in Michigan.
| | 04:05 | But since they're a business in California,
they simply choose the Choice Group and
| | 04:09 | choose the appropriate group of
controls to place for the information that
| | 04:12 | they need to enter.
| | 04:14 | Very flexible, very powerful, and
we're going to spend a lot of time in this
| | 04:17 | course looking at the uses
for these incredible controls.
| | 04:22 | With the controls in place,
then we begin to design views.
| | 04:25 | Views are very simple to understand.
| | 04:28 | You create a form, and then you create
a subset of the form that some subset
| | 04:34 | of users gets to see.
| | 04:35 | For example, I might create a form
that at the bottom has an area that says
| | 04:40 | 'for office use only'.
| | 04:42 | But why does the person
filling it out even need to see that?
| | 04:45 | So I can create a user view that's
the default view that everybody sees who
| | 04:49 | completes the form, and then a special
office-use view that will only be visible
| | 04:54 | to the people who want to actually fill
out those fields at the bottom that are
| | 04:58 | usually in gray in a form.
| | 05:00 | I also have the ability to create a separate
print view for each of the views that I make.
| | 05:06 | So I can have a view that allows
users to print all or part of the
| | 05:11 | information in my form.
| | 05:13 | Views are very powerful and users can
switch between them with a great deal of
| | 05:17 | ease in the InfoPath Filler.
| | 05:19 | If I'm going to publish my form in
such a way that it would be opened in a
| | 05:23 | browser, for example in SharePoint or
even on a shared network location, I'll
| | 05:29 | use the Design Checker to make sure
that all of the features that I've used are
| | 05:33 | supported by browsers.
| | 05:35 | Some of the controls that I showed you
earlier can't be rendered in browsers.
| | 05:39 | You've never seen them on the
Internet, and there is a reason for that.
| | 05:42 | So the Design Checker goes through
your form and says, ah, this control, not
| | 05:47 | going to work, you'll need to replace it.
| | 05:50 | When we're all done then the final
steps are a set of tasks that we'll do to be
| | 05:54 | able to publish our form template.
| | 05:56 | We'll need to tell Microsoft InfoPath
where the data that's collected in this
| | 06:01 | form will be put when a user submits it.
| | 06:03 | We can set where other
data in the form comes from.
| | 06:06 | We can indicate how the form is going
to be submitted on a published event.
| | 06:11 | Then we need to go through a list of
choices that we make when we're ready to
| | 06:14 | publish our form template.
| | 06:16 | There are a number of details that
we have to clean up here, for example,
| | 06:20 | indicating where data in the form
should go when a user clicks Submit,
| | 06:24 | whether it should be returned by
email or posted to a SharePoint site.
| | 06:27 | We'll also want to determine a
particular publishing method;
| | 06:31 | are we publishing it on a network share in
SharePoint? Are we sending this form by email?
| | 06:37 | So those are the kind of publishing
choices that we'll need to make when we're
| | 06:40 | done with our InfoPath template design.
| | 06:43 | This is the series of steps that we
will go through every single time we
| | 06:46 | create an InfoPath form.
| | 06:48 | We'll begin with a data source, put
together a layout, add controls, and we'll do
| | 06:53 | the layout and controls interactively.
| | 06:55 | One, first layout then controls,
then layout and controls as we work our
| | 06:59 | way through the form.
| | 07:00 | When the form is mostly finished,
we'll design our views, check our design,
| | 07:05 | and then we'll publish.
| | 07:06 | You'll get used to this series of steps.
| | 07:08 | It's really easy once we get going in InfoPath.
| | Collapse this transcript |
| Previewing and printing a form| 00:01 | When you're working in the InfoPath
Designer, you have a different experience
| | 00:05 | of the form than your user will have,
because you're seeing actual controls,
| | 00:11 | but not as they'll work when the user is
tabbing through them and actually using them.
| | 00:15 | So a dropdown list doesn't drop down
in the Designer. The Date Picker doesn't
| | 00:20 | open a calendar in the Designer.
| | 00:22 | In order to see what the user experience
looks like, you have two different choices.
| | 00:26 | One choice will be that as you're
working through your template, designing
| | 00:30 | it, you could open up the InfoPath
Filler and open your saved form to see
| | 00:34 | what it looks like.
| | 00:35 | But there is a shortcut to
this process here in the Designer.
| | 00:38 | On the Home tab at the far right, we
have Preview, and when you click Preview
| | 00:43 | you see exactly what this form
will look like in the InfoPath Filler.
| | 00:47 | You can try out all the controls.
| | 00:49 | You can click the date pickers.
| | 00:51 | You can click on the
repeating table, and insert new rows.
| | 00:56 | You can check and uncheck text boxes.
| | 00:58 | You can type information
and tab from field to field.
| | 01:02 | So you really see what the user
experience will be like in the Form Filler,
| | 01:07 | checking on each of the
controls and seeing how they work.
| | 01:10 | When you're all done, simply close
Preview and you return to the Designer.
| | 01:15 | So again Preview to view the form. Notice
all of my data is gone, except my default data.
| | 01:22 | The Preview simply opens a session of
the Filler, lets me play with it, and then
| | 01:26 | throws my data away when I close the Preview.
| | 01:30 | I might also want to print a form to
see what it looks like, or Print Preview to
| | 01:34 | see without wasting paper or killing trees.
| | 01:37 | I'm going to click File and then choose
Print to either print or print preview,
| | 01:42 | and notice here's my print preview that
allows me to see what it will look like.
| | 01:47 | I have some basic controls to zoom in and out.
| | 01:50 | I also have a Quick Print button, which
will print one copy to my default printer
| | 01:55 | using its default settings.
| | 01:57 | If I want to print copies of the
form to distribute, for example at a
| | 02:01 | design meeting where I am discussing
the form with the people who I'm creating
| | 02:05 | it for, I can choose File > Print and
set a particular number of copies, because
| | 02:10 | this will open the Print dialog box
so that I can choose a printer, set its
| | 02:14 | properties, set a number of
copies, number of pages, and so on.
| | 02:18 | You print or print preview as you would
expect to as you do in Word or Excel, and
| | 02:23 | you preview the form from the point of
view of the user experience by clicking
| | 02:27 | the Preview button on
the Home tab of the Ribbon.
| | Collapse this transcript |
| Saving a template| 00:01 | When you're ready to save your template,
you'll click File and choose Save or
| | 00:05 | Save As, if you saved it before
and want to put it somewhere else.
| | 00:09 | There are several choices, several
different ways you can save this template.
| | 00:13 | The default is based on the choice you made
when you decided to create a new template.
| | 00:19 | So if you had chosen an InfoPath 2007
Filler template, this would be the default here.
| | 00:25 | Because this form started with an
InfoPath 2010 Filler template, that's the
| | 00:31 | default choice, but you can make
another choice here anytime you wish.
| | 00:35 | If I choose one of the 2007 choices,
some of my tool choices will go away the
| | 00:40 | next time open this in the Designer.
| | 00:42 | The same thing is true if I choose to
save this in 2003, because the earlier
| | 00:47 | versions of Microsoft InfoPath did not
have as many controls available to them.
| | 00:51 | You'll also notice that in
InfoPath 2003 there is only one choice.
| | 00:57 | There was no Web Browser Form Template.
| | 00:59 | This will need to be filled out
using InfoPath 2003, which had only one
| | 01:04 | application, used both to
design and to fill in forms.
| | 01:08 | So choose a location, either keep the
default or choose a new way to save this,
| | 01:13 | and click Save to save your template.
| | Collapse this transcript |
|
|
3. Creating a Data SourceUnderstanding data sources| 00:01 | When we switch to the Data tab in
InfoPath Designer, it becomes very apparent
| | 00:06 | that data is important when we're
working with this application to create forms.
| | 00:11 | Every form is based on a
description of data that the user will enter.
| | 00:16 | Here is the description for this form,
four simple fields, an IdeaTitle, a
| | 00:21 | FirstName, a LastName, and
a referring PartnerName.
| | 00:25 | The data in this form will be stored
in one location when we're all done.
| | 00:30 | Let's go take a look at that
location for just a moment.
| | 00:33 | Every time someone fills out this form
and saves it or submits it, it's stored
| | 00:38 | onto the SharePoint site.
| | 00:40 | So we can see that there is already
an existing form that was placed here.
| | 00:45 | The fields that are going to be
saved are the fields that we see here in
| | 00:49 | the main data source.
| | 00:50 | But this form also gets data from SharePoint.
| | 00:54 | Let's take a look at how
this dropdown list works.
| | 00:59 | This dropdown list is a list of
partners who have agreed to work on referring
| | 01:04 | new ideas, and when we click, it
pulls up a list with three names on it.
| | 01:08 | Let's go and see where
those three names come from.
| | 01:13 | Back in SharePoint, in the Partners
list you'll see those three people.
| | 01:17 | The reason that we created the form
this way is we want to easily be able
| | 01:21 | to expand that list.
| | 01:22 | As more and more partners join this
effort, we'll simply add their names here.
| | 01:27 | Each time in the form that the user
opens this dropdown, they'll see the current
| | 01:32 | list of partners from the SharePoint site.
| | 01:36 | When we look at the form then, we have
data that's incoming here and data that's
| | 01:41 | stored, including the
incoming data back in SharePoint.
| | 01:45 | This isn't unusual, because Microsoft
InfoPath allows us to get external data,
| | 01:51 | the kind of data we have in this
dropdown, from a wide range of sources:
| | 01:55 | a web service, a SharePoint List like
we're currently using, data stored in
| | 02:00 | another way on a SharePoint server, or
from a wide range of other sources, almost
| | 02:05 | any database and any XML file.
| | 02:08 | When a user enters data in the form, we
can then send that data to someone else
| | 02:13 | or somewhere else by returning it
in an email, by saving it, as in this
| | 02:19 | demonstration, in a SharePoint library,
| | 02:22 | by sending it to a web service, so it
would ultimately end up in a database,
| | 02:27 | or sending it to a SharePoint Server
Connection, another type of database connection.
| | 02:33 | So we have many different options for
getting external data into our form, like
| | 02:38 | this dropdown list, and many ways to submit it.
| | 02:42 | There is one difference.
| | 02:43 | I might pull data for a complex form
from two or three different SharePoint
| | 02:48 | lists and a web service.
| | 02:50 | But I will always submit my data, all
of the data, at one time, either to email,
| | 02:57 | to SharePoint, or to another location.
| | 03:00 | If I want to understand the data
sources in any form that I opened in the
| | 03:04 | Designer, all I need to do is click the
Data Connections button and it will show
| | 03:09 | me each of the connections.
| | 03:11 | This connection, for example, which
is the connection for this dropdown,
| | 03:16 | retrieves data from a SharePoint site.
| | 03:20 | This connection submits data in a
completed form to a SharePoint library.
| | 03:27 | Now that we understand the many ways we
can obtain external data for a form or
| | 03:32 | submit user-entered data, we are
ready to begin creating our first main, or
| | 03:37 | primary, data source for use in an InfoPath form.
| | Collapse this transcript |
| Automatically creating a data source| 00:01 | You create an InfoPath template
because you want to be able to capture data
| | 00:05 | from users and do something else with it,
whether it's place it in a database
| | 00:10 | or display it on a SharePoint site, use
it in some kind of a workflow, or simply
| | 00:15 | print it and store in a file drawer.
| | 00:17 | There is some reason we need this data.
| | 00:20 | InfoPath therefore is designed to
make sure that if you create a form, it
| | 00:24 | will have a data source.
| | 00:26 | If we'd specified a data source after we
chose File > New then that data source
| | 00:32 | would show here on the right in the Fields list.
| | 00:34 | We started blank and so there is
nothing here, and InfoPath waits to help create
| | 00:40 | a data source for us.
| | 00:42 | So, for example, if I decide that I'm
going to play some controls, InfoPath is
| | 00:48 | going to create the data
source that goes along with it.
| | 00:51 | Let me just create a design table
for us to drop some controls into, just
| | 00:55 | because it's a best practice.
| | 00:58 | And I'm going to say that I want to
enter today's date, and I'm going to click
| | 01:03 | words it says Add control, and it's a
date, so I am going to add a date picker.
| | 01:07 | And InfoPath automatically creates a field
to hold the data that a user would enter here.
| | 01:14 | In the same way, if I enter a first
name here, InfoPath will create a field to
| | 01:19 | hold it, a last name, and another field.
| | 01:27 | Perhaps up here I would like to have
the email address and a fourth field.
| | 01:34 | You begin to notice a pattern I bet.
| | 01:37 | Every time I drop a control, I'm
going to get a container here on the right,
| | 01:42 | called field1, field2, and so on.
| | 01:46 | I'm really building an XML schema here,
so we can talk about these as being nodes.
| | 01:52 | Field4 is a node, field3 is a node,
field2 and 1 are each nodes, and they're
| | 01:57 | part of a higher node, a
parent node, called myFields.
| | 02:02 | Now, the form works just fine for a user.
| | 02:05 | Let me go ahead and add a
couple more fields here.
| | 02:09 | We'll add a control for Department and
we'll add a field for Location, 5 and 6.
| | 02:18 | Notice the user will have no trouble
putting information into this form.
| | 02:22 | They know what Today's Date is.
| | 02:24 | They understand what the
labeled Email Address means.
| | 02:27 | So if all we cared about was user input,
this list of fields on the right here
| | 02:31 | would be fine. But we want to use this
information again, and if we choose to
| | 02:36 | publish the results of this form on
SharePoint, rather than saying, here's
| | 02:41 | today's date, here's the person's email address,
| | 02:44 | it will say field1, field2, field3, and so on.
| | 02:47 | So obviously, it's not enough to let
InfoPath automatically create a field list,
| | 02:54 | a schema, because we've
dropped controls on our form.
| | 02:57 | We're going to have to be able to
modify the schema to meet our needs, perhaps
| | 03:01 | to create parts of it from scratch if we wish.
| | 03:04 | We'll see how to do that in our next movie.
| | Collapse this transcript |
| Setting field properties| 00:01 | It's easy to tell that the InfoPath form
controls have properties, have settings.
| | 00:07 | Some are text boxes, some are
combo boxes and check boxes;
| | 00:10 | they are visually different.
| | 00:12 | But fields have properties, too, that we can set.
| | 00:15 | Let's see how to set the
properties of fields in our schema here.
| | 00:19 | I am going to double-click on field1, and the
Field or Group Properties dialog box opens.
| | 00:25 | The first thing I can do
is I can change its name.
| | 00:28 | If I move this, I can tell that field1
is right here in my form because it has
| | 00:33 | handles around it, and I
can see that it's selected.
| | 00:37 | So I know that this is today's date.
| | 00:39 | Now, I could type 'Today's Date' like this,
but actually, InfoPath won't let me.
| | 00:44 | I'm creating an XML schema and
there are some rules associated with it.
| | 00:49 | I can't use much punctuation. No spaces.
| | 00:52 | I can use underscores, hyphens, the
period symbol. And by definition, I'm not
| | 00:57 | supposed to use uppercase.
| | 00:59 | So 'Today's Date' becomes 'todaysdate'
like this. Because I had dropped a date
| | 01:05 | picker, the data type of date is
chosen, but there are other choices here.
| | 01:11 | Text is used for plain text, a
paragraph or less. If a user presses Enter,
| | 01:18 | wants to press Enter when entering
data in a text field, we'll have to make a
| | 01:23 | special property setting for that.
| | 01:25 | Rich text is a kind of control we use
when we really want the user to be able
| | 01:30 | to format the text.
| | 01:31 | We'd like them to be able to choose to
put in a bulleted list or a numbered list
| | 01:36 | or to enter several paragraphs of text.
| | 01:40 | Whole Number is just what it says;
| | 01:42 | it's an integer with no trailing decimals.
| | 01:45 | A user will not be allowed to
enter anything other than an integer.
| | 01:49 | Decimal is used for all other
numbers other than integers.
| | 01:53 | So Decimal would be used
for currency quite frequently.
| | 01:57 | The True/False data type is normally
presented to a user in a form through a check box.
| | 02:03 | If they check it, it's true;
| | 02:05 | if they don't, it's false.
| | 02:06 | You can also think of this
is as yes/no or possibly 0/1.
| | 02:10 | This type of field is called a Boolean field.
| | 02:13 | The ability to add a hyperlink is
built in and the ability to add a date or a
| | 02:20 | time or a date/time field.
| | 02:24 | Finally, we have the ability to
add a picture or file attachment.
| | 02:28 | So a user here could click and could
place an image or could click and attach a
| | 02:33 | file, and that type is the same type.
| | 02:37 | Let's go back to Date,
because this is a date field.
| | 02:40 | Some other attributes of this field, if we
require this, then we mark Cannot be blank.
| | 02:46 | The red asterisk means that on the form
there will actually be a visual red asterisk.
| | 02:52 | It's a nonprinting character, but it allows
the users to know which fields are required.
| | 02:58 | We could put in a default value.
| | 03:00 | We'll learn about that later.
| | 03:02 | There are two other tabs.
| | 03:03 | When you initially add a
field, this is all you see.
| | 03:07 | All these other properties you find
later by double-clicking on the field
| | 03:11 | that already exists.
| | 03:12 | So there's information on how we
would merge this field with others, if we
| | 03:17 | collected fields together, and then
there's information that are details about
| | 03:22 | this field. Because we didn't
say that this field repeats,
| | 03:27 | it can only occur once.
| | 03:28 | There's only one container for it,
| | 03:30 | and that it is a date,
and that we set no default value.
| | 03:35 | You'll spend most of your time on
the initial tab of the Field or Group
| | 03:39 | Properties dialog boxes.
| | 03:41 | I am going to say OK.
Notice todaysdate with an asterisk.
| | 03:47 | And when we switch to Preview mode,
there's asterisk that allows the user to know
| | 03:53 | that this is a required field.
| | 03:55 | Let's go ahead and look at the
properties of this text box, and you'll notice
| | 03:59 | that we have a similar Field or
Group Properties dialog that opens.
| | 04:03 | This is the firstname field. So we'll say,
it can't be blank, and we'll name it.
| | 04:09 | And then, finally, the Last Name field.
| | 04:11 | Now, I can click here. I can
also double-click in the form.
| | 04:15 | If I do, it will not open the dialog
box, but it will take me to the control
| | 04:20 | tools properties tab, so I
could choose Field Properties here.
| | 04:25 | That's the other place I can open this.
And this field is the lastname field
| | 04:30 | and I'm going to say that
it also cannot be blank.
| | 04:34 | We could then proceed to fix the Email
Address, Department, and Location fields.
| | 04:39 | So here's our email address--
| | 04:42 | I don't mind if this is blank, so
we'll say OK--department, and location.
| | 04:50 | So, I very easily gone in and
adjusted the properties of these fields.
| | 04:55 | Now you might wonder, what if I wanted
to further limit or further specify what
| | 05:00 | was allowed in these fields?
| | 05:03 | The properties seem very limited.
| | 05:04 | For example, if I look at the
date property for todaysdate,
| | 05:09 | there's nothing here that says what
the date format would be. That's correct.
| | 05:14 | The properties that you've seen are the
only properties that we can assign to fields.
| | 05:19 | The rest of the properties we
assign we'll assign to the controls.
| | Collapse this transcript |
| Modifying a data source| 00:01 | I've changed some of the
properties of my data source that InfoPath
| | 00:04 | automatically created as I dropped
controls into my template, but I also want to
| | 00:09 | change its structure. Let's look at why.
| | 00:12 | I currently have a data source that has fields in
it with the names of todaysdate, firstname, lastname--
| | 00:18 | I've added spaces here for
readability, by the way--email, department,
| | 00:23 | location, and as I continue this form,
I'm going to actually start gathering
| | 00:28 | travel request information from the user.
| | 00:30 | I am going to ask them what city they
are going to and when their travel date
| | 00:34 | is, and many, many other fields.
| | 00:36 | By the time I'm done, I'll have
60 or 70 fields in this form,
| | 00:40 | all listed simply one after another.
| | 00:43 | But that's not really the truth of
these fields' relationships to each other.
| | 00:47 | I would create a better data source by
grouping together like kinds of information.
| | 00:53 | It will make no difference to the
user right now, but it will make a huge
| | 00:58 | difference when I see the data later,
| | 01:00 | to be able to know what
goes together and what doesn't.
| | 01:03 | Additionally, there are some form
features that are meant to work with group data.
| | 01:09 | So by grouping like kinds of data now,
we can leverage that in our form creation
| | 01:14 | later on with some of the controls,
| | 01:17 | for example, repeating
tables and repeating sections.
| | 01:21 | So the form has a date on
it, but then it has a user.
| | 01:24 | Now there's no field for user on the left,
and there won't really be a control for user.
| | 01:31 | However, I will create a group and put
the user's first name, last name, email,
| | 01:37 | department, and location inside of that group.
| | 01:41 | If you're familiar with XML
schemas, we have here our nodes.
| | 01:45 | We have a node called user, with elements:
| | 01:48 | first name, last name, email, and so on.
| | 01:51 | Then I'll have a travel request.
| | 01:53 | It will become a different
higher-level group, and in inside of that travel
| | 01:57 | request, we'll have city, travel date,
what hotel they want to stay in, whether
| | 02:02 | they're going to drive or fly, do
they need a rental and car, and so on.
| | 02:06 | By grouping this information, we end
up having a stronger, more robust, and far
| | 02:12 | more descriptive data source than if
we simply leave each of these elements
| | 02:17 | on the left ungrouped.
| | 02:19 | So let's see how we do that.
| | 02:21 | If we return to our form, we really want
to create two different groups in myFields.
| | 02:27 | The first group is for the user, so
we're going to add a user, and notice this is
| | 02:32 | the Add Field or Group dialog box.
| | 02:35 | I'm going to create a group.
Don't create a choice Group right now.
| | 02:38 | We'll talk about those later on in
this course. And I'm going to say OK, and
| | 02:43 | there is my user group.
| | 02:45 | Now I want another group as well,
and I want to create it up here.
| | 02:48 | If I click here and create a group,
it will become a subgroup of user.
| | 02:53 | So you always want to make sure you
see where you are when you're adding
| | 02:56 | fields or groups here.
| | 02:58 | So I'm simply going to add another
group that's called travelrequest, and when I
| | 03:05 | choose Group, there is no data type
for a group, and I'm going to say OK.
| | 03:09 | Now, what I'd like to do is move the
fields I already have--first name and last
| | 03:13 | name and so on--into the user group.
| | 03:17 | If you chose the dropdown in the fields
list, you have a choice to move things
| | 03:23 | up or down, to delete them, to add an
element or an attribute to the selected
| | 03:30 | item, or to move them.
| | 03:32 | When you move up and down it
simply rearranges the list.
| | 03:36 | If you want to put it into a
group or remove it from a group, you
| | 03:39 | actually choose Move.
| | 03:41 | So I'm going to say I'd like my
firstname in the user group, OK, and there it is.
| | 03:48 | I'll choose lastname in the same way
and choose Move it to the user group.
| | 03:56 | Now email, move it to the user group.
department, location, and I can also just
| | 04:09 | double-click the user group here.
| | 04:12 | Now I have space for a travelrequest.
| | 04:14 | I can continue adding controls and
allowing Microsoft InfoPath to create fields,
| | 04:22 | but it will not put them in groups for
me unless I work really hard to structure
| | 04:26 | my form, so that it
understands that I'm creating groups.
| | 04:30 | It's actually pretty easy for me to
choose travelrequest and add myFields here.
| | 04:35 | So this is my city that I'm going to go to.
| | 04:38 | That's a text field.
| | 04:40 | Now I want to add the
traveldate, and that's a date field.
| | 04:45 | Now I can simply hit the first letter
of the word on this list. Text is by
| | 04:49 | default. If I hit D once,
it will fall to Decimal.
| | 04:52 | If I hit D again, it will go to Date.
And we needed hotel information--click
| | 05:00 | Add Field again--and rentalcar.
| | 05:03 | So now I've modified the
structure by creating groups.
| | 05:06 | I can add items here, or I can
continue to add content controls and move
| | 05:11 | items into my hierarchy.
| | 05:13 | If I know ahead of time what all of myFields
are, it's great to simply go in and create them.
| | 05:18 | But however you create your structure
for your data source, when you're done,
| | 05:23 | you want to make sure that like items
are grouped, that you've abstracted groups
| | 05:27 | to place them into, and arranged your
data source in such a way that it's what's
| | 05:33 | called human readable.
| | 05:34 | Any human reading this can
make pretty good sense out of it.
| | 05:37 | This is a far better data source here
for our template, and so at some point
| | 05:42 | soon, it would be time for us to save
the template, and in doing so, we save
| | 05:46 | our data source.
| | Collapse this transcript |
|
|
4. Formatting a TemplateSelecting a page layout template| 00:00 | When you create your form layout, we are
going to do three things right in a row.
| | 00:05 | The first is we are going to choose a
page layout template for the entire form.
| | 00:09 | We are then going to populate it with
tables, and we are going to change the theme--
| | 00:13 | and you can do the tables
or the theme in either order.
| | 00:16 | When you create a new template, it
already has a page layout in it, right here.
| | 00:21 | It's the layout that is known as Title Only.
| | 00:24 | We find these on the Page Design tab.
| | 00:27 | So, Title Only doesn't have a whole
lot in it, doesn't have a subheading,
| | 00:31 | doesn't have a body.
| | 00:32 | Let's take a look at some of these others.
| | 00:34 | Simply select the table here and press
Delete, and then we could choose, for
| | 00:39 | example, Title and Heading. What you find is
you have a place for a title and a heading.
| | 00:45 | If the forms in your organization
have the organization name and logo here
| | 00:50 | and then have the title of the form, or the
other way around, you would rather choose this.
| | 00:58 | The next layout is Title and Body, and it
actually creates a place for some body text.
| | 01:03 | This is used for a form where at the top
you want to explain the purpose of the form.
| | 01:07 | Again, each of these gives you a head start.
| | 01:09 | You can insert text in any page
layout template, but if this is what you're
| | 01:13 | going to do, it make sense to grab this first.
| | 01:18 | Color Bar puts an attractive bar down
the left-hand side, and that bar actually
| | 01:24 | comes from the theme, which we'll talk
about in a minute, but it doesn't allow
| | 01:27 | to choose another theme, so you can
see that it actually changes color.
| | 01:34 | And then finally, we have a template
that's called Offset Body, and what you have
| | 01:39 | here is the tables are going to be
offset as they might be in a report.
| | 01:44 | This can be a very attractive form,
but know that as with Color Bar, you're
| | 01:48 | throwing away some space.
| | 01:50 | With Color Bar you throw away
about half this distance.
| | 01:53 | It's a nice visual element, but you
can't do anything in that area. And here
| | 01:57 | you give up slightly more than an inch to have
all of your tables line up in an offset fashion.
| | 02:05 | So I'm actually going to
choose Title and Heading.
| | 02:10 | That's my Page Layout.
| | 02:12 | I'm sticking to it.
| | Collapse this transcript |
| Adding and formatting a layout table| 00:00 | I've chosen a page layout, and
now it's time to create tables.
| | 00:04 | Whatever I know about my data, it's a good
thing to have that close at hand right now.
| | 00:09 | For example, if I'm working from
a manual form that's been in use,
| | 00:13 | I'd like a copy of that form in front of me.
| | 00:16 | If I'm working from a list of fields
that I've gotten from others and then
| | 00:20 | I've drawn a sketch on a napkin, I
want get napkin in front of me, because I
| | 00:25 | need to choose the basic structure of
how my form is going to look, and that's
| | 00:30 | all about the data.
| | 00:32 | On the Insert tab, we have an entire
gallery of tables, as well as the ability to
| | 00:36 | create a custom table.
| | 00:38 | I'm going to click where it says
'Add tables' and then open this dropdown,
| | 00:43 | and you'll find that we have
single-column tables here which allow a field
| | 00:48 | that goes from the left side of the
form to the right. And the differences
| | 00:52 | between these four thumbnails are that
this has no heading above it, this has
| | 00:57 | a subheading, this has a larger heading,
and this has both a heading and a subheading.
| | 01:04 | So if I were going to have a series of
tables and perhaps wanted to explain them
| | 01:09 | at the top of the first one, I might
choose this, and then for later tables
| | 01:13 | include just a subheading.
| | 01:16 | I then have some two-column and
four-column tables. They don't all have the same
| | 01:21 | number of controls per
row, so let's take a look.
| | 01:25 | And these two-column tables here, this
set of four, the first column is taken up
| | 01:29 | with labels and the second
is taken up with my controls.
| | 01:33 | So there are the four two-column
tables that really, each row has one control
| | 01:38 | element in it, and again, one with no
heading, one with the subheading, one with
| | 01:44 | the heading, and one with
both headings and subheadings.
| | 01:47 | I can see exactly those same four
choices repeated here on the right, two-column
| | 01:53 | tables, but with a backfill, with an
emphasis that's picked up out of the color
| | 01:57 | set, the theme that we'll choose next.
| | 01:59 | So I have the choice of four different
sets of headings or no headings and the
| | 02:06 | same thing with some backfill.
| | 02:08 | I then have what's called a stacked
display, and here, even though I have the
| | 02:13 | same two columns, in this layout,
the label appears above the control.
| | 02:18 | So the label todaysdate would be
above the date picker, and because I'm not
| | 02:23 | giving up the first column to Labels,
| | 02:25 | I actually have the ability to
put two controls in each row here.
| | 02:29 | I see those same four choices
and the four choices with emphasis.
| | 02:33 | I then have some four-column choices,
and none of them stack the controls.
| | 02:39 | So basically the four-column choices
will give me the same kind of layout as I
| | 02:46 | get here, with my two columns, because
what I have is a label and a control, a
| | 02:52 | label and a control.
| | 02:54 | If I want something other than two
columns, single column, or four columns, then
| | 02:58 | I should choose Custom Table.
| | 03:00 | What I'm going to choose this time is
I'm going to choose this two-column table
| | 03:04 | right here, with no heading.
| | 03:07 | And notice what it looks like.
| | 03:08 | It's very basic. My labels are
formatted in italics, so I could enter, for
| | 03:13 | example, Today's Date, and then
I click here to add a control.
| | 03:18 | Below this I would like the user to
have a place to enter a fair amount of
| | 03:22 | information, and I'd like to
give them a little subheading first.
| | 03:26 | So I'm going to choose this Single
Column stacked, and when I do, notice its
| | 03:31 | Click To Add Subheading,
and here I had my label and control.
| | 03:35 | Below this I have an area where I would
like the user to be able to enter a fair
| | 03:40 | amount of information in a small area.
| | 03:43 | So I'm going to choose one of these
four-column layouts, and I'm going to choose
| | 03:48 | one with an emphasis so you
can see what it looks like.
| | 03:51 | So we pick up a color out of the theme.
| | 03:54 | It's actually quite bright.
| | 03:56 | If I'd like a custom table for any of these, I
can simply choose a table as I would in Word.
| | 04:02 | The only issue with a custom table is
that I don't have the ability to put
| | 04:07 | headings and subheadings on it easily,
and it won't come with automatic Add
| | 04:13 | Label, Add Control placeholders.
| | 04:15 | So it might be that if I want a
custom table and I would like it to have a
| | 04:19 | heading, I might go in first and
say, well, I'm going to go pick up a
| | 04:23 | subheading here, just to get the
subheading, delete the rows, select,
| | 04:32 | right-click, Delete > Rows, so that I
have this subheading out of my gallery,
| | 04:38 | and then I could add a custom table.
| | 04:40 | So, for example, if I would like
people to be able to add a lot of data here
| | 04:44 | in a really small area, I could choose,
for example, an 8x1 table or 8x2, and
| | 04:51 | when I do that it will create a table for me--
but again, no placeholders in the table.
| | 04:56 | The other things that you can do to a
table here in InfoPath are very similar
| | 05:02 | to the things that you
can do when you're in Word.
| | 05:04 | If you click in a table, you have the
ability to insert rows above or below,
| | 05:10 | insert columns to the left or
the right of the current column.
| | 05:13 | You can turn gridlines on and off.
| | 05:16 | You can delete rows or columns that are
selected or the entire table that you're in.
| | 05:22 | You can take two cells or more and
select them and merge them and put them
| | 05:27 | together for a longer entry.
| | 05:29 | You can select any cell or group of
cells and split it into two or more columns
| | 05:35 | to be able to put very small controls--
| | 05:37 | for example, a two letter
state abbreviation would go here.
| | 05:41 | And you have the ability to modify
borders and shading in your table.
| | 05:46 | I ask you not to do that yet, for
reasons that will be apparent in the next movie.
| | 05:50 | You can adjust the cell padding.
| | 05:52 | So, for example, if you'd like to have
this text a little closer to the center
| | 05:56 | of the cell, you can select
any cell and make these changes.
| | 06:00 | Notice as soon as you select, the
placeholders for Add label and Add control
| | 06:05 | disappear, but they still
work exactly the same way.
| | 06:09 | Don't be afraid to use these Layout Table tools.
| | 06:12 | You probably know how most of them
work from other applications, but they're
| | 06:16 | very easy to use here in Microsoft InfoPath.
| | 06:19 | If you make a mistake while you're
formatting or laying out your table, simply
| | 06:24 | go ahead and undo, Ctrl+Z or click
the Undo button to undo your change.
| | Collapse this transcript |
| Choosing a theme| 00:00 | One significant difference between
InfoPath 2007 and InfoPath 2010 is that
| | 00:06 | InfoPath 2010 uses a set of themes.
| | 00:10 | You'll find them on the
Page Design tab of the Ribbon.
| | 00:14 | If you click you'll find about 40
different themes here, arranged in five categories:
| | 00:19 | SharePoint, Professional,
Industrial, Playground, and Modern.
| | 00:24 | The themes affect three
different aspects of your form.
| | 00:29 | They change the borders, they change
the cell colors, and they change the fonts.
| | 00:34 | Because of that, you'll want
to adjust themes very early.
| | 00:38 | So, for example, if I want to change to
this theme, I just click and the entire
| | 00:43 | form is changed at once. I'll switch here,
| | 00:48 | and you'll notice I have a
gray background and some green.
| | 00:52 | I don't think the thumbnails are that
easy to understand, but if you click on
| | 00:56 | them and take a look at what actually happens,
it begins to make sense in your document.
| | 01:02 | We have some backfill on some.
| | 01:04 | We have some stronger lines on others.
| | 01:08 | These themes are not the themes
that you find in the other Microsoft
| | 01:13 | Office Suite applications.
| | 01:14 | These aren't the themes that you would
use in PowerPoint, Word, Outlook, and Excel;
| | 01:20 | these are, instead, themes
that are shared with SharePoint.
| | 01:24 | So if you have a SharePoint site, you
can take a look at what the theme is, for
| | 01:29 | example Graham, and match
it up here in your forms.
| | 01:35 | That's all it takes, one click, to
make your InfoPath form match the theme of
| | 01:41 | your SharePoint site.
| | 01:42 | So go ahead and choose a theme that you like.
| | 01:44 | It doesn't hurt to go through a number
of them until you find one what you want.
| | 01:48 | They're all are a little different.
| | 01:50 | Some of them again have, in tables,
have a color bar, some of them have fill
| | 01:56 | throughout, some of them are easy
to read, and some of them are really,
| | 02:00 | really hard to read.
| | 02:01 | So choose something that
you believe is going to work.
| | 02:04 | If you need to theme it to go with a
SharePoint site, simply go to the site,
| | 02:08 | either ask your site administrator what
the theme is or if you have permission
| | 02:14 | go to the site settings for the site,
and it will tell you what the theme is.
| | 02:19 | Once you're done choosing a theme, it will
be time to go ahead and to save this template.
| | 02:25 | The next thing we'll be doing is
inserting a logo and adding our form controls.
| | Collapse this transcript |
| Inserting a logo or other picture| 00:00 | Another thing you can do to customize
or brand-identify a form you are creating
| | 00:05 | is include a logo from the
organization that the form is created for.
| | 00:09 | So we're going to add a logo to this
Travel Request from the Explorer California
| | 00:15 | organization, which is a
California Tourist Organization.
| | 00:18 | They've sent us a logo.
| | 00:20 | They also sent us some information
about colors that we could use to
| | 00:23 | complement that logo, and so we've chosen a
team that we believe is going to fit really nicely.
| | 00:28 | Now when the logo comes in, it's going to
go somewhere that we'd like to place it.
| | 00:31 | There are couple of choices. We could
put it up in our header, and because we
| | 00:35 | have the organization
name here, that makes sense.
| | 00:38 | Sometimes you'll also see a logo
down in the footer, with some all rights
| | 00:42 | reserved information in a smaller size,
but wherever you insert a logo, there
| | 00:46 | are two different tasks that you're going
to do, related to inserting and placing it.
| | 00:52 | The first, or second, is inserting, and
the other task is actually creating a cell
| | 00:57 | for that logo to live in.
| | 01:00 | If you know, for example, that you're
only willing to give up a certain amount
| | 01:03 | of space for the logo, then you could
begin by slicing that space off here.
| | 01:09 | I'm going to go to the Table Tools
Layout Tab, choose Draw Table, and actually
| | 01:13 | make as much space as I'm
willing to give up here.
| | 01:16 | The Travel Request heading is centered,
| | 01:18 | so watch what happens when I split this in two.
| | 01:22 | Travel Request flies over here to the left.
| | 01:25 | So I'm going to turn off draw table,
select this, and drag it back where it belongs.
| | 01:29 | But now the center of this
cell is farther over to the right.
| | 01:34 | If I'd like to keep this more or less
centered, I could choose to left-justify
| | 01:39 | and space it back over, or another
possibility you'll see is that we'll choose
| | 01:43 | to split both of these and move Explore
California text, so that it will stay underneath it.
| | 01:53 | That works.
| | 01:54 | Now I can merge these two cells if I
wish and drop my picture in right here.
| | 02:03 | The other possibility is I could drop
the picture first and make these table
| | 02:07 | layout changes afterwards.
| | 02:09 | Let's go ahead though an insert the
picture. Click the Insert tab, choose Picture.
| | 02:15 | You'll find this in the
Materials folder in your exercise files.
| | 02:19 | I am going to drop this in. Now, wow!
| | 02:22 | It's really, really big. It's a large logo.
| | 02:26 | So you can tell how much
space I need it to go in.
| | 02:29 | Let's now format it.
| | 02:30 | Right-click Format picture and change its size.
| | 02:34 | The size is currently measured in pixels.
| | 02:36 | I'm actually going to change this
over to inches and make sure that this
| | 02:40 | maintain proportions box stays on,
and I'm going to choose an inch height of
| | 02:46 | about 1 1/2 inches, perhaps even smaller.
| | 02:51 | Let's go 1 and see how
that looks, and apply it.
| | 02:55 | And notice that that fits fairly nicely.
| | 02:57 | I could make it a little bit bigger and
fill up that space a little more, click
| | 03:02 | Apply to see that change.
| | 03:05 | Nope, just let's go back to a little bit
smaller, split the difference here. There we go.
| | 03:12 | It fits nicely.
| | 03:13 | This is the margin, and you can tell that
because it's the same margin we see down here.
| | 03:19 | Let's click OK.
| | 03:21 | We've inserted our picture.
| | 03:23 | Now I'm going to go preview this just
so you can see, because it often appears
| | 03:27 | more crowded than it actually is
when you can see the gridlines.
| | 03:31 | So let's look at the preview of it,
and you'll notice this looks nice.
| | 03:36 | I am going to slide both of these
items over here, Travel Request and Explore
| | 03:40 | California, my heading and subheading,
| | 03:42 | I want to try them over to the
left, just for the heck of it.
| | 03:44 | So I am going to select them both, left-justify
them, go back to preview. Ah, that looks good.
| | 03:50 | The other things that you can do when
you have a picture or an image selected,
| | 03:54 | you'll find on the Picture Format tools
| | 03:56 | you can change the border.
| | 03:57 | You can adjust the size here, instead of
right-clicking and choosing Format picture.
| | 04:02 | You can indicate how text wrapping is
going to happen, whether it goes in line
| | 04:06 | with text to the left or the right, far
fewer choices and you than you have, for
| | 04:09 | example, in Word. And you can supply
alternative text, so that if you create this
| | 04:14 | form and ultimately publish it in a web
browser, users who could not see this,
| | 04:20 | or who either had graphics turned
off or who used screen scrapers or
| | 04:24 | screen readers to turn the image to
describe the screen and to read the text
| | 04:29 | could see that this was the
Explorer California logo image.
| | 04:34 | So you can supply some alternative
text for these other uses. That's it.
| | 04:40 | Here is our image.
| | 04:41 | We've taken care of checking
the properties of our image.
| | 04:43 | It's that quick and easy to drop an
image in, so that you can appropriately
| | 04:48 | brand the forms that you
create in InfoPath Designer.
| | Collapse this transcript |
|
|
5. Using Controls to Collect DataUnderstanding the use of form controls| 00:00 | On the right, you can see my
list of fields in the Fields list.
| | 00:03 | This is data that I'd like
my user to be able to enter.
| | 00:06 | So I need to give them places to put
this data, typically one different kind of
| | 00:12 | place for each field that
I'd like to collect from them.
| | 00:16 | Controls are the places that
you allow users to put data.
| | 00:21 | The input controls are used in areas
where you would like your user to be able
| | 00:26 | to enter text, choose from a list,
click a box, or something similar.
| | 00:32 | The objects are a mixed bag.
| | 00:34 | They include other things a user would
place in a form, but not by typing: an
| | 00:39 | attached file, a picture that they
would choose by browsing, or a hyperlink, as
| | 00:44 | well as some other controls that allow
for functionality in the form. And then
| | 00:50 | finally, the last type
of control is a container.
| | 00:54 | Containers are simply sections or
groups that are used to group these other
| | 01:00 | types of controls in a logical
fashion, and for some other reasons.
| | 01:06 | So, for example, if I wanted to
create a myfirstname field in the form, I
| | 01:12 | could simply drag this field out and
drop it in the form, and I'll get a
| | 01:16 | really big text box control.
| | 01:19 | That's the default type of control when I am
allowing the user to enter text. It has handles;
| | 01:25 | therefore I can change its size.
| | 01:27 | I can also point to the edge of it
and move it somewhat, although I'm at
| | 01:31 | the very top of my form here. I could have
moved it up here in the header if I wished.
| | 01:36 | Remember, you can always choose Undo
here on the Quick Access toolbar, or you
| | 01:41 | can hold Ctrl+Z and undo a change you have made.
| | 01:45 | When I drag the first name field into
the form, as the text box control was
| | 01:49 | being created, InfoPath also took a
look at the name of the field, capitalized
| | 01:54 | the first letter and
threw it in here as a label.
| | 01:57 | This allows me at least to see what
field this is easily when I'm not in Design
| | 02:02 | view, or when it isn't selected. But I
can feel free to delete this if I wish,
| | 02:06 | and later on I'll be typing in my own labels
| | 02:09 | that will make more sense to the user,
than the kind of tag labels that I'm
| | 02:13 | providing here in my data source.
| | 02:16 | Because this field has
handles, I can change its size.
| | 02:19 | I can also select it and hit Delete.
| | 02:21 | Notice that when I do, the label remains.
| | 02:24 | In order to delete it, I can select
it and hit Delete, or I can use the
| | 02:29 | Backspace key, that kind of thing.
| | 02:32 | I have here a choice that says mygender.
| | 02:36 | Presumably that's a short list.
| | 02:38 | I can drag it out here and force my
user to type in this text box, or I could
| | 02:43 | use a different kind of control,
| | 02:45 | for example, a list control. And if I
were going to do that, I could either
| | 02:50 | choose Drop-Down List here from the list,
but if I do, then I have to find some
| | 02:56 | way to say, no, this isn't a new field;
| | 02:59 | it's actually for mygender.
| | 03:01 | So this is one way to place
a control is simply to click.
| | 03:04 | I can click a check box.
| | 03:06 | I can click a date picker, or a time and
date field. But if I simply controls here,
| | 03:13 | what InfoPath will do is it will create
brand-new fields for me each time I do,
| | 03:17 | and I'll have to delete those
if I don't wish to have them.
| | 03:32 | So when it's possible, I actually
prefer to choose the field that I wish and to
| | 03:38 | place it in the form, not by dragging
it over, which will always give me a text
| | 03:42 | box for words, but by holding my
right mouse button and dragging it. And when I
| | 03:47 | release, I'll have a choice of every
type of control that is appropriate.
| | 03:52 | For example, if I wanted a short list
box, I can drop one in right here and
| | 03:57 | create a list in it.
| | 03:59 | Now, just as text fields
automatically want to make text boxes but I can
| | 04:04 | override that by right
dragging to place the control,
| | 04:08 | when I drag the field 'today' in,
because it's a date field, I will
| | 04:12 | automatically get a date picker.
| | 04:14 | When this is seen in a preview mode,
the user actually gets to choose a date
| | 04:20 | from a dropdown. Not bad, nice little calendar.
| | 04:26 | If I right-drag that date field,
I have the choice to say, no,
| | 04:30 | I'd rather have the user enter text or
choose from our short list of dates that
| | 04:35 | will be stored as a date.
| | 04:36 | We might do this for something like tickets
to a performance that happens three times.
| | 04:42 | They can't choose any date;
| | 04:43 | they can only choose from
those three specific dates.
| | 04:47 | Each place that I place a control, a
user makes a choice which then is connected
| | 04:53 | to, or bound to, this data source, so that
I know that no matter where on the form
| | 04:58 | I place the today field, it's connected
here. No matter where on the form I have
| | 05:03 | the control for mygender, it's right here.
| | 05:07 | Controls also have properties. Just as
we have the today field here that's a
| | 05:13 | date field, I have a date picker
control that has properties of its own.
| | 05:18 | I can either right-click the date
picker control and then choose Date Picker
| | 05:23 | Properties from the context menu, or I
can double-click the control to bring up
| | 05:28 | the Control Tools Properties Ribbon to
the front and choose Control Properties,
| | 05:33 | and I'll see the things I can change on this.
| | 05:35 | For example, I can have a default
value and automatically enter today's date.
| | 05:41 | I can type in a placeholder,
click here and choose a date.
| | 05:46 | I can set some specific size information.
| | 05:49 | I can provide a screen tip for people
who are opening this particular form who
| | 05:55 | have visual challenges and have
a screen reader reading to them.
| | 05:59 | There are some other settings that I'm
not going to set as frequently, and then
| | 06:02 | Browser Form settings, which
we'll talk about later in this course.
| | 06:08 | The list box control has different
properties that have to do with how the
| | 06:13 | choices for this list would be put together.
| | 06:15 | So every control is tied back to a
field. Every control has properties of its
| | 06:22 | own, and Microsoft InfoPath has a really
lush Control Gallery for you to choose from.
| | 06:28 | We will learn about these
controls in the next movies.
| | Collapse this transcript |
| Organizing a template with sections| 00:00 | Before you begin adding tables and
controls to your form, you should think about
| | 00:05 | how your form would best be organized.
| | 00:08 | In addition to using tables, you can
use sections, and should use sections, to
| | 00:13 | organize your data in a way that's meaningful.
| | 00:16 | For example, in this form, which is a
request to post something on a web site,
| | 00:22 | we have a well-organized data source here.
| | 00:25 | Here's who the request is coming from,
all of their information, and here's
| | 00:29 | information about the post,
| | 00:31 | the information that's
being sent to be put on the web.
| | 00:34 | These are two different types of data.
And then within the posts section, we
| | 00:39 | actually have a title and
a description for the post.
| | 00:43 | We also have some category
information, some department information, and then
| | 00:48 | whether or not this is a news item.
| | 00:50 | We're going to spend a fair
amount of time with this form,
| | 00:53 | so let's make sure that we
understand what it's about.
| | 00:56 | When I want to have somebody post
something on our intranet or Internet in my
| | 01:01 | organization, I'm going to send
them the content I'd like them to post.
| | 01:06 | In a Word document, for example, or
perhaps as a web page that's already created,
| | 01:11 | a form, however I send it to them,
| | 01:13 | I'm going to provide some information
to our office of electronic communication
| | 01:17 | to let them know how they should post it.
| | 01:19 | I'm going to tell them the name and
give them a description of the post that
| | 01:24 | helps them understand why I
want this information posted.
| | 01:27 | I'm going to place that information
into a category, so that they know where it
| | 01:32 | should be, and perhaps I'll have more
than one category. We'll see how to create
| | 01:36 | this kind of a repeating layout later.
| | 01:40 | I also want to say what department I
believe this information is best assigned to,
| | 01:45 | so that when a user in facilities
goes in to the intranet, if it's internal,
| | 01:50 | they can see the things that are
meant for facilities employees,
| | 01:54 | whereas the folks in accounting
will see a different set of information
| | 01:58 | that's most critical.
| | 02:00 | So who are the primary consumers
of this information in this post?
| | 02:05 | And then finally, should it go
on the homepage or the Internet?
| | 02:08 | Do I believe that it's newsworthy?
| | 02:11 | I of course won't make that final
decision, because somebody else will get to
| | 02:15 | choose based on the other information
that comes in. And if it's newsworthy, how
| | 02:19 | long is it news, if I have a
reasonable expiration date for it?
| | 02:22 | Finally, I'm going to attach the file
to this form, and then I'm going to let
| | 02:27 | them know whether this is a file that
they are to post as a file or to create a
| | 02:32 | page and create a link to the file,
or simply to use the information to
| | 02:35 | generate a web page.
| | 02:37 | So a nice form that rather than me
emailing things to the folks in our office
| | 02:43 | of electronic communications and saying,
hey, I think this should go up, this
| | 02:46 | is who should see it, and then they write
back and say, well, how long, that kind of thing,
| | 02:51 | they've put together a list of the information
that they need to be able to do their job well.
| | 02:56 | If we were thinking about how this
form is organized, the first thing is,
| | 03:00 | there's clearly a set of
data here about requesters.
| | 03:03 | Whenever you see a data set that goes
together, like this, you should think
| | 03:07 | automatically, I think that I want to put
that together in one section in my form.
| | 03:13 | So we'll click in the form and under
Controls, we'll actually insert a control
| | 03:18 | that's called Section.
| | 03:19 | Notice that it's a container.
| | 03:20 | All it does is hold things together.
And it will automatically say that it's
| | 03:26 | part of group 1 here.
| | 03:28 | It doesn't understand that I wanted
to use it for requester. That's okay.
| | 03:33 | We'll figure that out in a little bit.
| | 03:35 | I then have one for posts.
| | 03:37 | It's the same thing.
| | 03:39 | I'll go in here and say all right, I want
to press Enter to create a little space.
| | 03:43 | I can always get rid of that later.
And I'm going to put in another section here,
| | 03:49 | and automatically there's a
group called group2 that's created.
| | 03:54 | Notice that unlike when I drop a
control, when I drop a section, there is an
| | 03:58 | assumption that InfoPath makes, that a
section which is meant to hold a group of
| | 04:03 | controls, automatically means that I'm
going to be creating a group and not a
| | 04:08 | simple field or element.
| | 04:10 | There's another kind of section that
we can talk about using, and that's to
| | 04:14 | create a section that will only exist
in the form if certain conditions are
| | 04:18 | true, if a user clicks a button or a
link, or if a user decides not to delete it.
| | 04:23 | All of the information in our form,
however, we're going to have appear all the
| | 04:28 | time, and so we won't be
using an optional section.
| | 04:31 | We'll simply be using a section, a
container that contains other controls and
| | 04:37 | allows us to group them or treat them together.
| | 04:41 | One more thought about why
you want to use sections.
| | 04:44 | Not only are they a great
organization method for your form, but if I use
| | 04:49 | digital signatures in my form, if I
allow a user to digitally sign, I have two
| | 04:55 | choices of what they can sign.
| | 04:57 | I can have them sign the entire document,
or I can have them sign a specific section.
| | 05:03 | So later in this form, when we add
information at the bottom for office use only,
| | 05:07 | we will put it in a separate section.
| | 05:09 | We'll allow the user to sign some
sections of the form and the folks in our
| | 05:13 | electronic communications office to sign the
final section of the form, their own section.
| | 05:19 | Think about how your data is organized,
and then think about how it will be used
| | 05:24 | and who will use it.
| | 05:25 | If there are a set of controls that
only a subset of your users will need to
| | 05:30 | use, consider strongly putting
them in a section of their own.
| | Collapse this transcript |
| Changing data binding| 00:00 | Our form has a couple of sections that
we created by using a Section control,
| | 00:04 | and as always, when we drop a control
from our Control gallery directly into the
| | 00:10 | form, Microsoft InfoPath creates a
corresponding data element on the right.
| | 00:16 | If, for example, we drop a text box here,
it will create a field, and it creates
| | 00:25 | the field inside of group2 because
we're in the group2 section of our form.
| | 00:30 | When we create a section by dropping a
Section control in from the Control's
| | 00:35 | gallery, it creates a group.
| | 00:38 | The problem is I don't need
these new groups and fields.
| | 00:41 | I have plenty of fields and groups already.
| | 00:43 | They are here in my data source.
| | 00:45 | What I need to do is redirect InfoPath
so it knows that this section didn't
| | 00:50 | need a new group, that it's
actually a section for the requestor group.
| | 00:55 | The relationship between this
section and this group is called binding.
| | 01:01 | You can tell when you select a field,
for example, what it's bound to, because
| | 01:06 | you get a small icon here
that says here's your binding.
| | 01:10 | It's bound to field1.
| | 01:12 | If I click the group1 group in my dataset,
it will show me which section control
| | 01:17 | it's bound to in my form.
| | 01:18 | So what we're going to do is we are
going to change the binding for group1's
| | 01:22 | section, and we're going to say
this section that comes first,
| | 01:25 | I actually want to use it
here with the requestor.
| | 01:28 | In order to do that, I can either right-
click on the control for the section and
| | 01:34 | choose Change Binding, or I can
double-click on the section--notice I am
| | 01:39 | clicking on the Section tab--to open the
Control Tools > Properties Ribbon, and I
| | 01:46 | can choose Change Binding here in
the Properties. Either one works.
| | 01:50 | Either double-click and choose Change
Binding or right-click and choose Change Binding.
| | 01:55 | This is then a simple matter of saying
actually this is hooked to the requestor group.
| | 02:00 | Sections cannot be bound to fields.
| | 02:03 | They have to be bound to groups.
| | 02:05 | I am going to say OK, and now
notice that the binding says requestor.
| | 02:11 | I'm going to select and delete
field1, just so I am not confused.
| | 02:16 | I'm going to select the section, choose
Change Binding and I'm going to bind the
| | 02:21 | second section to posts and say OK.
| | 02:25 | Notice now where the binding is.
| | 02:27 | When I choose requestor, it says, this section.
| | 02:29 | Posts, this section.
| | 02:32 | This is a great time, right now, to get
rid of these extra groups and fields,
| | 02:37 | because even though we've deleted the field
control, the field is still in our data source.
| | 02:44 | Even though we've changed the binding
on the sections, these group nodes that
| | 02:48 | were created still exist.
| | 02:50 | So simply select and choose Delete.
| | 02:53 | You will see a message that says,
"Deleting this field or group will affect any
| | 02:57 | controls in your form
template that are bound to it.
| | 03:00 | Are you sure you want to delete it?"
| | 03:02 | This is a stock message.
| | 03:04 | You will see it all the time.
| | 03:06 | This doesn't mean anything.
| | 03:07 | There's nothing bound to it yet.
| | 03:09 | So InfoPath doesn't check first and say, hey,
are there any form controls bound to this?
| | 03:14 | It doesn't bother.
| | 03:15 | It assumes that you are checking.
| | 03:17 | So we say yes, we are going to delete
it, and the group will simply disappear.
| | 03:21 | The same thing happens here
when we delete this group.
| | 03:24 | It says, "Deleting this field or group
will affect any controls in your form." Yup!
| | 03:29 | We are sure we want to delete it.
| | 03:30 | Note that I did not have to
delete the field1 field first.
| | 03:35 | Simply deleting the group got rid of the
field control that was contained within it.
| | 03:40 | This is pretty powerful.
| | 03:41 | If I accidentally delete this, for
example, I'll have a lot of rework to do,
| | 03:46 | because when I delete fields and
groups, there is no undo for this.
| | 03:51 | So that dialog box opening is a good
thing, because at least it gives you chance
| | 03:55 | to breathe and think a little bit about it.
| | 03:58 | Now that we know how to bind controls
back to our data, you should feel very
| | 04:03 | comfortable choosing controls from here,
from the Controls gallery, and simply
| | 04:08 | changing their binding, and then
deleting any fields or groups that InfoPath has
| | 04:14 | created because you chose
a control from the gallery.
| | Collapse this transcript |
| Using text controls | 00:00 | We're back in our Web Post Request
InfoPath template that we're designing.
| | 00:05 | While you were gone, I added
more sections to this template.
| | 00:09 | I assume you did to yours as well.
| | 00:11 | So here's a section for department info,
a section for news, and so on, and all of
| | 00:16 | these are inside of a
large section called posts.
| | 00:20 | It really works if you click each
section, and notice in the data source
| | 00:23 | what's highlighted.
| | 00:25 | It should work its way up the form in
a way that makes perfect sense to you.
| | 00:29 | So we have a section that we inserted earlier.
| | 00:31 | It's for requestor section down below
for posts that encompasses all of the rest
| | 00:36 | of the form all the way up to here.
| | 00:44 | Now we're going to add our text
box controls and our date pickers.
| | 00:49 | So the first thing that we're going to
enter is we're going to enter the email,
| | 00:53 | name, department information,
so on for the requestor.
| | 00:57 | So first, we'll let the person type their
First Name and click where it says Add control.
| | 01:04 | Now, again our choices are to drag a
control over here, and if we do, then we'll
| | 01:10 | just have some extra space.
| | 01:13 | I'll show you later in the course
how to have InfoPath not do that if you
| | 01:17 | don't want it to, and we're going to click and
do a Last Name and add the Last Name control.
| | 01:27 | If you don't want to add all of the
labels at this time, you don't have to,
| | 01:30 | because the fact that the field
name comes over is very helpful.
| | 01:34 | So you could just choose now to add,
for example, the email and just drag it in
| | 01:40 | here and wait to enter the label
later, because we have that information.
| | 01:44 | All of these are text box fields.
| | 01:47 | So if I double-click and choose Control
Properties or click the control, right-click,
| | 01:53 | and choose Text Box Properties because
it's a text box, I will get to see all of
| | 01:58 | the properties that I can set for this control.
| | 02:00 | Now the fact that this control holds
text was actually set over here by the fact
| | 02:07 | that this field is a text
field, or as it's called, a string.
| | 02:12 | But the text box has properties of its own.
| | 02:15 | For example, I can put in a default value.
| | 02:19 | Now, that doesn't make a lot of sense if
you put in a first name. What would be
| | 02:23 | the normal first name,
Betty, or Joe, or...hard to know.
| | 02:27 | But the other choice that we'll make
here is we can say I don't want to get one
| | 02:31 | of these forms where someone
hasn't filled in their name.
| | 02:35 | So we're going to say this cannot be blank.
| | 02:38 | I'll then move to the Display tab and
say I could put click here and type, but
| | 02:43 | in this form I have light areas where
people enter text, and I'm going to have
| | 02:49 | areas with a shaded background where they can't.
| | 02:52 | That's actually how Windows works.
| | 02:54 | People are very used to typing in this box.
| | 02:56 | For example, you don't need a lot
of anything typed in this placeholder to
| | 03:01 | know that you could type a placeholder here.
| | 03:03 | So we're going to leave this.
| | 03:04 | We can enable the spelling
checker, but this is a first name.
| | 03:08 | We might not want to do that.
| | 03:09 | We also can choose to make this multi-
line to limit the number of characters.
| | 03:14 | Neither of those are appropriate in the case
of a first name. And we can set its alignment.
| | 03:19 | The next tab is Size and this is
specifying how this text box control operates,
| | 03:26 | how large it is, how much space is
left around the text--that's what padding
| | 03:32 | is--what the margins are within it,
and then you can align the control and the
| | 03:37 | label very easily by simply clicking
and clicking Align, so that you'll have
| | 03:43 | these in the same place.
| | 03:44 | Our table does that for us, and we don't
need to do it because we are using the table.
| | 03:49 | I can finally click on Advanced.
| | 03:51 | I could offer a screentip here so that
when someone points to the control, they
| | 03:56 | see information about it.
| | 03:57 | You will only want to do
that in one of two ways.
| | 04:01 | There are people who put a screentip
in for every single control in a form.
| | 04:06 | It's a little bit annoying each time
you point to a control to have it pop up,
| | 04:10 | if it's a form that you use
regularly or is very easy to use.
| | 04:14 | For example, I don't know how much
information we would have to give someone for
| | 04:18 | them to figure out that they
type their own first name here.
| | 04:21 | So I think we'll probably leave that.
But you could put a screentip in every control.
| | 04:28 | What some form developers choose to do
is to save screentips for fields where
| | 04:33 | users would commonly have a question
about how to complete it, and only to use
| | 04:37 | them in a few areas.
| | 04:39 | We can now go to Browser forms, and
we'll be looking at this property later when
| | 04:45 | we see how to create thin
client forms in Microsoft InfoPath.
| | 04:49 | So between these five tabs, you have
really everything you can easily do to
| | 04:55 | a control, other than formatting it
using the traditional font tools and
| | 05:00 | other formatting tools. Let's click OK.
| | 05:04 | We're going to require a last name, too.
| | 05:06 | So I am going to go to the Text Box
Properties and say it cannot be blank.
| | 05:12 | This is an email address.
| | 05:14 | Likewise, we can look at
its Text Box Properties.
| | 05:18 | I need to be able to get a hold of this person,
| | 05:20 | so I'm going to say
Cannot be blank and choose OK.
| | 05:22 | That's how you set the
properties for text boxes.
| | 05:26 | Now we also have a couple of other
controls that are here in our post section,
| | 05:31 | the title of the post and the
description of the post, and that's what this
| | 05:35 | part of the form is for.
| | 05:37 | Let me just do a little bit
of cleanup here before I leave.
| | 05:39 | Let me go ahead and first make sure that
I've done my spellcheck on First Name.
| | 05:46 | Let me add the label Email Address.
| | 05:51 | Those three controls are fine.
| | 05:52 | Now, title of a post, description of a post.
| | 05:56 | So we'll put in an appropriate label,
like Post Title, and we're going to use this
| | 06:02 | later on in our form when we
publish it as part of the file name,
| | 06:06 | so we'll want to provide some
additional help with this field.
| | 06:10 | Let's go ahead and drag Post Title over
here, and it will place the default check
| | 06:13 | box. Delete the extra text that it gives us.
| | 06:18 | Now let's set some of the
properties of this control.
| | 06:21 | Specifically, it can't be blank because
we need to use it for part of the file's
| | 06:26 | name, but we are also going to
actually provide a placeholder here that says,
| | 06:31 | "This will be used as a file
name, so no punctuation, please."
| | 06:43 | We'll enable the spelling
checker. That works fine.
| | 06:47 | Notice that we see this. However,
notice also that if we publish this as a web
| | 06:53 | form, we will not see any
placeholder text that we enter.
| | 06:56 | So this means that this text will only
be shown if someone uses the InfoPath
| | 07:01 | Filler application to fill this form.
| | 07:04 | Now we're going to add a description,
and we can drag the Post Description field
| | 07:12 | here, and we have a couple of choices.
| | 07:16 | We could choose to make this a rich text
control, and if we wish to do that, then
| | 07:22 | the data type over here should be
different, because it's only a string.
| | 07:26 | So we could allow the user to provide
formatting, to bold, to underline, and so on.
| | 07:32 | But when they save it, it's going back
to a string control, and that won't work.
| | 07:36 | So, given that this is a string and we
like it the way it is, we really want
| | 07:40 | somebody just to provide a text
description that's relatively brief.
| | 07:45 | What we'll do is we'll set the properties of
this control to allow a couple of other options.
| | 07:51 | First, we'll say it can't be blank.
| | 07:55 | But then we'll say that actually
the user can enter paragraphs of data.
| | 08:00 | They could type a paragraph, press
Enter, type another paragraph, press Enter,
| | 08:05 | and so on. And again if this is going
to be filled out in the InfoPath Form
| | 08:09 | Filler, I'll say, "Provide a brief
description of your post's content."
| | 08:21 | So we've now used a text control, a
text box control, and we've also used a
| | 08:28 | multi-line text box control.
| | 08:30 | What would it be like if we were
to use a rich text box control?
| | 08:33 | Well, if we choose to use a rich
text box control, it has slightly
| | 08:37 | different properties.
| | 08:42 | In a rich text box control, we have the
ability to actually put a scrollbar in,
| | 08:48 | and so if someone is entering data and
they fill up the box we gave them, we can
| | 08:53 | tell the box to expand to show all text.
| | 08:56 | That's not going to work over here
with our plain text control, our text box.
| | 09:02 | If we want to provide more space in
our text box, we actually have to make
| | 09:07 | the text box bigger, but with the rich text
box, I can say Expand or Show a Scrollbar.
| | 09:14 | So I could expand it so it
will show three or four lines.
| | 09:17 | I could say scroll automatically,
or I could allow it to scroll in both
| | 09:21 | directions, which users
don't typically like very much.
| | 09:25 | The best choice, if you have the
space, is to say Expand to show all text.
| | 09:29 | One of the biggest distinctions between
your plain text box then and your rich
| | 09:34 | text box is that if you believe your
users may type a widely variable amount
| | 09:39 | of information here--
| | 09:40 | for example, some might type one
paragraph and some might type six--
| | 09:45 | if you want to easily see it all,
you'll want to move to a rich text box
| | 09:50 | control and allow the control itself to expand
to show all of the text that the user entered.
| | 09:58 | Those are our text box controls. Easy
to place in your document. Easy to set
| | 10:02 | the properties of. Feel free to use
them as you will, very broadly, in all of
| | 10:07 | your InfoPath forms.
| | Collapse this transcript |
| Using date pickers| 00:01 | We need to add two different controls to our
form that will allow a user to choose a date.
| | 00:07 | One is a control to capture today's date here.
| | 00:11 | As we continue to improve this form,
we'll actually set a default date, but
| | 00:16 | right now we simply want the user to
choose a date using a control, and we would
| | 00:20 | like them to do it right here in the form.
| | 00:23 | We're going to click, and we're going to
simply put in 'Today's Date' and add a control.
| | 00:28 | Let's go ahead and practice how
that binding thing worked again.
| | 00:31 | So let's grab a date picker right
here from our Controls gallery, knowing of
| | 00:37 | course that we're creating a new
field, but we'll get rid of it.
| | 00:41 | Let's bind this to the
Today field in our data source.
| | 00:47 | So right-click > Change Binding, and let's
delete this field while we remember to do that.
| | 00:57 | Now the date picker has
lots of different properties.
| | 01:06 | Here we have the Field name and the Date.
We have the Cannot be blank again, but
| | 01:10 | we can also provide a default value,
which we'll do later by saying we actually
| | 01:15 | wanted to always enter today.
| | 01:18 | Actually, it's really easy.
| | 01:19 | Let's do it now as a preview.
| | 01:21 | I'm going to click this function button
fx. Say I want to insert a function and
| | 01:27 | the function is actually called today.
| | 01:29 | OK, OK, OK and now this control, when we
preview it, will actually show today's value.
| | 01:37 | It will still allow the
user to choose from the list.
| | 01:39 | Let's see how that looks.
| | 01:41 | Notice here's today's value built in.
| | 01:44 | They can still choose from the list.
| | 01:46 | So again, relentlessly easy. Wll we
did was in the Date Picker properties,
| | 01:51 | changed the default value.
| | 01:53 | Now we're not going to type a placeholder
if we've already supplied a default value.
| | 01:58 | It doesn't make sense.
| | 01:59 | The user will figure out a date goes there
and besides, the placeholder wouldn't show.
| | 02:04 | So there's nothing really here for us to change.
| | 02:08 | Not a lot on these other tabs either.
| | 02:10 | However, back on the Data tab, there's
a button we didn't see earlier for text
| | 02:14 | boxes, and that's Format.
| | 02:16 | So we can enter a date however the date
picker chooses it and display it using
| | 02:23 | any of these formats.
| | 02:27 | If you're creating a form for a web
browser, then you want to know that these
| | 02:33 | date forms that have an asterisk in
front of them actually pick up the date
| | 02:37 | from the operating system if you're
using it in an InfoPath Filler client.
| | 02:43 | But if you're using it on the web, then it will
swap in information that calms hear from the form,
| | 02:49 | information about, for example, do we
put the month first or the day first?
| | 02:54 | That's based on language settings.
| | 02:56 | Whether it's US English or
Czechoslovakian swaps that date around.
| | 03:01 | If you simply want to store the value
of the date, you can choose None, but
| | 03:05 | there's no reason to do that.
| | 03:06 | It's nice for your user
to be able to see the date.
| | 03:09 | So I'm going to actually choose a standard
date format that's month/day/year and say OK.
| | 03:18 | Then I'll say OK again.
| | 03:22 | Now, when a user chooses a date, no
matter what date they choose, it will
| | 03:26 | appear using that format.
| | 03:30 | We have one more date in our form, and
that's the date that says if this is news,
| | 03:35 | when does it expire?
| | 03:36 | Remember that this news category asks
the user to say, should this go on the
| | 03:40 | homepage of our company's Internet or intranet?
| | 03:44 | And if so, is it newsworthy, and for how long?
| | 03:49 | So let's go down to the news section,
and let's add that second control that
| | 03:54 | has Expiration Date.
| | 04:00 | Let's add this one by dragging this
over here, and if it's a Date field, sure
| | 04:04 | enough, we'll get a date picker,
which is always nice to have.
| | 04:10 | In this case I actually want to use a
different format, because if the user
| | 04:17 | tells me that it expires on a date, I'd like
them to be aware of what day of the week that is.
| | 04:22 | So, for example, if the user is telling
me that this is newsworthy until March
| | 04:27 | 14, I'd like them to know that
| | 04:30 | that's a Wednesday, so that they can
double-check and say oh, no, I didn't mean
| | 04:33 | that this would expire on a Saturday.
| | 04:35 | So that's an additional piece
of information I'll provide.
| | 04:38 | I'm not going to mark Cannot be blank right now.
| | 04:41 | We'll talk more about that later.
| | 04:43 | I believe that I may have to provide
some more space for this, because a
| | 04:47 | Wednesday in November will
take up a little more space.
| | 04:50 | So I am simply dragging this control
over, which is stretching it out, or dragging
| | 04:54 | the boundary of the cell in the table,
which actually doesn't change the control
| | 04:59 | size, but moves it to the left
so that I could make it larger.
| | 05:03 | Let's now go into Preview, and let's
take a look at what we've done with
| | 05:07 | these two date controls.
| | 05:09 | Here we have a date that
has a default setting.
| | 05:13 | Here when I choose a date, I get a
full set of text, because that's the
| | 05:18 | format that I chose.
| | 05:20 | Notice also the asterisks here will let the
user know that these fields are required.
| | 05:25 | If not the first InfoPath form they
come across, by the second or third,
| | 05:29 | they'll figure it out.
| | 05:31 | Date controls are powerful and easy to use.
| | Collapse this transcript |
| Using list boxes and combo boxes| 00:00 | In our requestor group, we have a field that
asks the user what department they are in.
| | 00:05 | If you ask users to enter
information with which they're familiar, like
| | 00:09 | department, it's surprising what a
wide range of information you'll get.
| | 00:14 | For example, you have someone who works
in accounting services, and some people
| | 00:18 | will type 'accounting services' and
spell them out. Some people would type
| | 00:23 | them in with no uppercase letters.
Some other people would simply put
| | 00:26 | accounting. Some would put
'accounting svcs'. Some people would put 'acct' and so on.
| | 00:34 | With that wide range of entries just
for a simple two-word department name, it
| | 00:39 | makes it really hard to be able to
report how many requests for posts did we get
| | 00:45 | from the accounting department.
| | 00:46 | If we want to be able to report on a
field, it behooves us to make it easy for a
| | 00:51 | user to choose from a set group of options.
| | 00:54 | Users like this too because they don't
have to wonder what they should put in,
| | 00:58 | and they are unlikely to make spelling
mistakes unless you made them for them.
| | 01:02 | So we're going to create a list that's
going to go here for us to be able to
| | 01:07 | enter department name.
| | 01:08 | We have several choices of list boxes
that are available in InfoPath 2010.
| | 01:14 | We have a simple dropdown list that
allows the user to choose one item.
| | 01:20 | We have a multiple selection list box
that allows users to put checks in front
| | 01:26 | of multiple options.
| | 01:28 | So they could choose a and b.
Finally, we have a Combo Box control that
| | 01:33 | allows the user to choose from a list or
enter a selection if it's not on the list already.
| | 01:39 | The type of list box we choose then
depends on how comfortable we are that we've
| | 01:46 | provided all the choices that users will want.
| | 01:49 | If we feel there might be choices
that we don't include on our list, either
| | 01:53 | because they're infrequently used or
it's information that we're not privy to,
| | 01:58 | then we'll need to use a combo box,
because the Combo Box control allows the
| | 02:02 | user to enter something we haven't entered.
| | 02:05 | If on the other hand, we know that we
have a closed universe--for example, we
| | 02:09 | take five credit cards, Visa and MasterCard,
American Express, Diners Club, and Discover.
| | 02:16 | We're not going to take another kind
of credit card, even if someone chose it
| | 02:19 | from a less or typed it in. Then
we could use a dropdown list box.
| | 02:24 | Or we might want to have a user be able
to make more than one choice, to say that
| | 02:30 | I actually work part-time in one
department and part of the time in another.
| | 02:34 | If we have users that are identified
with more than one department or want to
| | 02:39 | split their bill across more than one
credit card, then we'll need to allow them
| | 02:43 | to use this multi-selection, or what's
commonly called a multi-pick list box.
| | 02:47 | Let's begin with a regular dropdown List.
| | 02:50 | So if I click here where I want my
control to go and then click the dropdown
| | 02:54 | list, once again a new field will be
created, and I don't really want one.
| | 02:58 | This is bound to another field.
| | 03:00 | So let's go ahead and change the
binding here to the requestor's dept,
| | 03:05 | or department, say OK.
| | 03:06 | It's always a good habit to delete
this field right away, but if not, you
| | 03:11 | will find them at the end, because they
will all be named field, which is nice and easy.
| | 03:15 | Let's label this field Department.
| | 03:18 | Now we can go to the Control Tools >
Properties and choose Control Properties or
| | 03:23 | right-click here and choose Drop-Down
List Box Properties. And this is one of the
| | 03:29 | most extensive properties
boxes we've seen so far.
| | 03:32 | So we have different ways that we
can fire up choices for this list box.
| | 03:39 | One way is to enter a list of choices
manually, and that's what we'll be doing.
| | 03:43 | However, if you are developing a
form and that list of choices exists
| | 03:48 | somewhere else--in Excel, in Outlook,
on a SharePoint site as a list--don't
| | 03:54 | start copying that information.
| | 03:56 | Later in the course, you'll see how you can
get choices from an external data source.
| | 04:01 | Then finally, we could've had someone
already fill in some information, and we
| | 04:06 | want to return to the list of
information they provided and say, what's your
| | 04:10 | first choice out of this list?
| | 04:12 | That's how we would get choices from
fields in this form, and we'll see how to
| | 04:15 | do that later as well.
| | 04:17 | But let's assume that this list of
choices doesn't exist anywhere, is a
| | 04:21 | relatively static list, is also a good thing, and
| | 04:24 | let's go ahead and make our selections.
| | 04:27 | Now it's traditional in this kind of a list
box that the very first item would say Select.
| | 04:32 | Then we'll add another item.
| | 04:34 | When I click the Add button,
an Add Choice dialog box opens.
| | 04:37 | I have five departments
I am going to enter here.
| | 04:42 | When I press Enter, notice that
the Add button gets focused again.
| | 04:47 | So if I enter again, it will just open it
again, and I can then very quickly enter.
| | 04:51 | If I make a mistake, I can modify.
| | 04:58 | I can then really quickly
enter each of these items.
| | 05:11 | With my items in place and in order,
I'm ready to click OK. If I wanted to move
| | 05:16 | these around for any reason, I could
select the item I want to move and choose
| | 05:20 | either Move Up or Move Down.
| | 05:23 | If the bulk of the people who are
filling out this form are in a particular
| | 05:26 | department, I could choose
it and make it the default.
| | 05:30 | I should then move it to the top of
the list and delete the Select choice.
| | 05:35 | This list should always be in an
order that your users understand.
| | 05:39 | Alphabetical order is best, unless
there's a dominant value you want to set
| | 05:43 | as the default. If this is a numerical list,
smallest to largest or largest to smallest.
| | 05:49 | Because there's already a choice in here,
when I say Cannot be blank, it would
| | 05:53 | seem like it really can't be blank,
but it ism because there's no value.
| | 05:57 | So if I choose Cannot be blank, a user
will be forced to choose a department
| | 06:01 | other than the word Select.
| | 06:03 | I'm going to go ahead and
say that this Cannot be blank.
| | 06:07 | Let's go back to the Home tab and click
Preview to see how this dialog box works then.
| | 06:12 | There's my list.
| | 06:13 | A user selects from the
list. Seems to work fine.
| | 06:20 | Now what if instead of a dropdown
list, I had a multiple selection List?
| | 06:25 | Let's go ahead and delete this control and
let's place a multiple selection list in.
| | 06:33 | Notice that we have a longer box
because the user will need to click items,
| | 06:37 | and let's go ahead and see what it looks
like to set the properties of this list box.
| | 06:42 | We're going to enter choices manually
again, and we will simply add these items.
| | 06:47 | I'm going to quickly add them.
| | 06:48 | So now I have all of my items entered.
| | 06:51 | I haven't bound the field on this. That's okay.
| | 06:56 | We can do that later.
| | 06:57 | What I can do is I can say either that
it cannot be blank or that at least one
| | 07:02 | selection is required.
| | 07:06 | Cannot be blank is almost the same
as at least one selection is required,
| | 07:10 | except if I have a default value in this case,
because it has a value, there is no set default.
| | 07:17 | It actually acts as if
it's not blank to start with.
| | 07:20 | So I am going to say that the user
has to at least choose something.
| | 07:23 | Notice I also have a choice to
allow users to enter custom values.
| | 07:27 | We'll look at that in a minute.
But let's see how this box behaves to begin with.
| | 07:31 | When I go to preview, the user has the
opportunity to select as many things here as they wish.
| | 07:38 | Notice that there's a scrollbar,
but it doesn't scroll much.
| | 07:42 | Our control is just a little bit too small.
| | 07:45 | We are going to size it to get rid of that.
| | 07:49 | Notice that the g at the
bottom of marketing is cut off.
| | 07:53 | I am going to just make
this a little bit larger.
| | 07:55 | Go back to Preview. No scrollbar. Excellent!
| | 08:00 | Who'd want to scroll in that teeny-tiny box?
| | 08:03 | What happens if I allow the
user to enter other values?
| | 08:09 | Let's go back to the List Box
property, and we'll allow a user to enter
| | 08:12 | some custom values.
| | 08:14 | Now when we go into preview, at the
bottom, there will be a choice already
| | 08:19 | checked where the user can enter.
| | 08:22 | They wouldn't know this was here.
| | 08:24 | If I'm going to do this, I need to once
again make space for it. Very useful!
| | 08:31 | So now a user can choose as many
items as they wish or enter an item that
| | 08:37 | they want to select.
| | 08:40 | That's the multiple selection list box.
| | 08:42 | Our third choice here is a combo box.
| | 08:45 | A combo box is very similar to a
dropdown list and very similar to the
| | 08:51 | multi-selection List.
| | 08:53 | Let's see how a combo box works.
| | 08:55 | In a combo box, I have the choice, as I
do in the dropdown list, to choose any one
| | 09:00 | item. But as with the multi-pick list
box, I have the ability to enter an item, to
| | 09:07 | type an item in that I'd like to have.
| | 09:10 | So let's go ahead and look at the
properties here of our combo box.
| | 09:14 | You'll find that they're very similar.
| | 09:16 | I am going to speed-enter
all of this information.
| | 09:19 | I'm actually just typing.
| | 09:22 | But through the magic of
editing, our editors will speed it up.
| | 09:27 | So here's how this looks.
| | 09:28 | If I want to force a user choice, I
choose Cannot be blank. I'm all set.
| | 09:32 | I am going to choose OK.
| | 09:35 | Now let's preview this
combo box and see how it looks.
| | 09:37 | It says Select or type.
| | 09:39 | It doesn't simply say select.
| | 09:40 | The user can choose an item or a
user can enter an item, either way.
| | 09:47 | Let's close the preview.
| | 09:48 | So three different types of list
controls: a combo box which allows the user
| | 09:54 | to choose or enter one thing; a dropdown list
which only allows a user to choose one thing,
| | 10:01 | no typing; and finally, a multiple
selection list box, which is the most
| | 10:06 | permission-giving of all the lists,
because a user can not only choose multiple
| | 10:10 | items, but if you enable the property,
they can add an item to the list that
| | 10:14 | didn't exist already.
| | Collapse this transcript |
| Using bulleted and numbered list controls| 00:00 | There are two different types of
controls that have the word 'list' associated
| | 00:04 | with them, the Drop-Down List, Combo Box,
and Multiple Selection List controls
| | 00:08 | that we just looked at that
are used to allow user choice.
| | 00:12 | There are then again three controls called
Plain List, Bulleted List, and Numbered List.
| | 00:17 | These controls are actually
a form of the Rich Text Box.
| | 00:22 | If we place a rich text box on a form,
the user can type bulleted lists,
| | 00:27 | numbered lists, and plain lists in them.
| | 00:29 | However, sometimes we actually want to make
sure that a user provides a numbered list.
| | 00:35 | For example, list the steps needed to
do X. Or, a bulleted list, which makes it
| | 00:41 | clear that we don't want paragraphs of text.
| | 00:43 | We want short pieces of text.
| | 00:45 | The same with the plain list.
| | 00:47 | So we're providing not just the
ability to add rich text, but we are
| | 00:51 | constraining it to a particular type of list.
| | 00:55 | I'm going to enter first
a Plain List control here.
| | 00:58 | We are simply going to click where it
says Add control and drop in a plain list.
| | 01:05 | Notice that there's a field
associated with it and a group.
| | 01:09 | You might wonder, why a group?
| | 01:11 | Because they'll be more than one item that
will repeat, and it will go into this group.
| | 01:16 | We would rename these if we wish,
but let's just go preview and see how it looks.
| | 01:20 | So when I type in the plain list and
I type, for example, 'Alabama', and press
| | 01:25 | Enter, note that it allows me
to continue the list, and so on.
| | 01:34 | Let's close the preview and
look at the Bulleted List control.
| | 01:39 | Once again, when I click the Bulleted
List control, InfoPath will create a group
| | 01:45 | that would be associated with all the items.
| | 01:48 | So if this was a list of software
and inventory, we would rename this
| | 01:52 | group something like 'inventory', and
we would name the individual item
| | 01:58 | within it 'software'.
| | 02:04 | Let's see how this works.
| | 02:06 | So I click in my bulleted list
and I type 'Microsoft InfoPath'.
| | 02:15 | When I press Enter, I get a new line
and a new bullet point, 'Adobe Acrobat Pro',
| | 02:24 | 'Microsoft Excel', and so on.
| | 02:28 | Finally, the numbered list is also going
to work in a predictable way and create
| | 02:32 | fields in a predictable way.
| | 02:34 | I click where I want the control to go,
| | 02:36 | click on Numbered List, and again I'll
have to name both the group and the field,
| | 02:41 | but when I click Preview,
I will get a list of steps.
| | 02:59 | Now each of these controls
also has some properties.
| | 03:02 | If we look at the properties of the
Plain List, you'll see that it will allow
| | 03:07 | you to actually have a
button that says Insert item.
| | 03:11 | So you could say 'Insert another list
item', for example, and if we look at that
| | 03:17 | in Preview, you'll see that there's a
place for the user to click and continue
| | 03:21 | entering items. Even without that
though, this list box was pretty easy to use.
| | 03:28 | If we look at the properties of our
bulleted list, you'll find that we have a few.
| | 03:36 | We have the ability to show an insert
button and hint text, insert another
| | 03:40 | bulleted item. But other than that, as
with the plain list, not many choices.
| | 03:47 | Our Numbered List Properties, again we can
show an insert button and hint text if we wish.
| | 03:56 | We can set an initial default value.
| | 03:58 | Basically, what you would expect and
similar to the properties that we see if we
| | 04:03 | choose the Rich Text Box control.
| | 04:09 | If you want to allow a user to enter a
list, any of these four controls work.
| | 04:15 | The Rich Text Box control, when a
user uses it, they simply click and then
| | 04:21 | choose that they want to enter,
for example, bulleted text.
| | 04:25 | However, if you want to constrain your
user to a particular list, a numbered
| | 04:30 | list, a bulleted list, or a plain list,
then feel free to choose the appropriate
| | 04:35 | list control here in the
Input Controls dropdown.
| | Collapse this transcript |
| Using checkboxes| 00:00 | The check box control is used when
you want to provide your user with two
| | 00:05 | different choices: yes or no, true and false,
0 or 1, in or out, checked or unchecked.
| | 00:13 | Check box controls are really easy to
place and are used for this type of field,
| | 00:17 | which is called a Boolean field.
| | 00:20 | We have two different places that we need
to use a check box in our form right now.
| | 00:24 | One is the question in the news group
of our data sources, is this item news?
| | 00:29 | By that we mean does it belong on the
front page of the Internet or the intranet
| | 00:36 | site for that day or for a few days?
| | 00:39 | Does it make it to the news page?
| | 00:41 | So let's go ahead and place
this check box really quickly.
| | 00:44 | Here is our Check Box control.
| | 00:46 | So I'm going to enter the label, and I might
have to provide some kind of a user tip here.
| | 00:56 | If I drag isnews and drop it, you'll
find that it actually places a check box
| | 01:02 | because again, this field
here has the data type Boolean.
| | 01:06 | I am simply going to delete the
text that's provided, works just fine.
| | 01:13 | The other place we need to add a
control is at the point when we're posting the
| | 01:17 | file and the user has the option to
say, would you create a PDF please?
| | 01:21 | So I'm going to click here and say
'Create PDF', and then we can either drag, or
| | 01:29 | I'm going to create this check box here
by using the control. And then we know
| | 01:34 | that we'll need to bind that here,
and then we can delete the extra field.
| | 01:44 | So let's take a look at the
properties of a Check Box control.
| | 01:49 | If I choose Control Properties here on
the Control Tools > Properties tab, what
| | 01:54 | you will find is that in addition to
the Field name and the Data type you have
| | 01:58 | the ability to start this check box
off as either checked or unchecked.
| | 02:03 | So if we preview this right now, the
check box is unchecked, and the user
| | 02:11 | can check, uncheck it.
| | 02:15 | The other possibility is that I'd
like to take this check box and say we'll
| | 02:20 | start with it checked, and I do that by
choosing Checked rather than Cleared.
| | 02:26 | Here's what we know.
| | 02:27 | A user is far more likely to check a
cleared box than to clear a checked box.
| | 02:35 | So if I really want to know that the
user is choosing something, I'm almost
| | 02:39 | always going to start with this
in a Default state of Cleared.
| | 02:42 | Even if this means rearranging your
question that says you know check if this is
| | 02:48 | not news, you want to try to get to a
point where your default state is Cleared
| | 02:53 | based on the text that you
are providing as a label.
| | 02:57 | You also can choose how the Cleared and
Checked status is stored in the data source.
| | 03:03 | By default, if the check box is Cleared,
the word 'FALSE' is stored and if the
| | 03:08 | check box is Checked, the
word 'TRUE' will be stored.
| | 03:12 | But you have another set of choices.
| | 03:14 | You can choose 0 and 1.
| | 03:17 | Now, although you could say that if it's
Cleared, you'd like it to be TRUE, that
| | 03:21 | is such a bad idea, because many check
boxes in other applications don't allow
| | 03:28 | you to choose the inverse,
so just stay away from that.
| | 03:31 | If it's Cleared, it should either be FALSE or 0.
| | 03:36 | If it's Checked, it should either be TRUE or 1.
| | 03:40 | Storing a 1 and a 0 works because if you
see a check box and it's checked and it
| | 03:45 | passes a numeric value to you,
just know it will be true.
| | 03:49 | It should always be true because
everybody else should set up their forms the
| | 03:53 | same way that we are.
| | 03:55 | The reason you might want to send a 0 or a
1 is you can use that 1 in a calculation.
| | 03:59 | You could, for example, add together
the value of checked check boxes.
| | 04:04 | I have four check boxes.
How many did the user check?
| | 04:07 | Well, let's add them all up and see.
| | 04:09 | The reason I might want to use TRUE
and FALSE, however, is if I'm publishing
| | 04:14 | this form to a SharePoint site, or I'm
publishing this data out of this form in
| | 04:19 | others, later on in Excel or in a
database in a way that users see this.
| | 04:25 | If there was a column that at the
top said 'news?' users understand the
| | 04:30 | words TRUE and FALSE.
| | 04:32 | They don't necessarily
understand the value of 0 and 1.
| | 04:36 | So if you're going to share this data
with users later, it's a good idea to
| | 04:41 | leave TRUE and FALSE;
| | 04:42 | if you need a calculation, 0 and 1 are nice.
| | 04:45 | Having set our properties, we're just
going to click OK, and any time that we
| | 04:50 | have something where a 0 or 1, true
and false, works, a check box is the great
| | 04:55 | control to use for that.
| | 04:58 | One other note about check boxes.
| | 05:00 | When the user is actually using this form,
I cannot tell that they actually read,
| | 05:07 | "Is this post 'news'," and checked
and turned the check box on or off.
| | 05:12 | What I can infer from this is I can
infer that if this isn't checked, one of
| | 05:17 | two things happened: either it is not news,
or they didn't look at this part of the form.
| | 05:23 | Same thing is true with Create PDF.
| | 05:25 | If the check box isn't checked, I'll
think they don't want a PDF. And later on
| | 05:29 | when there isn't one posted,
they might call and say, hey!
| | 05:32 | I wanted a PDF and I say you
didn't check it. And they say, hmm!
| | 05:35 | I didn't see it on the form.
| | 05:37 | It doesn't matter at any cosmic sense
whether this post goes on the front page,
| | 05:41 | or we create a PDF, most of the time.
But there are times I absolutely need to
| | 05:47 | know that a user either checked or
chose not to check this check box.
| | 05:52 | And because I can't know that, there are
times that I won't use a check box, but
| | 05:56 | instead I'll use a dropdown list.
| | 05:59 | Let me give you an example.
| | 06:01 | I created a form a couple of years ago
for a patient intake center where when
| | 06:06 | people called in, the person doing
intake and referral had to go down a check
| | 06:10 | list and ask them specific questions.
| | 06:13 | For example, they needed to ask
questions like, "Are you suicidal?" and in that
| | 06:17 | case, it's not good enough to have a
check box that somebody can overlook because
| | 06:23 | if you forget to ask the
question, it's problematic.
| | 06:26 | This clinic needed to know
accurate information about its patients to
| | 06:30 | make accurate referrals.
| | 06:32 | In that case, they chose not to use
check boxes in their form; instead they
| | 06:37 | inserted a dropdown list, and in the
dropdown list there were three choices:
| | 06:42 | Select, which was the default, Yes, and No.
| | 06:51 | When this control then was previewed,
I can tell that the user filled it out.
| | 06:58 | With the check box I wasn't sure,
but this is how it looks when it's ignored.
| | 07:04 | These are the choices when
the user actually made a choice.
| | 07:08 | So check boxes aren't good for every
single occasion where there are two
| | 07:12 | choices, but most of the time they are
precisely the correct control to use in a
| | 07:17 | world of yes/no, true/false, 1/0.
| | Collapse this transcript |
| Using option buttons| 00:00 | Just as check boxes are the best
control in a universe of only two choices,
| | 00:05 | option buttons are the best control in
a universe of three or four or perhaps
| | 00:10 | five choices, where a user
can only choose one item.
| | 00:14 | Option buttons then are an alternative
to dropdown lists, and option buttons
| | 00:19 | present clear choices, unambiguous
choices, that you can easily see on the form,
| | 00:25 | so the option buttons give users a
choice to kind of rock back and say, which of
| | 00:29 | those choices do I want?
| | 00:30 | We are going to create some
option buttons here for the posttype.
| | 00:35 | There are four specific
choices that a user has here.
| | 00:39 | They can say please post only
the description that I sent.
| | 00:44 | The second choice is post a description
with a link to a file that I have attached.
| | 00:48 | The third choice is post this description
along with the contents of the file on the page.
| | 00:55 | And the fourth choice is post this
description with a link to somewhere else on the site.
| | 00:59 | For example, that fourth choice might
be I want to post an announcement and
| | 01:04 | point people back to
another section of the site.
| | 01:07 | So, posttype is going to go right here.
| | 01:12 | Let's go ahead and drop in option buttons.
| | 01:14 | It's important that I know that there
are four options, because the moment I
| | 01:18 | choose the option button control,
I'm asked how many option buttons there
| | 01:22 | will be altogether.
| | 01:24 | Up until now, InfoPath
has been fairly forgiving.
| | 01:27 | If we insert a control and we want
to move it, or change our minds about
| | 01:31 | it, it's pretty easy to modify it, but the
number of option buttons is not a property.
| | 01:37 | When we select four option buttons, it will
actually create four of them as a set together.
| | 01:41 | And it's a little bit more
difficult to add another option button, not
| | 01:45 | impossible, but it's just a little harder.
| | 01:47 | So, rather than choosing some number randomly,
find out how many choices you have first.
| | 01:52 | Here are my four option buttons and
again, they're bound to this new field
| | 01:57 | that was put in, field3.
| | 01:58 | But I actually need them to be bound
to posttype, so I'm going to right-click
| | 02:03 | and change their binding.
| | 02:08 | And I am going to do this four times.
| | 02:24 | Now, it helps if I just click on
each point to them and see, there we go.
| | 02:27 | They are all bound to the right control.
| | 02:29 | I can get rid of field3. All good.
| | 02:32 | I need to enter text,
and I have my four choices.
| | 02:38 | I can either add them in some kind of
alphabetical order, although they all
| | 02:42 | start the same way, or in this case
I'm going to put the option that I
| | 02:46 | believe is the default option at the top, so
Description only, and I can just arrow down.
| | 02:54 | In this case if I press Enter, it actually
creates some space, so I don't want to do that.
| | 02:58 | And Description with link to file,
Description with file content, and finally,
| | 03:10 | Description with URL link.
| | 03:14 | We'll have to find a way to
capture that later, which we'll do.
| | 03:17 | I'd like to make a little more space for this.
| | 03:19 | I am simply going to slide this over
because we have a lot of room because this
| | 03:22 | Check Box control doesn't
take up much space at all.
| | 03:25 | Let's now take a look at the
properties of option buttons.
| | 03:29 | You'll note that each option
button has a value when it's selected.
| | 03:34 | This one, for example, is the first
option button, and its value is 1.
| | 03:38 | The second option button's value, not
surprisingly, is going to be two, and just
| | 03:43 | trust me that the next two
are going to say three and four.
| | 03:47 | Now, you might want to use those
numbers to do specific actions.
| | 03:51 | You might, for example, need
to use them in a calculation.
| | 03:55 | But if you don't, you should change
these values so that they make sense, when
| | 03:59 | you do something like see this
data with simply a heading at the top.
| | 04:04 | Because if the heading said posttype
and all we stored in terms of data or
| | 04:09 | passed along was one, two, three or
four, somebody at the other end, in the
| | 04:13 | Office of Electronic Services, needs
a little sticky note that tells them
| | 04:16 | what one means, or two.
| | 04:18 | And we can so easily go in and simply
say that when someone selected one that
| | 04:24 | they want to have the description only.
| | 04:26 | And I can even use probably some pretty
decent shorthand here because the people
| | 04:31 | who are reading this know that
they're looking for a posttype.
| | 04:34 | So like this can say Desc/file link,
and I'm just going to come up with a
| | 04:44 | charming description for each one of
these that will make some sense downstream:
| | 04:48 | Desc/file content and then Desc/URL.
| | 04:58 | If I wanted to put all the text in
there, it wouldn't hurt for me to do that.
| | 05:05 | And I could copy/paste the
text from here into here.
| | 05:09 | Now there's one other property that I
have, and that's that one of the buttons
| | 05:13 | is selected by default.
| | 05:14 | Let's slide over and preview what this
section of our form looks like real quickly.
| | 05:19 | Right now, no button is selected,
and so if I click, it chooses whatever item I
| | 05:26 | click, and when I choose a different
option button, the first one is unselected.
| | 05:32 | That's how option buttons work.
| | 05:34 | I can only choose one.
| | 05:35 | So, let's go ahead and make
this very first choice our default.
| | 05:44 | Change its properties.
| | 05:45 | This button is selected by
default, Description only.
| | 05:49 | If I apply it, I can
actually see it there and say OK.
| | 05:54 | So a small universe of
choices, but a total universe.
| | 05:57 | These are the four things that we'll
do as a result of having received this
| | 06:01 | particular post information.
| | 06:03 | I think this looks great.
| | 06:04 | Don't be afraid to use option buttons
any time you have three or more options.
| | 06:09 | If you only have two options, then the
choices should more likely be a check
| | 06:14 | box or a dropdown list.
| | Collapse this transcript |
| Changing the control type| 00:00 | As you're placing controls on your
form and testing your form, having other
| | 00:04 | users look at it, you might decide
that you need to change the type of one of
| | 00:08 | the controls on your form.
| | 00:09 | For example, we have here a dropdown
list control and we might decide that we
| | 00:15 | want to change that control to something else.
| | 00:17 | For example, we might want to change
that to a plain text box--here we go--or
| | 00:23 | we can take our text box and we could
change that control to be a combo box, or
| | 00:30 | change the control to be a regular list box
that's larger that they will multi-pick from.
| | 00:35 | So simply right-click on a control,
choose Change Control, and you'll see all
| | 00:40 | of the possible controls that you
could use for this type of data that's
| | 00:46 | stored in this control.
| | 00:48 | I can tell that I'm actually looking at
a text control here because all of the
| | 00:52 | choices are choices that
store text in one way or another.
| | 00:57 | Let's take a look then at this
control that currently is a place that users
| | 01:02 | would type in the description.
| | 01:04 | I'd like them to be able to format this text.
| | 01:07 | So let's go ahead and change this if
we can to a rich text box, and we'll
| | 01:12 | find that we can't.
| | 01:14 | The reason is that even if a user
enters rich text here, I can't store it here
| | 01:20 | because this is a string
field in my data source.
| | 01:24 | So in order to change this to a rich
text control, I actually have to change the
| | 01:29 | data source as well.
| | 01:30 | Let's go ahead and do that.
| | 01:32 | Let's change its Properties and say you
know we would like people to be able to
| | 01:36 | enter rich text here.
| | 01:39 | When I say OK, the form
control tells me, "I have a problem.
| | 01:45 | I'm only a simple text box.
| | 01:48 | I don't know how to let people type rich text."
| | 01:51 | That's easy then because
we're going to right-click,
| | 01:54 | change the control to a rich text box.
| | 01:58 | If we chose More Details, we
could actually get some information.
| | 02:01 | It says it can't store data because
it's bound to a field with the data type
| | 02:06 | that doesn't match the control.
| | 02:08 | So right-click, change control to a
rich text box and once again, the binding
| | 02:14 | works, and everything is fine.
| | 02:16 | Anytime you want to change an
existing control, simply right-click, choose
| | 02:19 | Change Control, and you'll see
the options that are available.
| | 02:23 | If you need to have a different type
of control, you may need to change your
| | 02:27 | data source in order to be able to support it.
| | Collapse this transcript |
|
|
6. Setting Options and Formatting ControlsFormatting labels| 00:00 | If you want to change the entire look
and feel of your form, don't begin by
| | 00:04 | using the formatting tools; begin
instead by switching over to Page Design and
| | 00:09 | choosing a different theme.
| | 00:11 | But if you like the theme and simply
want to make adjustments in some of your
| | 00:15 | labels, here's how you can think about doing it.
| | 00:17 | For example, in the center of my
form I have two items that I have a
| | 00:23 | backshading on them so that they'll stand out.
| | 00:26 | This is actually the most important
information in this part of the form that
| | 00:29 | says what the post title is and the
post description. I want it to jump out
| | 00:33 | for the person who ultimately needs to
fill out information and create a post
| | 00:37 | based on this form.
| | 00:39 | But one result of that shading is that these
two labels don't really stand out very much.
| | 00:44 | So I'm going to switch over to the
Home tab, and I'm going to choose a darker
| | 00:50 | color for these labels, so they will
better stand out against the background.
| | 00:54 | Here are my Theme Colors, and here they
are at 90%, 75%, and so on, lightening.
| | 01:01 | I'm going to simply grab a darker
brown, and those already look better.
| | 01:07 | At the top, I have a placeholder for
some information that will be provided by
| | 01:12 | the staff about this form.
| | 01:14 | So I'd like to have this descriptive text--
not label text but form descriptive text--
| | 01:20 | have a different font than
anything else in the form.
| | 01:23 | Throughout this form, Calibri is used generously.
| | 01:26 | It's used in my titles.
| | 01:27 | It's used every place else.
| | 01:28 | So by simply switching to another font,
I can make this text look different than
| | 01:35 | anything else on the form, without
putting it in a box or changing it to a
| | 01:39 | dramatically different color.
| | 01:41 | So let's go find a font that looks good with
Calibri. And you might wonder, how would I know?
| | 01:47 | Well, there's nothing in InfoPath
to tell you, but you can rely on the
| | 01:52 | experience that you already have in
other Office applications, like Word, Excel,
| | 01:57 | and PowerPoint, that have themes
that are created using two fonts.
| | 02:02 | So if you'll recall, the font that is
most frequently used with Calibri is the
| | 02:07 | font Cambria, and I can find it
down on the list, under the Cs.
| | 02:12 | Another good choice that's a little bit
more decorative, it's just a little bit
| | 02:17 | further down the list, and it's a font
called Constantia--again more decorative,
| | 02:21 | more for headings than for
text you want someone to read.
| | 02:26 | So I'm going to choose Cambria here.
Cambria, Calibri, Constantia, Consolas,
| | 02:32 | all of these fonts were actually
created for the latest version of office as
| | 02:36 | highly readable fonts.
| | 02:39 | So when I click, you'll notice that even
though this is a serif font, it's easier
| | 02:43 | to read than Times New Roman.
| | 02:45 | It stands out and looks different,
and then one more thing I can do is change
| | 02:49 | its color so that it
doesn't look like a label anymore.
| | 02:53 | So when I replace this with the text from
the electronic communication step, I can
| | 02:57 | expect that this is going to look good
and still looks resonant with the form.
| | 03:02 | You have the ability to bold,
italicize, and underline text.
| | 03:07 | You don't want to highlight text in a form.
| | 03:09 | This is a tool that you will most use
as you're going through the form to note
| | 03:13 | changes that you need to make.
| | 03:15 | It's an invaluable tool
while you're in Design mode.
| | 03:18 | It's not the way you would
like to mark text for use later.
| | 03:22 | If you decide that you would like to
bold required fields--that's something that
| | 03:27 | some designers do--you can bold this one.
| | 03:30 | Then I can use the Format Painter
and bold other fields in the same way,
| | 03:35 | double-click to make it stay on,
and click again to turn it off.
| | 03:48 | So using the tools that you already know
how to use from Microsoft Word or other
| | 03:53 | Office applications, you can easily
format the labels in your form here in
| | 03:58 | InfoPath Designer 2010.
| | Collapse this transcript |
| Formatting controls| 00:00 | In the last movie, we used tools in the
Format Text Group on the Home tab to be
| | 00:05 | able to format labels in our form--
| | 00:08 | first name, this descriptive text--
but when we want to format controls, there is
| | 00:14 | a much better way than through
the use of the Format Text tools.
| | 00:19 | Let's first take a look at how we could
change the entire look and feel of the
| | 00:23 | form--and a reminder that you
do that over here in Themes,
| | 00:26 | that changing themes
changes not only colors, but fonts.
| | 00:30 | But let's say that we wanted to change
all of the fonts in our text boxes here.
| | 00:35 | On that same Page Design tab,
you'll see a group that's called Views.
| | 00:39 | In the Views group, you have the ability to
change a lot of the properties of a view.
| | 00:43 | We haven't talked about views yet.
| | 00:46 | We will talk about them later in the
course. But a short description is that a
| | 00:50 | view is one version of a form
that works with this data set.
| | 00:54 | So we could create yet another form that
only included this part of our data and
| | 01:01 | save it in the same template,
| | 01:02 | the idea being that different users
might have needs for different views.
| | 01:06 | We only have one view right now, and so
for our purposes, we could think of the
| | 01:12 | view as what we see here on the screen,
the form that we're creating, to allow a
| | 01:18 | user to enter data into these fields.
| | 01:21 | I'm going to click Properties to open
the View Properties dialog box and then
| | 01:25 | click the Text Settings tab,
and what you'll see on the left is a list of
| | 01:29 | controls that can contain text
and that you can set properties for.
| | 01:34 | So, for example, here's all the
Text Box controls in the form.
| | 01:39 | Here's our Rich Text Box control, here
are our date pickers, our single dropdown
| | 01:45 | list box, our one combo box, and so on.
| | 01:48 | So if I want to change the font for
all of the text boxes in my form at one
| | 01:53 | time, I'm simply going to slide up here,
and we're going to choose Cambria just
| | 01:57 | so we can see it, and say OK.
| | 02:02 | Let's go Home, click the Preview button,
and when I start typing in this form, it's
| | 02:07 | Cambria. So is the next
text box, and the next one.
| | 02:14 | Today's date, on the
other hand, is not a text box.
| | 02:17 | It's a date picker. And so it still uses
Calibri. And if I wasn't sure, I can click
| | 02:21 | in it and read it up here in the
Font group in the InfoPath Filler.
| | 02:26 | Likewise, this list, which is a combo
box, is still Calibri as well, but every
| | 02:34 | single text box is now using Cambria.
| | 02:38 | I won't want to leave the form that
way, but you understand how that works.
| | 02:43 | I want to give you a caveat here.
| | 02:45 | If you've already gone in and formatted
a text box individually, when you switch
| | 02:51 | them from Calibri to Cambria,
it may not actually change.
| | 02:55 | So if I change this text box, for example,
to Bookman Old Style and I do it with
| | 03:01 | the tools here in the Format Text group,
that local change will usually override
| | 03:08 | a global change that I make my using
the Text Settings for the view properties.
| | 03:13 | Not always, but most of the time, the
changes that I make here override those
| | 03:18 | more global changes.
| | 03:19 | Therefore, you really don't want to
be formatting here unless there is a
| | 03:24 | really good reason to.
| | 03:25 | For example, this might be the most
important piece of text in this entire form,
| | 03:32 | and because of that, we might say, no
matter what else we do, we want the
| | 03:35 | contents of this control
to be bold, so we bold it.
| | 03:39 | That makes perfect sense.
| | 03:41 | Let's go back now to Page Design,
View Properties, Text Settings.
| | 03:47 | If you wanted to change then all the
control types, you'd simply slide one to the
| | 03:51 | next, and you change them
in whatever way you want to.
| | 03:54 | If you wanted our date picker to be Calibri
or Cambria, you would change it here as well.
| | 04:00 | I'm going to change our text
boxes back to Calibri and say OK.
| | 04:11 | Now when we go back into Preview
and I type, we are all back in Calibri.
| | 04:19 | The single change I made to the
field post title to make it bold has been
| | 04:23 | discarded as I switched back from
Cambria bold to Calibri without bold.
| | 04:29 | If I want to do specific kinds of
formatting to individual fields, I should make
| | 04:34 | sure that I've made all the changes I'm
going to make to my Text Settings at my
| | 04:39 | properties level, and then go back
and simply bold that single field.
| | 04:45 | So that's how we format control
groups and individual controls in
| | 04:48 | InfoPath Designer.
| | Collapse this transcript |
| Catching incorrect or missing data| 00:00 | We're creating this form because
we would like to collect really good
| | 00:04 | information from users, and good in this
sense means valid and accurate and complete.
| | 00:09 | We make it easier for a user to give us
really good data by providing some kind
| | 00:13 | of structured feedback when they give
us data that we think might be wrong.
| | 00:18 | There's a notion about how data is
collected called source data capture, and in
| | 00:23 | a nutshell what that means is that the
closer you get to the owner of data, the
| | 00:29 | more likely you are to get correct data.
| | 00:31 | If you type in my street address and you
get it wrong, you might not even know it.
| | 00:36 | But if I type it in, I'm likely to notice.
| | 00:39 | We're going to use validation in our
form to help our user provide information.
| | 00:45 | When we created our data source, we noted
that some kinds of information cannot be blank.
| | 00:51 | For example, the email address is
required. The first name of the user is
| | 00:57 | required, and this was set at the Field level.
| | 01:00 | But we also see it out here at the
control level because when we look at
| | 01:03 | the properties of the text box, it knows it
can't be blank because the field is required.
| | 01:09 | This kind of validation cannot be blank.
| | 01:11 | It will be checked at the very end of
the user completing this form when they
| | 01:17 | get ready to submit it, and not before then.
| | 01:20 | So, missing information, totally gone
information, gets caught at the end of the process.
| | 01:26 | However, incomplete information or
incorrect information we can catch ahead of time.
| | 01:33 | Let's look, for example, at Email Address.
| | 01:36 | In many organizations, users get used
to entering part of their email address,
| | 01:40 | simply their username and leaving off
the @ symbol in their domain, but we'd
| | 01:45 | like to have complete email addresses.
| | 01:47 | On either the Home tab in the Add
Rule gallery or in the Control Tools >
| | 01:54 | Properties ribbon in the Add Rule
gallery, let's click and take a look at the
| | 01:59 | rules for Email addresses.
| | 02:02 | If what a user enters here is blank
then at the very end of the form, InfoPath
| | 02:07 | will tell them, hey!
You're missing some data.
| | 02:09 | But if they enter partial data here, we
can give them some kind of an error message.
| | 02:15 | Now, this kind of formatting is simply
used to mark up text so that someone can
| | 02:19 | go back and look for the correct data.
| | 02:22 | Think of a person who spends their
evening entering information off of paper
| | 02:26 | forms into a computer.
| | 02:27 | If we flag information we formatted is
good or bad, then later on someone can
| | 02:32 | print it out and say go back and every place
that the information is marked as bad, go fix it.
| | 02:37 | We want to do something a little more strenuous.
| | 02:40 | So, we're going to use
these two types of actions.
| | 02:43 | We are going to either show a
validation error or ideally, we'll show a message.
| | 02:49 | When we show a validation error, what
we're doing is we're saying that when a
| | 02:53 | user enters data in the form and just
enters part of their information, that
| | 03:00 | we'll get this nice bright red border
around it that at least might give the user
| | 03:05 | pause. And they might think, hmm, when I
type my name up here, I don't get that,
| | 03:10 | so what's wrong with my email
address, and they might even figure it out.
| | 03:14 | So, this provides at least some feedback
and makes it really easy when this form
| | 03:19 | is printed to tell that there's a
problem with some of the data, but there's
| | 03:22 | actually a better way that
we can flag this for them.
| | 03:25 | So I am going to go to the Rules pane
that opened as soon as I added a rule.
| | 03:30 | I'm going to delete that rule I just
created, and I'm going to add a new rule.
| | 03:36 | You can click the New dropdown and start here.
| | 03:38 | You can walk step by step through
this process, but we have these built-in
| | 03:42 | templates up here under Add Rule that
are so much easier to use in InfoPath 2010.
| | 03:47 | So, when I choose Is Not an Email
Address then I can choose to show a message.
| | 03:52 | There are a number of actions you
can select from here, but those are for
| | 03:56 | different kinds of rules.
| | 03:58 | We are simply going to show a message.
| | 03:59 | We will look at some of those others
later. And type the text of the message you
| | 04:03 | would want our users to see,
| | 04:05 | a message that gives them enough
information that they know what the correct action is.
| | 04:09 | A message that simply says, "you made a mistake,"
| | 04:11 | might feel good for you,
but is not much help for them.
| | 04:14 | So, "You must enter a complete email address.
| | 04:16 | Here is an example."
| | 04:18 | That's a good message. I'll say OK.
| | 04:21 | Now let's preview this and see how it behaves.
| | 04:24 | Again, when a user simply leaves a
field blank it doesn't matter, but when
| | 04:28 | a user enters partial information, there is
that message box that we just constructed.
| | 04:34 | It will have at the top the name of
the form and it will say, "You must enter a
| | 04:39 | complete email address."
| | 04:40 | We've already moved on to the next
field because we caught that error tabbing
| | 04:44 | out of this field into Today's Date,
but it's not hard for the user to just
| | 04:49 | click back here and say, oh,
I think I know what this does.
| | 04:53 | Now, notice that's not a
complete email address either.
| | 04:56 | It will keep punching at
them until they get it right.
| | 04:58 | It's not actually looking for an email address;
| | 05:01 | it's looking for the form of an email address.
| | 05:04 | Some text @ some more text, dot, and some kind
of a domain, a short piece of text afterwards.
| | 05:12 | So, I don't know that this
is a valid email address.
| | 05:14 | It's certainly not mine, but it
looks like an email address, and therefore
| | 05:19 | Microsoft InfoPath says, good enough.
| | 05:21 | It's got the right form.
| | 05:24 | So, we have a rule that's a good rule.
| | 05:26 | Let's go ahead and rename it.
| | 05:27 | You can rename it here.
| | 05:28 | This is my Email invalid and that box
that we saw is actually called a message box.
| | 05:35 | So Email invalid MsgBox.
| | 05:36 | As soon as I tab anywhere
else, it changes the name here.
| | 05:41 | You can manage all of the rules that you
have within your entire form in one place.
| | 05:46 | So, it's helpful for you
to have a naming convention.
| | 05:48 | This once says, I am going to tell you
where you found it, what went wrong, and
| | 05:53 | what I did, or where you found it, what
the condition is, and what my action is.
| | 05:57 | You don't want to simply leave Rule 1,
Rule 2, and so on, or you'll need sticky
| | 06:01 | notes to know what it is that you're doing.
| | 06:03 | We can create that kind of
a rule in any text field.
| | 06:08 | So, if we go to another text field and
we take a look at a rule, we have rules
| | 06:12 | for if they are blank, but I'll warn
you that if you use the Is Blank rule, it
| | 06:16 | won't be checked until the end.
| | 06:19 | But if it's equal to something, if it
contains some text, or it doesn't contain
| | 06:23 | some, we can flag that.
| | 06:26 | Let's take a look at what happens
when we want to apply a rule to a date.
| | 06:30 | Remember the context of this form.
| | 06:32 | We're asking somebody, is this thing
you want me to post newsworthy, and if so,
| | 06:36 | until when? What's the expiration date?
| | 06:39 | It would then make sense that the
expiration date had always better be in the
| | 06:43 | future because we haven't posted this yet.
| | 06:45 | If it's already expired,
there's no reason for the request.
| | 06:49 | So, let's go ahead and add a
rule to the Expiration Date.
| | 06:52 | Notice that we get a different set of choices.
| | 06:55 | We're in a date picker and
we get date-relevant choices.
| | 06:58 | If the expiration date is in the past,
that would be wrong, so let's show a message.
| | 07:04 | And it can be as simple as, "Please choose an
expiration date at least 5 days in the future."
| | 07:15 | Now, it will actually let them choose
one one day in the future, but since we have
| | 07:18 | their attention, we can
shape this a little bit for them.
| | 07:22 | And now let's go ahead into
Preview and test that control.
| | 07:26 | Let's choose an expiration date in the past.
| | 07:31 | Let's choose today.
At least 5 days in the future.
| | 07:36 | So, let's close our preview.
| | 07:38 | That's a pretty good rule.
| | 07:40 | If we wanted to change it, we can
actually click, and it says when this is less
| | 07:45 | than today and not blank, we could
say well, if it's less than or equal to
| | 07:50 | today, and that would mean that if
someone shows today, it would also give them
| | 07:54 | that same error message.
| | 07:55 | There is our today. If it's less than
or equal to today. Let's preview it.
| | 08:13 | So, if I choose next week, it's fine;
| | 08:16 | if I choose in the past, it's not; and I
if I would simply choose today, it's not.
| | 08:24 | That works. So, this is for my expiry date,
which is the fields name NewsExpiry invalid MsgBox.
| | 08:36 | It looks good. Tab and go somewhere else.
| | 08:39 | These rules are very powerful. Any
place that you have a business rule that you
| | 08:43 | want to create about data,
| | 08:45 | if you're creating a form where people
type how many hours they worked in a day,
| | 08:49 | if they're not allowed to work more
than 12 then if it's the number is greater
| | 08:52 | than 12, give them a message, if the
email address is incomplete, if the date is
| | 08:57 | in the past when it should be in the
future, or in the future when it should be
| | 09:01 | in the past, as with an expense report.
| | 09:04 | However you use rules, remember that
rules are constrained to the control in
| | 09:09 | which you built them and that
they're checked when a user tabs out of the
| | 09:13 | control when you're all done.
| | 09:15 | To see all of your rules, you can
choose to manage rules to open the task pane
| | 09:20 | and take a look at different controls.
And as you click on them, if there is a
| | 09:24 | rule in that control, it will show
up here in the Manage Rules task pane.
| | Collapse this transcript |
| Using rules for conditional formatting| 00:00 | One of the things that makes a form
easy to use for our users is to ensure that
| | 00:05 | we don't ask them for information
that they don't need to provide.
| | 00:09 | An example here is that if the user
tells us that this post is actually news
| | 00:15 | then they need to provide an expiration
date for the news: a week from now, or
| | 00:19 | month from now. But if it's not news,
we don't need an expiration date.
| | 00:24 | I've added a text field for another possibility.
| | 00:28 | If the user chooses one of our first
three option buttons, then we have all the
| | 00:32 | information that we need. But if
they want a description with a link to
| | 00:37 | somewhere else on the site, a
different URL, then they're going to need to
| | 00:41 | provide us with the information to get
to that page, or to that specific place.
| | 00:47 | However, if they choose the first three choices,
we don't need to have them do anything here.
| | 00:54 | So let's take a look at how we can use
some formatting rules to be able to turn
| | 00:59 | off the option to provide us with information.
| | 01:03 | I'm going to choose Expiration Date, our
newsexpiry control, and choose to Manage Rules.
| | 01:10 | I'm choosing that because the kind of
rule I want to create here, these are all
| | 01:14 | specific formatting rules
or specific action rules.
| | 01:17 | I actually want to create my own custom rule.
| | 01:20 | So with this control selected, I'll
choose Manage Rules, and we're going to create
| | 01:25 | a new rule for formatting.
| | 01:28 | In this rule, what we want to do is
have a check and see, what's the status of
| | 01:34 | the isnews check box?
| | 01:36 | That's a condition.
| | 01:38 | So if the isnews check box is equal to--
and this is a good time to know that on
| | 01:44 | is true and off is false--
| | 01:46 | so if it's equal to false, that's
the condition. So it's not news.
| | 01:51 | If that's the case, then what we're
going to do is turn this control off.
| | 01:55 | Now I can't hide it, because it's a
datepicker. That would be my first choice
| | 02:00 | if it was a text box.
| | 02:01 | I can't hide it, but I can turn it off,
so that the user won't be able to type
| | 02:05 | in it, and therefore
really won't try to type in it.
| | 02:08 | I'm going to name this
NewsExpiry turn off, and there is my rule.
| | 02:16 | Let's go ahead and test it.
| | 02:20 | So right now it's turned off. I can't
even click in it, but when I do click it
| | 02:26 | and tab, I can use it.
| | 02:28 | I turn off the check box. I can't use it.
| | 02:32 | I do tab to it; it's still in the tab order.
| | 02:34 | But you'll notice that if I'm here,
turn this off and tab once, I will end up
| | 02:39 | here, then here on my second tab,
and then here on my third. But most users are
| | 02:45 | familiar with forms that work this way,
and they won't try to put anything here
| | 02:49 | if they can't. I'm going to close the preview.
| | 02:52 | Let's now tell this text box that we'd
like it to be hidden, unless it's needed.
| | 02:59 | It helps for us to remember what these
fields are before we start this process.
| | 03:03 | So we're in the posttype field,
the fourth option button control.
| | 03:09 | Let's open its properties,
and notice that this is its name.
| | 03:13 | So I'm going to go ahead and copy that.
| | 03:16 | I can right-click and nothing
happens, no context menu. But Windows
| | 03:20 | will override that.
| | 03:21 | If I hold Ctrl and hit C, I can
still copy that, so I am going to say OK.
| | 03:25 | Now, choosing the field that we want to
hide, or to turn off, I'm going to choose
| | 03:31 | New > Formatting and say that the
Condition here is when posttype is equal to,
| | 03:41 | and it says, what do you want to type?
| | 03:43 | And I say, oh, text.
| | 03:45 | And then I'm going to hold Ctrl and hit V
to paste in our text--that's V as in victory.
| | 03:51 | Here is my text.
| | 03:53 | So when that's true, I'd like
to hide this control, totally.
| | 03:57 | Let's go ahead and preview this,
and you'll actually see that it works, but it's
| | 04:08 | backwards. The control goes away when I want it.
| | 04:10 | So how would I fix that?
| | 04:12 | I would go back to mycondition and say
actually, when it's not equal to that, hide it.
| | 04:18 | So when posttype is not equal to Desc_URL.
| | 04:22 | Now, preview it again.
| | 04:26 | So one selected, two, my third
choice, my fourth, ah! There we go.
| | 04:32 | Now I could also choose to mark this
control as disabled, rather than hide it.
| | 04:37 | And the compelling reason that I might
is first, as I click in here, that when this
| | 04:43 | control is added InfoPath actually
moves my footer a little bit, which makes it
| | 04:49 | look a little jumpy. And the other thing
is I only have these two fields so far,
| | 04:55 | that if they're not needed, I can see
this one, but I'm not able to type in it.
| | 05:00 | It would kind to be great if this
one behaved in exactly the same way.
| | 05:04 | So let's go back and change what we're
doing with this control, and say, you
| | 05:07 | know, if we don't need it,
simply make it not enabled.
| | 05:13 | And so I'm going to call this
PostURLlink turn off, and tab out of this control.
| | 05:26 | That's how you create rules for formatting.
| | 05:28 | The ability to hide or disable controls
are one of the major reasons that I use
| | 05:34 | formatting rules, but I want to
remind you that there are other reasons.
| | 05:37 | You could choose that if someone entered
a particular value that you would put a
| | 05:42 | backfill on a control, that you would
bold a control, or that you would change
| | 05:46 | the color of the font.
| | 05:48 | It's a fairly limited control set,
but there are times that you would like to
| | 05:52 | highlight the kind of value someone
enters, or hide, or turn off, disable a
| | 05:57 | control that's not available to them.
| | 05:59 | And we'll do all of this by creating
new rules that are formatting rules
| | 06:04 | in InfoPath Designer.
| | Collapse this transcript |
|
|
7. Using Tables and Sections for Repeating DataUsing repeating tables| 00:00 | There are several types of data in our form
that might appear more than once, if we allow it.
| | 00:06 | Let me give you an example.
| | 00:08 | The post that the user sends in
might have more than one category that it
| | 00:13 | could be attached to.
| | 00:14 | For example, it might be about
travel and tourism, or it might be about
| | 00:20 | festivals and travel, that kind of thing.
| | 00:22 | So this postcategories, we could choose
to allow them to enter categories in a
| | 00:28 | Multi-Select list, but we actually
want information about each category.
| | 00:33 | So it's more than just one control.
| | 00:35 | We have three data fields here.
| | 00:38 | Fortunately, InfoPath has controls
that repeat, both repeating tables and
| | 00:44 | repeating sections, and they
are incredibly powerful to use.
| | 00:48 | We have to start, however, not out in
the view of the form, but in the data
| | 00:53 | itself, in the data source.
| | 00:55 | I'm going to go to postcategories, and
I'm going to open the properties for the
| | 01:00 | postcategories group.
| | 01:03 | In order to allow the form to use the
repeating controls--a repeating table,
| | 01:09 | a repeating section--I have to actually say
that this data repeats in the data source.
| | 01:14 | So by checking the Repeating check box,
you'll see that there is a little blue
| | 01:19 | dropdown arrow that's placed on
the group, and it says it's repeating.
| | 01:24 | This is different than saying the fields repeat.
| | 01:27 | What I'm saying is the whole
group, all three fields, repeat.
| | 01:31 | If I'd said, for example, that only
postcategory repeated, it wouldn't allow me
| | 01:36 | to repeat the notes in isprimary.
| | 01:39 | Now, I want to create either a repeating
table or a repeating section and really,
| | 01:44 | this depends on layout.
| | 01:46 | I only have three fields, so they
should fit really neatly across the width of
| | 01:52 | my form, and that tells me that a
table would be a good way to do this.
| | 01:56 | I have several choices.
| | 01:57 | I will not go up here and insert a
repeating table, or a repeating section, even
| | 02:03 | though those containers exist here on
my list, because then I'll have to do a
| | 02:08 | lot of binding, not just to
one thing, but to several.
| | 02:12 | Instead, my choices are to drag and drop
out of the data source and into my Form
| | 02:19 | view, and I'll be asked, do I want to
create a Repeating Table, a Repeating
| | 02:24 | Section with Controls, a Repeating
Section without Controls, a Horizontal
| | 02:29 | Repeating Table--a bad
idea for this data--and so on.
| | 02:33 | So let's look first and see what the
Repeating Section with Controls would look like.
| | 02:38 | Here is my section, here are my controls,
and I can then arrange those and label
| | 02:44 | those however I wish.
| | 02:45 | I begin by putting in some kind of a
table. But what we're going to do instead
| | 02:51 | is we're going to insert the Repeating Table.
| | 02:54 | So I will undo this change, and because
my data fits, I can drag this repeating
| | 03:00 | table, or I can right-click.
| | 03:02 | Notice that my insertion point is in
the proper place out in the form, and I can
| | 03:06 | simply choose Repeating Table and it will be
inserted at my insertion point. So, check it out.
| | 03:15 | There is my postcategory textbox, my
postcategorynote, and a check box for this
| | 03:22 | Boolean field, is it primary.
| | 03:25 | All I need to do now is apply some headers.
| | 03:28 | So, I could type in 'Category', tab,
and type in 'Notes'. Or in this case, what
| | 03:35 | we really want to know is the reason,
and then I can ask is this the primary category?
| | 03:43 | I hate to give up that much room for a
check box. I would try to spend a lot of
| | 03:47 | time thinking if I could make that
shorter, because there is my edge.
| | 03:52 | And I'd like this Reason check box
to provide enough space for people.
| | 03:56 | Let's right-click on it, go into the
Text Box Properties, and make sure on the
| | 04:00 | display that I allow it to be multi-line,
and to wrap the text, and to have this
| | 04:05 | text box expand to show all the text.
| | 04:08 | I don't want them to write a novel
though, so I'm going to take away the
| | 04:11 | paragraph breaks, which will allow them,
the first time they try to press Enter,
| | 04:15 | it won't--it's kind of self-limiting.
| | 04:19 | I could place a placeholder here that says,
"Why do you think this category is appropriate?"
| | 04:32 | That fits nicely.
| | 04:33 | There is my repeating table.
| | 04:35 | Let's go see what it looks like.
| | 04:38 | So when the user tabs into this,
they can't enter their first category,
| | 04:43 | Travel, enter some data, tab, and
say that's the primary category.
| | 04:48 | Now, if they tab again, they will
tab out of this table. But if they
| | 04:52 | click Insert item, more text, now this will
let them check more than one primary category.
| | 05:01 | If I want them to check only one,
I could put Primary Category, in
| | 05:05 | parentheses, one only.
| | 05:07 | I could provide some text to help the
user understand that here, particularly if
| | 05:13 | I want to provide text for this entire table.
| | 05:16 | But each time they insert a
new item, they will get a new row.
| | 05:20 | Let's go back and see what the settings
are that we can provide for this table,
| | 05:25 | because there are some
things that we can do with this.
| | 05:28 | To choose the repeating table, I click
the Repeating Table tab here, and again
| | 05:33 | this is a kind of a control that
holds controls. It's a container.
| | 05:37 | I'm going to right-click and
choose the Repeating Table Properties.
| | 05:41 | One of the choices that I have here is
that I can provide default values. I can
| | 05:46 | make sure that the binding is correct.
| | 05:48 | Again, if I change binding, I'm going
to get to choose a group to bind it to.
| | 05:54 | So there is a special dialog for that.
| | 05:58 | But I will often, in my repeating table,
change that button that says Show insert
| | 06:03 | button and hint text, and I will simply
say something like, "Click to add another
| | 06:10 | row," or in this case,
"Click to add another category."
| | 06:13 | With a table, if you say row, because
it looks like Excel, people will get it,
| | 06:17 | but you could also say
'another category' if you wish.
| | 06:21 | Now, when the user is using this table,
they actually have the ability--there is
| | 06:27 | my Click to add another category--to go
back and choose one, and to say I'd like
| | 06:32 | to remove one or insert one before
so they're in a particular order.
| | 06:36 | Notice that the name that's getting
picked up here though, is the group
| | 06:40 | name, postcategories.
| | 06:42 | This isn't very friendly to the user.
| | 06:44 | Let's go back to the properties of
the repeating table and change that
| | 06:48 | text, because we don't think they
need to care that we've called this field
| | 06:53 | group postcategories.
| | 06:55 | They're simply seeing the word 'category'.
| | 06:57 | So let's go back to the Repeating Table
Properties and customize the commands
| | 07:02 | that are used there.
| | 07:03 | The first is to insert.
| | 07:05 | So I could say, "Insert another category,"
or "Insert category," Insert Above, "Insert
| | 07:18 | category before," Insert Below would be
"Insert category after," and then Remove
| | 07:25 | would be "Remove this category."
| | 07:29 | If I want to allow the power of dump the
whole table, I would choose Remove All,
| | 07:34 | and then it would be "Remove All categories."
| | 07:36 | That's off by default.
| | 07:39 | Let's go back to Preview and see how it works.
| | 07:42 | I click here to add another category.
| | 07:45 | When I select a category, I can insert
one before, after, or remove this one,
| | 07:50 | or move this one down.
| | 07:52 | That's how you create a repeating
table and modify its properties, so that
| | 07:57 | you can have repeating data in
your form without leaving empty rows
| | 08:01 | available for it.
| | Collapse this transcript |
| Using repeating sections| 00:00 | Repeating sections are a
lot like repeating tables.
| | 00:03 | If we want to repeat a section, first
we need to make sure that we've gone into
| | 00:08 | our data source and said
| | 00:09 | this group of controls is going to repeat.
| | 00:12 | Then we can come in to our form and
either place a section with or without
| | 00:16 | controls, or we can take a section
that's already there, remove it, and replace
| | 00:21 | it with a repeating section.
| | 00:23 | This is a little more difficult than
when we simply took a table that didn't
| | 00:28 | exist already and created it in the form.
| | 00:31 | This was easy. We simply right-clicked
and said give us a Repeating Table.
| | 00:35 | We could have also said give us a
Repeating Section with Controls, and so on.
| | 00:40 | We're actually going to take two
sections of this form that exist already and
| | 00:44 | replace them with repeating sections.
| | 00:46 | It's like that trick where you have
all of the glasses and china on the table
| | 00:50 | and you pull the tablecloth off
without moving the glasses and the china.
| | 00:54 | That's what we're going to try to do here.
| | 00:57 | The two sections that repeat. One is the
section on the file that's going to be posted.
| | 01:03 | It sits right down here, and we could
actually have a user attach more than one file.
| | 01:10 | So we want to be able to take that
section right here and repeat it.
| | 01:15 | It already has contents.
| | 01:17 | If I simply change this section from a
regular section to a repeating section,
| | 01:25 | when I do that, all of
these controls will be gone.
| | 01:29 | So my process looks like this.
| | 01:31 | First change the data source;
| | 01:33 | then copy the controls, because there
is nothing wrong with them; change the
| | 01:39 | section to a repeating section; and
then paste my copied controls back in.
| | 01:44 | Let's see how it works.
| | 01:45 | We'll start here with our postfile
group, change its properties to say that
| | 01:52 | this is a repeating group.
| | 01:53 | As soon as I say OK, of course, we'll
get a binding error that comes back from
| | 01:59 | the section control.
| | 02:00 | It says, hey, that's a repeating data group.
| | 02:02 | I'm a non-repeating section,
and I'm going to have a problem.
| | 02:06 | So, what we can do now is we can copy
the contents here, all of our controls.
| | 02:11 | You can hold Shift and use your arrow
keys to make sure that you get everything.
| | 02:17 | You don't want the whole section
because the section itself is going away; you
| | 02:22 | only want the controls on the table.
| | 02:25 | So select here and either drag or Shift
and then click again or use the arrow
| | 02:31 | keys, but make sure that
you've got that whole control set.
| | 02:35 | You can cut them or copy them.
In a moment, it's not going to matter.
| | 02:38 | So I'm going to copy
this table and its controls.
| | 02:43 | I'm then going to click on the Section
tab, right-click, change the control to a
| | 02:49 | repeating section, and when I do, as
I promised, all the controls are gone.
| | 02:55 | In my repeating section
though, the section is selected.
| | 02:59 | I am going to hit the Right
Arrow key, the Left Arrow key.
| | 03:02 | I'm still in my control.
| | 03:03 | This all looks good.
| | 03:05 | Now I'm going to paste. Hold Ctrl and hit
V, or you can Paste up here if you wish.
| | 03:12 | There are my controls in my repeating section.
| | 03:15 | If you miss on this, if it pastes
above or below, don't worry about it.
| | 03:19 | Just undo and click, so you're
back in your repeating section.
| | 03:22 | Now if you notice, if I choose one of my
fields over here, it's still connected.
| | 03:29 | As soon as I pasted this section of
controls back in, they immediately latched back on.
| | 03:35 | The issue wasn't with my option button
controls or my check box control; the
| | 03:40 | issue I was having was with
my section container control.
| | 03:45 | Now we're going to do something really
edgy, because the other thing that we
| | 03:48 | found out that can repeat, as we've
gone along and been working on this form,
| | 03:53 | is most of the form.
| | 03:55 | In other words, we can have more than
one post that's sent over at one time.
| | 04:01 | This might boggle your mind a little bit
because we have a natural tendency to
| | 04:06 | think that a form is 8 1/2 x 11, but there
is no need for a form to have a limited
| | 04:12 | size, unless our primary use of it is to print.
| | 04:15 | If we're simply collecting user
information and viewing it electronically, we
| | 04:19 | don't really care that this
form is a little bit longer.
| | 04:22 | So if a user has two or three things
they need to send us at one time, we could
| | 04:27 | actually make it easy by putting
multiple posts here in this one form.
| | 04:32 | If we were to do that, let's
take a look at how we would do it.
| | 04:36 | It's the same process. The first thing
we would do is we would go over here to
| | 04:40 | posts and we would say, well,
this whole section can repeat.
| | 04:44 | The fact that it has repeating
sections in it, not a problem.
| | 04:48 | So let's change its properties, say
this entire group of fields can repeat,
| | 04:54 | including all of the subgroups, and say OK.
| | 04:58 | And not surprisingly, as soon as we
do, what we see is that this section
| | 05:03 | container can't hold repeating data.
| | 05:06 | Now, we need to choose our entire set
of controls, and they start down here.
| | 05:11 | This repeating section is one of our controls.
| | 05:14 | So again, you can do Shift and
hold your arrow keys down and select
| | 05:19 | everything you need.
| | 05:20 | You can hold Shift, click Shift.
Whatever you do we want everything from post to
| | 05:24 | the bottom, and we're going to copy that.
| | 05:30 | Now let's go to our section
control and make sure it's the right one.
| | 05:33 | It's this one linked here.
| | 05:36 | If I select it there, you'll
see it's selected down here.
| | 05:39 | Right-click. Change the
control to a repeating section.
| | 05:43 | If all you see when you choose this is
Repeating Table, you're probably in the
| | 05:47 | wrong place, because a section should
always offer you the ability to change to
| | 05:52 | another section type.
| | 05:54 | I'm going to choose Repeating Section,
and as soon as I do, most of my form
| | 05:57 | disappears. And I could be truly
miserable right now if I hadn't copied all of
| | 06:02 | those controls, tables, sections, and so on.
| | 06:05 | I'm going to hit the right arrow and
the left arrow, which is going to light up
| | 06:08 | the entire section, and I'm going
to paste my information back in here.
| | 06:14 | And there are all of my controls back
again, and they should all be properly bound.
| | 06:19 | If I click posttitle, postdescription,
postURL I haven't placed a control for
| | 06:25 | yet, there are my categories, and so on.
| | 06:28 | So I'm going to check each and every one
of these, just because it's a good thing
| | 06:32 | to do, but that worked really nicely.
| | 06:35 | So now in my form, I have several
repeating tables and repeating sections.
| | 06:40 | Let's see quickly how that works.
| | 06:42 | I am going to click on Preview and
look at. All of this, one long post.
| | 06:47 | So, if I want to Insert another post,
insert posts before, after, there is
| | 06:53 | another post. And when I scroll my form now,
I'll see that entire post form there twice.
| | 06:58 | I can do some cleanup by going back into the
properties of the section itself at the bottom,
| | 07:05 | my second repeating section, which is
posts. As your form gets more complex, you
| | 07:10 | spend more time making sure that what
you've clicked down here in the Form view
| | 07:13 | is the same as your data source.
| | 07:15 | I am going to right-click, choose my
Properties, and I could say I want to
| | 07:20 | "Insert another post."
| | 07:23 | I'd like that clarity in my preview.
| | 07:26 | Otherwise, I'm feeling pretty good,
and down here, Insert another item,
| | 07:31 | this is insert another set of
instructions and another file.
| | 07:35 | So let's fix that repeating section as well.
| | 07:38 | Right-click and say, "Insert
another file and/or instructions."
| | 07:45 | I have the whole width of the form for
these, so there is no point in my being
| | 07:48 | brief, when it would be more
helpful to the user if I was clear.
| | 07:52 | Let's scroll down to the bottom of the
form and make sure that we can see what
| | 07:55 | those things are going to do.
| | 07:57 | This link is going to set a new
Instructions and File. That worked.
| | 08:02 | This, another entire Post
section. Amazing! Fabulous form!
| | 08:08 | So this is how we're going to use repeating
sections and repeating tables in our form.
| | 08:13 | In the next movie, we'll
look at optional sections.
| | Collapse this transcript |
| Using optional sections| 00:00 | Another type of specialized
container that you can add is a container for
| | 00:05 | an optional section, a set of controls
that we don't normally need but we might need.
| | 00:11 | So rather than create a separate form
for them, or rather than have them appear
| | 00:16 | in the form when they're rarely used,
we allow the user either to insert or
| | 00:21 | delete the set of controls.
| | 00:23 | We have another piece of
functionality that we want to add to our form, and
| | 00:26 | this isn't unusual. You have a form. It's working.
| | 00:30 | People are using it and somebody else
says, "Ah, let's grab another type of
| | 00:35 | request here because it would be
easier than getting users to use a form they
| | 00:39 | are not already used to using."
| | 00:41 | So the functionality that we are going
to add is to allow the users also to say
| | 00:47 | that this post is actually going to
create the need for an entirely new content
| | 00:53 | area, in other words a new section of
our Internet site, or intranet site.
| | 00:59 | The reason that this is important and
belongs in its own section is that we're
| | 01:03 | not going to simply take the user's word for it.
| | 01:06 | This is significant endeavor.
| | 01:08 | Every user would like to have
their own section of the web.
| | 01:11 | So what we are going to do is, when
a user asks for this, we are going to
| | 01:16 | require that we get a
signature from their manager.
| | 01:19 | Let's see how we can add
this optional sectional here.
| | 01:22 | Here are our controls for
newcontentarea, and we are going to put that
| | 01:27 | relatively high in the form, because if
we need to do that and then post these
| | 01:32 | items in this area, if there is an
issue with creating the new area then the
| | 01:38 | posts don't really matter.
| | 01:40 | We want to deal with the
newcontentarea first before we post anything to it.
| | 01:45 | As with the other types of groups that
we've placed controls for, we have the
| | 01:50 | ability to say that we'd like
to have a section with controls.
| | 01:54 | But notice here that one of our choices is
to create an Optional Section with Controls.
| | 01:59 | So, let's go ahead and do that.
| | 02:00 | We'll get a relatively ugly-looking
section when we do this, and you might
| | 02:05 | wonder why we would do it at all.
| | 02:07 | Well, it's kind of nice to have the
controls here and to have them bound.
| | 02:10 | I mean that's the benefit.
| | 02:13 | The disadvantage is that we now need to
turn around and lay them out, but that's okay.
| | 02:17 | We are going to go to the beginning of
this optional form section, and we are
| | 02:21 | simply going to insert a
table to hold four items.
| | 02:24 | And I think we will choose a basic
four-column table here without a heading.
| | 02:32 | We do want a heading.
| | 02:33 | But we don't want a big heading.
| | 02:34 | We want a subheading, the same
as Post in the center of the form.
| | 02:38 | So let's go ahead, and let's click the
add subheading, and this is COMPELETE
| | 02:43 | THIS SECTION IF YOU ARE REQUESTING A
NEW CONTENT AREA. Makes sense to me.
| | 02:55 | So the first label we have is Area name,
and just so people don't think that
| | 03:03 | they will always get what they want,
we will put in a word like 'suggested'.
| | 03:05 | We will then take this Area
name control and move it up there.
| | 03:10 | The next thing we want is the
description, and so we need to leave a little
| | 03:13 | more room for that.
| | 03:15 | I'm going to take these three cells and
actually merge them together to make a
| | 03:21 | space for this, and so 'Description of
area, including rationale', and we're
| | 03:31 | going to add our Description control right here.
| | 03:36 | Now we can stretch this out a little
bit, but we want somebody to add a lot
| | 03:41 | of information, so let's go in here
and change the properties of the text box
| | 03:46 | to ensure that it's multi-line, the
text wraps, and that this will expand to
| | 03:52 | show all of their text.
| | 03:53 | Because if we don't do that when we
print it, if we use the scroll bars
| | 03:57 | rather than expanding, when we
print it, it will cut off anything that
| | 04:01 | doesn't easily show.
| | 04:02 | So, expanding is always a good idea.
| | 04:05 | We won't miss anything that way.
| | 04:08 | And now we need Approval
Signature and Approval Date.
| | 04:17 | We will move our
signature here and our date here.
| | 04:23 | We now have some room where those
controls were, so we can simply get out of the
| | 04:27 | table, select this area if we wish, and delete.
| | 04:31 | Now let's go take a look at our preview
and it's just says, "Click here to insert."
| | 04:37 | Clearly, we will need more instruction,
but when we do, there is the section.
| | 04:42 | So now let's go check the properties of
the optional section and change so that
| | 04:48 | instead of saying, "Click here to insert,"
we are going to say, "Click here if
| | 04:53 | you are requesting a new
content area." Very clear. Preview.
| | 05:04 | There is our new content area.
| | 05:06 | The user can then decide to remove it, so
we will want to change that text as well.
| | 05:11 | Let's go back into our Properties.
| | 05:15 | That's our Customize Commands.
| | 05:17 | If they insert it, once they've
inserted it, all they can do is remove.
| | 05:22 | So the only command we need to change
is actually Remove newcontentarea, so
| | 05:28 | "Remove New Content Area information."
| | 05:33 | I could continue that I've just
spent 30 seconds entering, and so on.
| | 05:38 | That's what an optional section looks
like when the form starts without it.
| | 05:42 | You have another choice as well, which
is to include the section in the form and
| | 05:47 | to allow users to delete
it if they don't want it.
| | 05:51 | But we actually don't want the
section in the form by default.
| | 05:54 | Most people who use this form
won't be requesting a new content area.
| | 05:59 | So let's click OK, swing back into
Preview again, and you'll notice that if we
| | 06:05 | click here, we are requesting a new
content area, and we can remove it if we
| | 06:09 | don't want it, and the
original prompt comes back.
| | 06:12 | Optional sections are very powerful if
you use them to provide a space to enter
| | 06:18 | information that most users
are never going to need to enter.
| | Collapse this transcript |
| Using choice controls| 00:00 | There's one more type of section that
you can use to provide your users with
| | 00:05 | one or more choices.
| | 00:07 | When we use the Optional Section, what
we were doing was giving them a choice to
| | 00:12 | have or not have a particular section,
but with a Choice Group and a Choice
| | 00:17 | Section, we have the ability to provide
the user with one section that they can
| | 00:23 | then swap out for another that we
see as a parallel sort of section.
| | 00:28 | Let's take a look at how this
functionality works, and then I'll come back and
| | 00:32 | show you how we put it together.
| | 00:34 | Let's go to the Home tab and click Preview,
and we have an Emergency Contact form.
| | 00:39 | Participant information goes in the
first shaded area, and then in the second
| | 00:43 | shaded area, we gather emergency
contact for an adult.
| | 00:48 | Now in our program, we only need
to have one contact for an adult.
| | 00:52 | However, we need more
information and two contacts for any minor
| | 00:58 | participating in our program.
| | 01:00 | So rather than have both of those
kinds of information on the form so that
| | 01:05 | adults have to figure out what to
leave out, and minors or their parents
| | 01:09 | completing the form need to figure
out that they need to provide two, we can
| | 01:13 | just provide two different sections.
| | 01:15 | The default is Adult because most of
our program participants are adults.
| | 01:19 | However, I can choose to replace
this with another section called
| | 01:24 | EMERGENCY CONTACTS INFORMATION - MINOR.
| | 01:27 | Notice that this section has
additional information and allows the user to
| | 01:32 | insert a second, a third, a fourth contact.
| | 01:36 | It has dropdown lists, and it has more
specific information on the cell phone.
| | 01:41 | So this is how it works.
| | 01:43 | I can say I want to see the section for minors,
or I want to see the section for an adult.
| | 01:50 | This type of functionality is created
by placing controls first and adding
| | 01:56 | fields or moving fields into them afterwards.
| | 02:00 | This isn't the type of feature where
you want to go in retroactively and change
| | 02:05 | existing groups or change existing sections.
| | 02:08 | So from the beginning, if possible,
you should say, I'd like to have two
| | 02:12 | possible choices here, or three.
| | 02:15 | I'm going to open a new blank web form,
and let's take a look at how we would
| | 02:21 | actually use these controls.
| | 02:23 | Notice I have no data source whatsoever.
| | 02:25 | This will make it really
easy to see what happens here.
| | 02:29 | If I choose a Choice Group, then I'm
going to place simply one group here
| | 02:36 | with two sections in it.
| | 02:38 | Notice that I have first a group
that would describe my choices.
| | 02:43 | In my case, what I named this was I
named this emercontacts. Then you
| | 02:49 | don't rename this Choice section at
all; it will always simply say Choice.
| | 02:54 | group2 was the contact for adults,
and group3 was the contact for minors.
| | 03:05 | So then I would put the controls
that I needed in each of these sections.
| | 03:08 | I am actually building two
parallel form sections here.
| | 03:12 | So I'm simply going to drop one field in
here, and I'm simply going to call this
| | 03:18 | adultcontactinfo, and then I'm going
to add a field for a minor and call it
| | 03:23 | minorcontactinfo, and this
is just so I can see the form.
| | 03:28 | I'm going to drag this
over and drop the text box.
| | 03:32 | Remember also that I can right-drag
over and drop a combo box or a list box
| | 03:38 | or whatever I choose.
| | 03:39 | So there are my two views of the form.
| | 03:42 | Let's go into Preview quickly, and
you'll see that it shows Adultcontactinfo,
| | 03:48 | but I can trade that for the
Minorcontactinfo. Or I can remove the
| | 03:54 | Adultcontactinfo altogether.
| | 03:56 | If I do, I won't be able to get
back to a button to do anything else.
| | 04:03 | So how then would I ensure that the
choice that I wanted was the default?
| | 04:09 | In this case, Adultcontactinfo is the
default, but what if I wanted to change it
| | 04:14 | to Minorcontactinfo?
| | 04:17 | This is a little detailed, so watch carefully.
| | 04:21 | I'm going to choose the Choice group,
not adultcontact or minorcontact, and
| | 04:27 | I'm going to go to the Data tab,
because if I look at this Choice group, it has
| | 04:33 | almost no properties.
| | 04:34 | Very little I can change. I can't rename
it, can't set a default value, and I'm
| | 04:39 | thinking, ah, but I want to.
| | 04:41 | What I want to do is go to Data
and choose Default Values here.
| | 04:46 | This is a dialog that we haven't seen
before that allows us to stuff default
| | 04:51 | values into fields in a form when the
user opens it, or at the point where a user
| | 04:58 | inserts a section into a form.
| | 05:00 | But we are actually going to
use this for a different purpose.
| | 05:03 | We are going to open up the tree list and
say I'd like minorcontact to be the default.
| | 05:10 | When I do that, it will change. Choice
section will say default here in my minor
| | 05:15 | section, and when I go back in
Preview, notice what comes up first.
| | 05:21 | So again, it's a little out of the way,
but choose the Choice group, slide to
| | 05:25 | the Data tab, and set the Default Values here.
| | 05:28 | I'm going to return to my other form,
so we can see this functionality one more
| | 05:33 | time in a finished form.
| | 05:35 | Here is my overriding group
that contains this choice section.
| | 05:42 | There is my Choice group where I would
go set the default value, here, to say
| | 05:49 | which section I want to see.
| | 05:54 | Here is my adultcontact section of the
form that I show by default, and here is
| | 06:03 | my Choice section for emergency contact
for a minor, with its repeating section,
| | 06:09 | so we can collect multiple contacts.
| | 06:12 | What if I wanted to add another choice?
| | 06:15 | What if there was a third choice?
| | 06:17 | A minor accompanied by an adult, for example.
| | 06:20 | Well, in that case, I would return
back to the Home tab and go back.
| | 06:25 | It doesn't really matter where I am.
| | 06:27 | I can do it in the Choice group though,
and choose my Choice group here as well,
| | 06:35 | and say I want to add another section.
| | 06:38 | When I do, I told you it didn't
really matter where we put it.
| | 06:42 | This group gets created in a
separate choice group when you do this.
| | 06:46 | But you can take this section and
you can move it to another group.
| | 06:51 | You can't move it up or down, but I can
move it and say actually, this is a new
| | 06:55 | choice into this choice group. Here it is.
| | 07:01 | I then can move the control, here, my
section, into this group and delete this
| | 07:12 | group here that I no longer require.
| | 07:17 | Now, I have the ability to add controls
here, to change this one's name--so this
| | 07:22 | is EmerContactMinorandAdult, for
example--and fill in the fields.
| | 07:32 | So I have the ability to change all of
these out any way I wish, and one more
| | 07:37 | property you need to know about.
| | 07:39 | In the Choice section itself, the major
thing I want to do here is to be able to
| | 07:44 | customize the commands that will
appear when I click on the purple arrow to
| | 07:49 | switch out sections.
| | 07:51 | So I'm in the Emergency
Contacts for a Minor section.
| | 07:54 | I can Insert a new one, remove this one,
or if someone chooses this section as a
| | 08:00 | replacement, it would say, properly,
"Replace with Emergency Contacts for a Minor."
| | 08:06 | In other words, I'm not specifying
here what I would replace it with, but the
| | 08:10 | language that should appear on the
button if this is the replacement section
| | 08:15 | that the user is looking for.
| | 08:17 | You will want to rename these, so
that rather than having replaced with
| | 08:21 | EmerContactsMinor, it says, "Replace
with Emergency Contacts for a Minor."
| | 08:27 | Make these command choices user-
friendly for the section commands.
| | 08:31 | That's it, a powerful control, nifty to
use because you don't have to put in two
| | 08:38 | different option groups. And as long
as you have a limited number of pure
| | 08:43 | choices, this will look
really dazzling in your form.
| | Collapse this transcript |
|
|
8. Using Object ControlsUsing the file attachment control| 00:00 | Way down at the bottom, in the
Instructions and File section of our form, we want
| | 00:05 | the user to be able to attach a
document. It could be a Word document, an Excel
| | 00:10 | document. It could be a PDF that
contains information that they'd like to post.
| | 00:15 | So we're going to use the
attachment control to do that.
| | 00:18 | Now I'm going to put that attachment
control right here. Despite what you may
| | 00:24 | have heard, there's actually nothing
wrong with attachment, as long as you're
| | 00:26 | doing it with files.
| | 00:28 | So I'm going to click the
Controls Gallery and choose, in the Object
| | 00:33 | section, File Attachment, and it's
going to drop this really nice-looking
| | 00:36 | file attachment in here.
| | 00:38 | I actually have a field for that already,
so I'm going to right-click and change
| | 00:44 | it's binding to postattach.
| | 00:48 | The data type here has to be the type
that will hold a file of base64Binary, and
| | 00:56 | then I can get rid of this field
here that was automatically created by
| | 01:00 | InfoPath. So let's see how this works.
| | 01:03 | First, let's switching into Preview
mode, and down towards the bottom it says,
| | 01:07 | "Click here to attach a file."
Notice that gray border is a little cut off, so
| | 01:11 | will make some adjustments, in terms of
space, but I'm going to click here, and it
| | 01:16 | will automatically allow me to choose
a file and insert it, just like that.
| | 01:24 | Slick control. Quite nice, huh?
| | 01:27 | It only has space for one,
but remember that we've made this section repeat
| | 01:32 | so that for each file the user will
provide some instructions, and that section
| | 01:36 | works quite nicely.
| | 01:37 | Let's close our preview, go back,
and first just make some visual space here to
| | 01:43 | make sure that the border
of this control fits as well.
| | 01:47 | And now let's right-click and choose
the File Attachment Properties, because
| | 01:51 | there's a couple of
properties you may want to change here.
| | 01:54 | First, showing the file placeholders
is pretty nice, because it gives this
| | 01:58 | nice visual on it. But if you weren't
allowing a user to choose just any file,
| | 02:04 | you might want to specify a default file
that they are sending, in a default location.
| | 02:08 | An example of this would be a
situation where a user goes in and completes a
| | 02:13 | particular template, and you'd like
them to attach what they've created out of
| | 02:17 | that template, so we can at least get
them to the file and the file location.
| | 02:23 | By default, users are allowed to browse,
delete, and replace files, so if we turn
| | 02:28 | this off, let's go see what that looks like.
| | 02:32 | We'll still have the control, but when I
click to attach a file, it's really not
| | 02:38 | going to allow me to, because I
don't even have the right to browse.
| | 02:42 | So we clearly don't want to do that.
because it takes the user totally out of
| | 02:47 | the experience. Why is that even there?
| | 02:50 | Because if we're specifying a default file,
when the user clicks, we just load that file.
| | 02:55 | We don't allow them to look for anything.
| | 02:57 | So when I want my user to look, I
show a placeholder and let them browse.
| | 03:02 | If I already know what file I'm aiming
at--that doesn't happen frequently--I'll
| | 03:06 | simply specify the default file,
and when they click--or I can programmatically
| | 03:11 | do this in some forms.
| | 03:13 | I'll grab the file I want.
| | 03:14 | Here is the other powerful setting.
| | 03:16 | You can go in and tell a user that
there are specific kinds of documents
| | 03:20 | you're willing to have
and types that you're not.
| | 03:23 | Here you're typing file extensions.
| | 03:25 | I'm willing to have a doc or docx,
a ppt, an xls, a pdf, and so on.
| | 03:32 | This does two things. One thing it does
is when the user opens that dialog box
| | 03:37 | and browses, they won't be
seeing files that you don't want.
| | 03:42 | It will limit it, for example, to documents.
| | 03:45 | So if I were to go in and say that I'm
only willing to see doc files, ppt files,
| | 03:50 | and xls files, then if a user has a
bunch of jpegs in the same folder, they
| | 03:55 | won't have to sort through
those to find the type of file.
| | 03:59 | If you're asking the user to upload an
image, then you might only be willing to
| | 04:03 | look at jpegs, gifs, and tiff files.
And if that's the case, there's no reason
| | 04:09 | they should have to scroll through
Microsoft Word documents, Excel files, and
| | 04:13 | InfoPath forms in order to find them.
| | 04:16 | If we're going to allow any kind of
file attachment, which is what we should be
| | 04:20 | doing here in our form, because a user
could be sending any of those, then we'll
| | 04:24 | simply clear that list and
allow any type of file posting.
| | 04:28 | The attachment object is easy to use,
very slick, users feel great about it, and
| | 04:34 | when I click to attach that file and
select that file, it's actually stored in
| | 04:42 | the data source specified in my form,
so that it's available to the next person
| | 04:47 | this form is emailed to, or available
on the web site if I post this form.
| | Collapse this transcript |
| Using the hyperlink control| 00:00 | We have two places in this form where
we're asking a user for information that
| | 00:04 | could come in the form of a URL.
| | 00:07 | The first is here, where we're asking
them to give us a specific place that they
| | 00:12 | believe this post belongs.
| | 00:14 | The second location is here, where we're
asking the user to provide information
| | 00:20 | if they have chosen that they'd like to have
this file point to a link to another location.
| | 00:26 | You may recall that we chose to leave
this text, and the reason is that we felt
| | 00:31 | that it was equally valid for user to
enter a URL or simply to say something
| | 00:37 | like, "link to employee manual," in which
case they wouldn't be entering something
| | 00:42 | that was valid as a URL.
| | 00:44 | In this other location though, we're
specifically request in a URL, which could
| | 00:49 | point to a location on the intranet,
the Internet, a network drive, wherever.
| | 00:56 | So we're going to use a particular
control here that's meant for hyperlinks.
| | 01:01 | The field that we're going to bind this
control to is here, postURL, in our Posts
| | 01:08 | section, and if you point to this,
you'll note that it is actually anticipating
| | 01:13 | that you will paste some kind of a
uniform resource identifier in here. So this
| | 01:19 | data type is expecting a file path.
| | 01:22 | If I simply use a text box, then no
matter what control I put in here, all I'll
| | 01:27 | store is text. But by having both a
field type here that support hyperlinks
| | 01:34 | and the hyperlink object control,
I can actually store hyperlinks.
| | 01:41 | So let's go ahead and place a hyperlink control.
| | 01:45 | This is what it looks like. As always,
we'll find that InfoPath has created a
| | 01:51 | field that we don't need, so we can delete that.
| | 01:56 | We can then bind this control, which
is temporarily unbound, to our postURL
| | 02:03 | field in our data source.
| | 02:07 | Let's take a look and see
what that looks like then.
| | 02:10 | When the user clicks the text that says,
"Click here to insert a hyperlink," the
| | 02:15 | Insert Hyperlink dialog box opens.
So their choices at this point are to type a
| | 02:19 | URL or to have copied and then paste
a URL here, but it's a real hyperlink.
| | 02:28 | When I click, it will actually open
Google on my page. It looks good, my sea
| | 02:34 | tortoise, and that all works.
| | 02:38 | We don't have many properties here
in the Insert Hyperlink dialog box.
| | 02:42 | We simply have, here's a hyperlink.
| | 02:44 | You can make it read-only if you wish,
and if you did, what you would have here
| | 02:49 | would be the URL itself.
| | 02:52 | However, there are times when I use
this that I want to add a little text,
| | 02:57 | because "click here to insert a hyperlink,"
leads me to believe that I'm going to
| | 03:01 | be off browsing, as I was with a
file attachment object, and I'm not.
| | 03:06 | So what I might place here in terms of
information would be something that said,
| | 03:11 | for example, "type or copy from
your browser before you click."
| | 03:19 | So I can provide some really good
information that allows my user to understand
| | 03:24 | what it is that they're going to be doing here.
| | 03:27 | I'm going to select some text here and
then use the format painter to format
| | 03:31 | that instructive text.
| | 03:33 | So, great instructions here that allow
the user to know what they should do
| | 03:37 | first, if they wanted to insert a
hyperlink that was complex, more than they
| | 03:42 | wanted to type, that they could copy
from the browser before they click.
| | 03:47 | This all works good, a really nice
control that has a limited function, but when
| | 03:52 | you want a hyperlink, this is
exactly the control that you wish to use.
| | Collapse this transcript |
| Calculating a value with form data| 00:00 | I don't have a need for any calculated
values in the InfoPath form that we are
| | 00:05 | creating for web posting, but I do
want to make sure you know how to use the
| | 00:10 | Calculated Values control in InfoPath.
| | 00:13 | You'll find this control in the
Object section. In some prior versions of
| | 00:17 | InfoPath this control was called an
Expression box, and it's used when you want
| | 00:23 | to be able to calculate data or have
another place that you as a form developer
| | 00:29 | can enter a value but that
the user can't enter a value.
| | 00:34 | So I have two examples. One is that I
have a first name and a last name and I
| | 00:39 | actually want to know the full name of
the person who completes this form, but
| | 00:45 | there's no reason to have them type three times.
| | 00:49 | I could. I could simply say, type your
first name, your last name, and I'll put
| | 00:52 | the two together, but it's easy enough
for me to calculate the full name once I
| | 00:57 | know the first name and the last name.
| | 00:59 | So I am going to change this control
from a text box to a Calculated Value
| | 01:05 | control. Looks good.
| | 01:09 | I need to be able to tell the
control how to calculate the value.
| | 01:13 | Let's right-click and change
the Calculated Value Properties.
| | 01:17 | Right now, it simply says that it's going to
enter a full name here. Don't worry about this.
| | 01:23 | This is simply some more XML. It's called XPath.
| | 01:25 | I am going to click the Edit formula
button to insert the Insert Formula dialog
| | 01:31 | box and delete this.
| | 01:33 | When I want to put two text strings
together, whether I am in Excel or
| | 01:37 | InfoPath, I use a function
called Concatenate, or concat.
| | 01:41 | So I am going to insert the concat
function, and it will come up with a place
| | 01:47 | for three arguments, separated by commas.
| | 01:50 | I am going to say the first argument
is FirstName, and the last argument is
| | 01:57 | LastName. In between, I don't want a field.
| | 02:01 | I simply want a space, which I'm going to
surround in quotes here as I would in Excel.
| | 02:08 | Let's click the Verify Formula
button. Everything looks good here.
| | 02:12 | I am going to say OK. Notice that the
XPath is changed to OK. And that will be
| | 02:18 | text when it's done, so that a fine format.
| | 02:20 | Let's say OK and preview
this functionality of the form.
| | 02:25 | So if I enter my first name and then
my last name, notice that full name
| | 02:30 | is easily calculated.
| | 02:32 | Even though I am not typing this in the
form, it's stored in the data source, in
| | 02:36 | the full name field.
| | 02:38 | Similarly, I might want to have a
user enter information on items they are
| | 02:43 | buying in a repeating table or a
regular table, and have them enter quantities
| | 02:47 | and price and calculate a subtotal.
| | 02:50 | So I am going to begin by assuming
that there was a subtotal field here.
| | 02:55 | That works nicely, but I'd like to change
this, so that it is no longer a text box
| | 03:01 | but is instead a Calculated Value.
| | 03:03 | So now let's create a formula to tell
InfoPath how to calculate the subtotal.
| | 03:13 | So again, let's click the Edit Formula
button to open the Insert Formula dialog
| | 03:17 | box and say we want to create a calculation.
| | 03:21 | This is very much like Excel, except
you don't need to start with an equals.
| | 03:25 | So we're going to insert a field or
group, and because this is a repeating
| | 03:30 | table, here's my group structure.
And I'm going to say take the quantity
| | 03:36 | and multiply, using asterisk for that, the
Qty by the Price. Verify your Formula. Say OK.
| | 03:44 | If you've done something like typed in
Equal sign in here, it will get caught at
| | 03:48 | this point when you click
Verify Formula. Let's say OK then.
| | 03:52 | My result should be formatted
as a decimal. That's correct.
| | 03:55 | Here is my XPath and I'll
say, ok, we are all good.
| | 04:00 | Now let's preview this portion of the form.
| | 04:02 | So the user says they
are going to order pencils,
| | 04:05 | four boxes of pencils.
| | 04:07 | They are going to pay $55
a box. $220, works nicely.
| | 04:13 | When they insert another item, that
item row also gets a subtotal here for
| | 04:18 | whatever information they would like to enter.
| | 04:25 | This Calculated Value control is a
great control. Even though there are
| | 04:29 | a limited set of functions available to
you in InfoPath, many of them are powerful.
| | 04:35 | They allow you to sum.
| | 04:37 | They allow you to find a highest or
a lowest value, and to do some basic
| | 04:41 | concatenation like we just saw.
| | 04:43 | Don't be afraid to replace a text
box a user would type in with the
| | 04:47 | Calculated Value control, so that you
can have InfoPath do the heavy lifting
| | Collapse this transcript |
|
|
9. Creating Browser FormsUnderstanding browser (thin-client) forms| 00:00 | This is a great time for us to have a
short conversation about thin-client forms
| | 00:06 | or what are also called web browser forms.
| | 00:09 | In InfoPath there are two
ways you can fill out a form.
| | 00:12 | One way is to use the InfoPath Filler,
but we might want to have people who
| | 00:18 | complete a form who don't have access
to the InfoPath Filler. Or we might have
| | 00:23 | a policy, or at least a belief, in our
organization that the best forms are all web-enabled forms.
| | 00:30 | For any of these reasons, we might end
up wanting to create forms that can be
| | 00:34 | completed in a browser.
| | 00:37 | Because when you use a tool like
InfoPath or a Filler you're having to
| | 00:41 | actually run what's called a client
application on your computer that takes up
| | 00:47 | some memory, whereas when you use the web all
the processing is done on the Internet server,
| | 00:54 | the kind of forms that are created for
use that use InfoPath Form Filler or
| | 00:59 | InfoPath are called thick
forms or thick-client forms.
| | 01:04 | Whereas, forms that take advantage
of the power of somebody else's server
| | 01:09 | or somebody else's computer, these
Internet forms are called thin-client
| | 01:13 | forms, meaning web forms.
| | 01:16 | Let's take a look at what our
form is going to look like when it's
| | 01:20 | published here on SharePoint.
| | 01:23 | So I took our form and just published it as
a test, so you could see it before we start.
| | 01:30 | And here is what our form looks like.
| | 01:33 | It actually looks amazingly like our form.
| | 01:38 | It still has all of the controls working.
| | 01:41 | It still has all of the required fields.
| | 01:44 | It still has the text that we are
waiting for from the office of electronic
| | 01:48 | communications. Keeping it here
actually helps them remember that every time
| | 01:52 | we show them the form.
| | 01:54 | My option group works. My dropdowns work.
It's a nice-looking form, and again, I
| | 02:03 | require almost nothing for
someone to be able to run this form.
| | 02:07 | Right now, it's running in Internet Explorer.
| | 02:09 | We'll have a slightly less rich client
experience if I run it with Safari or
| | 02:15 | another browser, but it will still work
in any browser, still allow me to enter
| | 02:21 | information and to post information and
to save it back on my SharePoint site.
| | 02:26 | So welcome to the
web browser or thin-client experience.
| | 02:30 | In the next movie, we'll take a look at
using the Design Checker to get our form
| | 02:35 | ready to publish on a SharePoint site.
| | Collapse this transcript |
| Checking a template for use in a browser| 00:00 | So I've developed this form and
want to know whether or not it's a good
| | 00:06 | candidate for a web browser. Why in
the world would I even wonder this?
| | 00:10 | Well, originally I was aiming this
form at the InfoPath Form Filler, but I
| | 00:16 | liked what I just saw and think I might
want to just make this a web browser form.
| | 00:22 | I know that I'm in the InfoPath
Filler mode because I have lots of controls
| | 00:27 | down here under Containers that just
aren't available for use on the web.
| | 00:33 | So what I'm going to do first is I'm
going to go to File > Save As, and I'm
| | 00:39 | going to save this as a
web browser form template.
| | 00:44 | When I do that, I'm going to get lots of support.
| | 00:47 | First, the set of controls that's
available to me just got shortened because I'm
| | 00:52 | not going to see a single control here
that's not supported in a web browser.
| | 00:58 | Next, because I changed the type of
client I'll be using with this form from
| | 01:04 | Form Filler to the web, the
Design Checker automatically kicked in.
| | 01:08 | Now if it hadn't, I would
still kick it in manually.
| | 01:11 | I would go to File and choose Design
Checker in order to see if there are things
| | 01:16 | about my form that are problematic.
| | 01:19 | There are three levels of
information that you can get here.
| | 01:23 | When you see this little blue
information icon, you know that even though
| | 01:27 | you're getting a warning,
| | 01:29 | as long as you're happy with how the
browser will handle your form, there is
| | 01:33 | nothing here that would prevent you
from publishing this on a SharePoint site.
| | 01:38 | So the first thing it says is that
dialog box actions are not supported,
| | 01:43 | what does that mean?
| | 01:44 | Well, click and it will either show
you something specific in the form or a
| | 01:49 | general message box, or both.
| | 01:51 | It says you've used a rule to automatically
display a dialog box and the web can't do that.
| | 01:57 | Well, of course it can't, and if it
can, like a pop-up window, we as users find
| | 02:01 | ways to turn it off.
| | 02:03 | So it says this dialog box message will not
show when the form is edited in a web browser.
| | 02:10 | I wonder if they are important. I'll
need to check. And then it gives us a
| | 02:13 | tip that says, maybe you could achieve
a similar effect by using conditional
| | 02:17 | formatting to show or hide sections, taking
care of things you don't want the user to see.
| | 02:23 | So what we can do here is we can go
to the Data tab and click the Rule
| | 02:29 | Inspector and see all of the
rules that are in this form.
| | 02:34 | Expand them all, collapse them all if there
is lots and you need to be able to look at them.
| | 02:39 | I'm thinking that the rule that we
aren't having an issue with though probably
| | 02:43 | has some kind of a dialog box in it,
and you see now that it was useful for me
| | 02:49 | to say MsgBox, or include the word
box, in the title of my rule. So it says
| | 02:55 | this dialog box message will not be completed.
| | 02:58 | Therefore, if someone enters an invalid
email address, we're just going to accept
| | 03:04 | it. There is nothing to stop it.
| | 03:06 | And we'll have to either
provide some information--
| | 03:09 | we could provide a little prompt
underneath there--or we can just live with
| | 03:13 | getting partial email addresses,
assuming we won't get many of them.
| | 03:17 | But we could squeeze some text in
underneath here in a very small font that says 'ex:
| | 03:22 | yourname@company.com', and we could make
this really small and that would allow
| | 03:35 | the user to have a good
idea of what we're looking for.
| | 03:37 | So it won't stop them from entering
something wrong, but we're giving them some
| | 03:42 | additional information.
| | 03:44 | Secondly, it says
placeholder text isn't support it.
| | 03:47 | Well, we actually knew that when we put
it in because we saw this message then.
| | 03:52 | So we could go into the text box
property and remove the placeholder.
| | 03:57 | We're asking people not to include
punctuation, but we could do exactly the same thing.
| | 04:03 | We can place our prompt
underneath in a very small font.
| | 04:09 | Say, "Your title will be used as a
file name, so no punctuation please."
| | 04:19 | We even have more room,
"(other than the underscore) please."
| | 04:27 | What's our other placeholder text say?
| | 04:30 | Now, let's go to take a look. Why do
you think this category is appropriate?
| | 04:34 | Well, I can just change my label here,
"Reason post should be in this category."
| | 04:43 | I've now handled all my warnings, and
you notice I didn't actually change
| | 04:47 | the form significantly.
| | 04:49 | I didn't take away the dialog box rule.
| | 04:52 | I didn't remove the placeholder text.
| | 04:54 | I just provided some supplemental information.
| | 04:57 | If I refresh this, it's still going to
give me the same three warnings because I
| | 05:01 | didn't really deal with the issues.
| | 05:03 | I found a way to support the same
information in my thin client, but I'm leaving
| | 05:09 | it here for my thick client.
| | 05:12 | If I wish though, to see some of these
go away, I could, for example, edit this
| | 05:16 | particular text box control, go to the
display, remove the placeholder, which
| | 05:23 | there isn't a way to show in a browser,
| | 05:25 | say OK, and refresh, and you'll
notice I only have two warnings now.
| | 05:30 | So you can use your own judgment here
about whether you want to actually get
| | 05:35 | rid of the things that cause the
warnings or provide a secondary system to
| | 05:40 | remediate the warnings.
| | 05:42 | If, however, you see a circle that's red
with an x in it, that tells you that you
| | 05:48 | have a critical warning, and that's
something that you must address because the
| | 05:52 | form cannot be published as it currently stands.
| | 05:56 | So that's how you use the Design Checker
process to be able to determine if your
| | 06:01 | form can be published as a web form,
what features won't be supported if you
| | 06:06 | publish it that way,
and then address those issues.
| | 06:09 | We now have a form that would be great
to publish as a thin-client form, and we
| | 06:14 | could still publish it for use
in the InfoPath Form Filler.
| | 06:17 | The choice is up to you, and we'll be
publishing in a couple of chapters.
| | Collapse this transcript |
|
|
10. Finishing a TemplateChecking spelling| 00:00 | What a beautiful form, and
too bad it has typos in it.
| | 00:04 | There is nothing worse than creating
great product and then putting it out with
| | 00:08 | small errors that make people
wonder about the entire enterprise.
| | 00:13 | So we are at the point where we are
ready to think about letting somebody else
| | 00:17 | use this form, and before we do, we
would really be wise to check our spelling.
| | 00:22 | Now before we do that, let's just take a look
at the Spelling Options and see what they are.
| | 00:26 | These are the same options that we're
getting from Microsoft Word right here.
| | 00:32 | If you are relatively new to Office 2010,
you might not realize that the options
| | 00:38 | that you set for ignoring words in
uppercase or not, ignoring words that contain
| | 00:44 | numbers, when you set those in any
Office application, you're setting them for
| | 00:48 | all Office applications.
| | 00:50 | So if we change them here, we are
changing them for Excel as well.
| | 00:54 | But if you're happy with the way you
set those in Microsoft Word, they are
| | 00:56 | going to work here too.
| | 00:59 | And then we have two specific
options that are InfoPath only.
| | 01:04 | One is to check spelling as you type,
and that's whether it's the user or
| | 01:08 | you as the developer.
| | 01:10 | If you type a word incorrectly, do
you want that nice little wavy red line
| | 01:13 | underneath it or not?
| | 01:15 | And the second is to hide spelling
errors, and if you check the spelling but
| | 01:18 | hide the errors, you won't
necessarily know that anything was wrong.
| | 01:23 | You can leave these settings as they
are typically, and they'll work for you
| | 01:26 | because you're used to them in
other Microsoft Office products.
| | 01:30 | Let's go ahead and click OK,
and let's run a spell-check here on our form.
| | 01:36 | When I was typing, I didn't let the
shift key go quickly enough, and FIrst has
| | 01:40 | two initial capital letter,
so let's change that.
| | 01:44 | Sugested is spelled wrong.
| | 01:47 | Let's go ahead and fix that.
| | 01:49 | It says, "including rationaled."
Probably means rationale. Let's fix that.
| | 01:55 | The spell-check is now complete, and I know
that every word in here is correct, almost.
| | 02:02 | Any information that I put in a
placeholder will not be spell-checked, and this
| | 02:07 | is sort of a weird thing, because this
placeholder is set that when a user enters
| | 02:12 | information, it will spell-check.
| | 02:14 | Take a look at this behavior.
| | 02:18 | If the user enters incorrect
information, then the spell-check will eventually
| | 02:23 | catch this for them.
| | 02:26 | Notice one error after another. But if
my placeholder itself is incorrect, the
| | 02:31 | form will go out with a typo in it.
| | 02:34 | So pay particular attention to each and
every piece of placeholder text that you entered.
| | 02:40 | You'll find this information on the
Display tab of the Text Box Properties, and
| | 02:45 | you need to make sure that your
placeholders are spelled correctly because
| | 02:50 | InfoPath will not do that for you.
| | 02:54 | Here's another one.
| | 02:55 | Let's look. Are we comfortable?
| | 02:57 | Is that correct? This you have to do by
yourself. Maybe in a future version of
| | 03:01 | InfoPath spell-check will reach in
and catch those placeholders for us too.
| | 03:06 | Once we are convinced that the spell-
check is working just fine, then we can
| | 03:10 | save our form and know that we can
send it out feeling very, very comfortable
| | 03:15 | about how it will work.
| | 03:17 | If you by chance create forms that
are in more than one language, so
| | 03:23 | some section of the form in English,
for example, and another section
| | 03:27 | for accessibility purposes in Spanish, then
you'll need to set your proofing language.
| | 03:34 | So you mark this view as an English
view, and then when you create a second
| | 03:40 | view, you can actually say, well,
this view should be checked using a
| | 03:44 | different dictionary.
| | 03:45 | For example, this particular view
that we created is US Spanish, is Puerto
| | 03:53 | Rican Spanish, and so on.
| | 03:57 | So if you wanted to have a form that was
created with different views to support
| | 04:02 | users using different languages,
the spell-check will still work.
| | 04:06 | You just need to choose particular
spelling options for each of the different
| | 04:11 | views created for people speaking and
filling out forms in different languages.
| | 04:16 | It's a powerful spelling tool. You don't
have the grammar tool you might wish you had.
| | 04:21 | So remember, also, that in addition to
checking any place that you've added
| | 04:25 | prompts or text within a
control, you need to check it.
| | 04:29 | You also need to check the
grammar throughout the form.
| | 04:34 | When you're all done, you're in good shape.
| | 04:35 | Your spelling has been checked by
InfoPath, your grammar has been checked by
| | 04:39 | you, and you can feel great
about releasing this form.
| | Collapse this transcript |
| Enabling digital signatures in a form| 00:00 | In InfoPath there are three reasons
that one might digitally sign a form.
| | 00:05 | We will dispense with the first reason quickly.
| | 00:08 | If someone is developing a form, like
you are, like I am, and we want to use that
| | 00:12 | form in a variety of settings, and that
form obtains data using a web service, a
| | 00:19 | database, or a SharePoint list, then it
is prudent and sometimes necessary for
| | 00:26 | the developer to apply a
special signature to that form
| | 00:30 | that's called code signing.
| | 00:32 | If you code-sign a form, then that form
can travel more easily because it has
| | 00:38 | proof of who you are.
| | 00:40 | That kind of a digital signature is a
little bit expensive and requires you to
| | 00:45 | provide some rock-solid
information about who you are.
| | 00:48 | The other two reasons that we would
sign a form are the same kinds of reasons
| | 00:53 | that we might sign a Microsoft Outlook
email message, or a Word document, or a
| | 00:58 | PDF that we were sending to some agency.
| | 01:01 | We sign a form to do two things.
| | 01:05 | One is to say that this is me.
| | 01:08 | I signed this form. And the other locks
the fields on the form so that no one
| | 01:13 | can change it after you sign it.
| | 01:16 | If they want to edit the form that you
have saved, they actually are forced to
| | 01:21 | remove your digital signature first.
| | 01:24 | They can change the data, but they can no
longer say it's the data that you provided.
| | 01:28 | You can sign entire forms in many
applications, including the Office
| | 01:34 | applications and Adobe Acrobat;
| | 01:37 | however, InfoPath allows you to sign not
just an entire form, but a section of a
| | 01:43 | form. And let me be very specific. I can
sign a group. So if I want to be able to
| | 01:51 | have someone sign this section, or this
section, or all of posts, or a specific
| | 02:00 | group in posts, that works.
| | 02:03 | I can also say that someone can sign
this section and this section separately.
| | 02:08 | I cannot, however, sign one or
two fields within a section.
| | 02:13 | So in order to apply a signature to part
of a form, I need to make sure that the
| | 02:20 | fields that I need to have signed
are all in one section together.
| | 02:25 | I created this form with signatures in mind.
| | 02:29 | So, for example, I might fill out the
top part of the form myself as a user, and
| | 02:34 | then I might choose to sign it.
| | 02:37 | This newcontentarea requires a
signature from someone who has enough authority
| | 02:43 | in the company to actually
request a new content area.
| | 02:46 | So that might be a separate signature.
| | 02:49 | The Post section perhaps I don't need to
sign at all because no one is approving that.
| | 02:54 | Signatures are typically used as
some part of an approval process.
| | 02:58 | So once I fill the top of this out and
signed it, then I might want to have a
| | 03:02 | second signature down here.
| | 03:05 | One more thought about this.
| | 03:07 | Because the Area name and Description
are not in the first part that would be
| | 03:12 | signed, the person who's approving this
will actually have the ability to edit
| | 03:17 | these before they sign.
| | 03:19 | If I want to ensure that whatever the
initiator of this form has placed in these
| | 03:25 | fields gets locked down, I would
actually move it up into this section, so it
| | 03:31 | could be signed in the first place.
| | 03:34 | So, with our digital signature enabled, we can
sign either the whole form or part of the form.
| | 03:41 | Let's take a look at how this is going to work.
| | 03:45 | I'm going to choose File, and then
not Options here, but Advanced form
| | 03:51 | options, and click.
| | 03:54 | The From Options dialog box
opens, and I'll choose the Digital Signatures category.
| | 04:00 | By default, this form is not set
up to allow digital signatures;
| | 04:05 | however, if I want the user to be able
to sign the entire form, I simply enable
| | 04:10 | the second option button. And if I
want one or more users to sign sections of
| | 04:16 | the form, then I choose the third
option, Allow signing parts of the form.
| | 04:22 | That's what I would like to do in this case.
| | 04:23 | So I am going to now add the sections
that I'd like to be able to make signable.
| | 04:29 | First I need to enter a name for the
data, and this is actually the requestor
| | 04:34 | information that I'm going
to allow the person to sign.
| | 04:38 | So I could call this FormCompletedBy,
for example. Requester is not all that
| | 04:45 | helpful or FormCompleterData.
| | 04:52 | Another option would be
FormOwner. Another would be FormFilledOutBy.
| | 05:00 | No spaces. I am using upper- and
lowercase, or CamelCase as it's called, to
| | 05:05 | make sure that you can read it, because
a user will need to read what I typed in
| | 05:10 | here later. And then I can choose
the fields and groups to be signed.
| | 05:14 | When I click the Select XPath button,
it's actually going to open myField list,
| | 05:19 | and I'm going to say that this
signature is for the requester.
| | 05:23 | Now again, I could choose one field,
but I can't choose multiples, and that's
| | 05:27 | why I'm using sections here.
| | 05:31 | I have three options. The first
option is one signature. The second is this
| | 05:37 | requires two or more
signatures obtained independently.
| | 05:41 | An example of this would be a company
where the policy is that two director-
| | 05:46 | level signatures are required for any
purchase over $1,000. And then the third
| | 05:51 | possibility is that two people are going
to sign this, or three, or four; however,
| | 05:57 | they will sign in a particular order.
| | 05:59 | First, the employee, then their supervisor,
then the director, then the vice president.
| | 06:05 | I only need one signature on this section.
| | 06:08 | When the user signs the form,
they will see this message.
| | 06:12 | It's standard message. If you don't have a
reason to change this, let's just leave it.
| | 06:19 | Now I want to add another signature.
| | 06:22 | This is for ApprovalForNewContentArea,
and the fields and groups to be signed
| | 06:31 | here is this group that falls
into the second optional section.
| | 06:35 | So I'm going to say OK,
and it's only one signature.
| | 06:39 | I could change this message and say,
verify that you are signing this and that
| | 06:44 | the prior section of the
requester information is also correct.
| | 06:48 | But people will get this as it goes along.
| | 06:50 | Let's say OK. Two sets of assignable data.
| | 06:53 | I am going to say this is just fine.
| | 06:56 | So my template is now ready to
allow users to apply digital signatures
| | 07:01 | to specific sections.
| | 07:03 | I would have followed much the same path
to allow users to sign the entire form.
| | 07:08 | In the next movie, we will see how
the users will actually sign this.
| | Collapse this transcript |
| Using a digital signature| 00:00 | In the last movie, we enabled our form
so that it could use digital signatures.
| | 00:05 | Now we've opened that form in the
InfoPath Form Filler so we can see what the
| | 00:10 | user experience will be like.
| | 00:12 | Although I can look at some of this in
Preview, I actually can't save the form
| | 00:17 | in Preview in a way that I can reopen it.
| | 00:20 | So I've chosen to leave InfoPath
Designer and go all the way up to the Form
| | 00:24 | Filler to test this form.
| | 00:27 | So I'm going to type my name and my email
address, and work phone is not required.
| | 00:39 | I'm testing, so I want to limit the
number of required fields I have to deal with.
| | 00:43 | I am in Customer Service.
| | 00:44 | I'm going to give it a title,
and description is required also.
| | 00:51 | But I don't have to put much information here.
| | 00:54 | I don't see any other required fields.
| | 00:57 | I want to request a new content area.
| | 01:00 | So I'm going to click here to open this,
and I'm going to give a suggested area
| | 01:04 | name. And I'd actually like to suggest
that we include a new content area that's
| | 01:10 | aimed particularly at hikers. And I
can provide some other information.
| | 01:19 | Now, I'm ready, actually, to sign my
part of the form, which is just the
| | 01:23 | section that's up here.
| | 01:25 | So I'm going to go to File
and actually click Sign Form.
| | 01:29 | I'm going to add a digital signature
to the FormFilledOutBy area, and I'm
| | 01:35 | going to type my name.
| | 01:36 | Now I can insert an image here.
I want to give you a piece of advice.
| | 01:40 | I've seen some people scan their
actual signatures and use those as images.
| | 01:46 | You have no idea where that
picture is going after it leaves here.
| | 01:50 | So my sense is, if you want to select an
image, it should actually be some kind
| | 01:54 | of an iconographic image, rather than
having copies of your signatures floating
| | 01:59 | around all over the universe.
| | 02:02 | So purpose for signing this document
is 'want to submit this request', or I can
| | 02:08 | leave this blank if I wish. And I'm
signing with my digital signature.
| | 02:15 | I might have another one on
here too that I could use.
| | 02:18 | This is my code-signing signature that I
use as a developer with forms, but this
| | 02:24 | is my signature that I obtained.
| | 02:26 | I actually got it for
free, and that's good enough.
| | 02:29 | However, it will tell me it can't be verified.
| | 02:32 | That's because this is a
relatively cheap signature.
| | 02:36 | But I'm still going to say okay,
because that's the signature I'm using.
| | 02:41 | If you want to use digital signatures
within your organization, it's a help to
| | 02:45 | know that anyone else is using them.
| | 02:47 | Assuming that digital signatures
are not being used, plan on having an
| | 02:51 | extensive conversation with your IT or
IS department to make the case for why
| | 02:57 | they might want to use them.
| | 02:58 | When individuals need to provide their
own digital signatures, they're still
| | 03:02 | relatively anonymous.
| | 03:04 | You go click on the Internet and obtain one.
| | 03:07 | But within an organization, normally
there is a way that the Information
| | 03:11 | Services people can put together a
certificate server that will be good enough
| | 03:16 | to really guarantee that your
signatures are valid within your firewall.
| | 03:21 | So I've signed this.
| | 03:23 | I can now go take a look and view
the signatures that are being used.
| | 03:27 | I could go view the certificate if I
wished, which would tell me Windows doesn't
| | 03:30 | have enough information to
verify it, and say OK and close it.
| | 03:36 | Now, I'm going to simply save
this document on my desktop.
| | 03:41 | We're going to open it again in a moment.
And this is going to be my hiker request.
| | 03:48 | So here's the form.
| | 03:49 | I've emailed this to someone else, my
supervisor, and they're going to go in and review it.
| | 03:54 | And you'll notice that when they click
on any field that was digitally signed,
| | 03:58 | there's a small certificate that
shows that it was signed by someone else.
| | 04:04 | If my boss tries to go in and enter
different information in here, they see this
| | 04:11 | dialog box that says you can't change this.
| | 04:15 | The only way in fact they can
change this is to go back and to remove
| | 04:20 | the digital signature.
| | 04:21 | There are plenty of tools that will
allow them to do that, but in doing so, it's
| | 04:25 | very clear this is no longer the
document as I sent and guaranteed it.
| | 04:30 | So now let's say that my boss continues
and says, "I think this is a great idea."
| | 04:35 | Because I left these fields in the next
section, they could even add more text
| | 04:40 | and a better description of the
information that they think would be needed,
| | 04:45 | make the case a little stronger, and then
they're all done, and they're ready to sign the form.
| | 04:50 | So they return and say that they would
like to add another signature, and notice
| | 04:57 | now that they can sign the
ApprovalForNewContentArea.
| | 05:00 | It won't allow them to over-sign the
content that I already signed because I
| | 05:06 | only allowed one signature in the design.
| | 05:09 | But they can say, "I'm ready to
approve the new content area."
| | 05:12 | They can then put their own signature
in here, add an image if they wish, type
| | 05:17 | their own text if they wish, and sign this.
| | 05:23 | Because I was showing you, I used my
own certificate twice. Normally, you would
| | 05:27 | see two different people's digital
certificates here. And when my boss is done
| | 05:31 | with this, and they close it, and save it,
| | 05:36 | now the next time we open this form,
you'll notice that this section can no
| | 05:42 | longer be edited either.
| | 05:44 | That's how digital signatures work.
Within a particular document as you move
| | 05:49 | it through a workflow in your office, each
successive approver gets their own section to sign.
| | 05:55 | It's very easy to set up, very
easy to apply, very powerful.
| | 06:00 | Enjoy using digital signatures with InfoPath.
| | Collapse this transcript |
| Testing a template| 00:00 | We're entering the endgame for this form.
| | 00:02 | The next few things we're going to do
are creating views, preparing the form to
| | 00:08 | be submitted, and then publishing the form.
| | 00:11 | So before we take those steps, this
is a good time to test our form again.
| | 00:16 | There are two approaches to form testing:
| | 00:19 | one of them is sort of casual and the
other is fairly formal--and I'd like to
| | 00:24 | hit a place that's more towards the formal
| | 00:26 | but starts with the former, the casual.
| | 00:30 | At this point I will usually have a
couple of other folks in my office just
| | 00:35 | test the form, and their job at this
point is actually just to take it out for a
| | 00:39 | spin, but drive it really hard.
| | 00:42 | If they can make its wheels fly
off, then they get extra credit.
| | 00:45 | I'll take them out for dinner. Because I
want to know if this form can be easily broken.
| | 00:50 | So their job is to go into Preview
mode and to try everything on the form.
| | 00:55 | Now, this is where we start talking
about the part of this that's a little more
| | 00:58 | formal, because there are a series of
things that they know to check, and I'd
| | 01:02 | like to make sure you
know to check them as well.
| | 01:05 | First, a basic run-through of the form
is to check its tab order, just to tab on
| | 01:09 | each control and make sure that they
come up in order, that we don't drop to the
| | 01:13 | end of the form and back.
| | 01:15 | If we do, then we'll actually want to
do something to adjust the tab order of
| | 01:20 | our controls in our form, one of its properties.
| | 01:23 | The next thing is they need to
make sure that every control works.
| | 01:27 | So they'll type text in controls,
and make sure that each of the controls works.
| | 01:32 | They'll also check rules, and so I
will give them a list that says you must
| | 01:37 | enter, for example, a complete email
address, and I'll show you in a moment how
| | 01:41 | to create that list.
| | 01:42 | So they're actually making sure that
each of the controls is going to work.
| | 01:49 | They want to make sure that every
department that should be on the list is on
| | 01:53 | the department list, that every category
that should be in the Categories list is there.
| | 01:58 | But remember that part of testing
controls is testing each optional section,
| | 02:03 | first to insert it, then to be
able to remove it, like this, and then
| | 02:10 | entering information in it.
| | 02:12 | We'll do the same thing here where
we'll click to add another category and
| | 02:19 | then go back up and say I'd like to remove
this category or insert one before and after.
| | 02:25 | Don't just test the input controls; test
the container controls as well and make
| | 02:30 | sure that they work.
| | 02:32 | Make sure check boxes check and uncheck,
and that in this example, another rule,
| | 02:38 | if this check box is checked, then this
field should be enabled, and if it's not
| | 02:45 | checked, they should not be able
to type here or use the date picker.
| | 02:50 | They should make sure that if they click
to attach a file, it actually opens the
| | 02:54 | Attach File dialog box, and that the
option buttons, if one is clicked, the
| | 02:59 | others are turned off.
| | 03:01 | So this is the process to walk
through and make sure--and another whole
| | 03:06 | post gets inserted here. This looks great!
| | 03:09 | We're checking every control for a section.
| | 03:12 | We're checking to ensure that the
contents of dropdown lists are correct,
| | 03:17 | that if it says select or type, that I can
actually type, that it is indeed a combo box.
| | 03:23 | Let's go take a look at where
you'll find that rules list for them.
| | 03:26 | You can go to Manage Rules here,
but that's managing rules for the control that
| | 03:30 | is currently selected.
| | 03:32 | Let's go instead to the Data tab
and click the Rule Inspector.
| | 03:37 | Here are all of the calculated values'
actions in this form, and we would have
| | 03:43 | validation if there was validation to be had.
| | 03:45 | So what we know is that we want to
print this out and hand it to our testers
| | 03:51 | and say, "Here are the things to check," to
make sure that Today field is equal to
| | 03:56 | Today and that when they click on the
email and enter an invalid email that they
| | 04:02 | see this message box.
| | 04:03 | So this is a testing tool, this Rule Inspector.
| | 04:07 | We have a couple of other things that we
need to be able to check in our form as well.
| | 04:12 | We've enabled digital signatures here,
so we would like our users to make sure
| | 04:18 | that after they have filled in all of
the information for required fields, that
| | 04:24 | they are then able to sign this form.
| | 04:27 | So they can go to File > Sign Form.
| | 04:30 | Now, if they haven't filled out all of
the required fields, they can still sign
| | 04:34 | it, but it should tell them that
they actually can't sign it yet.
| | 04:38 | So let's say I'd like to sign this
section, and it says there are validation errors.
| | 04:45 | We expected that. And I can say I still
want to sign it, and it should allow me
| | 04:49 | to actually apply a signature.
| | 04:50 | Then after the signature has been
provided, I should not be able to make changes
| | 05:03 | to the section of the form I signed.
| | 05:05 | That was actually not the right
section of the form. There we go!
| | 05:09 | It can't be inserted because it's been
digitally signed. Makes sense, all right?
| | 05:17 | So I'm testing to make sure
the signatures can be applied.
| | 05:22 | I'm checking to make sure the
signatures can be removed and that after they're
| | 05:27 | removed, that I can again go in and
make changes to whatever section had
| | 05:32 | previously been signed.
| | 05:33 | The last thing I want to be able to do
is ensure that once information has been
| | 05:37 | filled in, if I have believed that I
filled in every required field, that I can at
| | 05:44 | least save this form, and so when I go
to Save, I should not see this dialog box
| | 05:50 | if I have filled in all the appropriate fields.
| | 05:52 | So the best thing to do is to have a
couple people start testing your form and
| | 05:59 | give them information on what they need to test.
| | 06:01 | Walk them through, have them see this
movie, so they know what to look at.
| | 06:05 | Then give them a log.
| | 06:07 | You could even create a form where
they can type what they were trying to do,
| | 06:11 | what control they were in, and what
they believe is a problem with the form.
| | 06:15 | After you've tested your form with
your friends and made any changes that are
| | 06:20 | required, then you can begin doing the
real testing, and that's again when you
| | 06:25 | have people who aren't necessarily
your friends, but who have an interest in
| | 06:29 | the form performing well, using the form
without your assistance and without any guidance.
| | 06:34 | Users who are unfamiliar with the form
will stretch its boundaries by trying to
| | 06:39 | enter what they think you're asking for,
rather than what you've told them you're
| | 06:42 | looking for, and in that way, you'll
discover issues with the form that you and
| | 06:47 | your friends are not as likely to find.
| | Collapse this transcript |
|
|
11. Creating ViewsCreating views| 00:00 | I've added one more section to our
form since the last time you saw it.
| | 00:05 | We have a wonderful form for the user,
but we need a section at the bottom so
| | 00:09 | that the staff who will actually create
these new content areas or post these files
| | 00:14 | and descriptions will be able to
indicate that their work was done, or to keep
| | 00:18 | notes on the work that they did.
| | 00:21 | So here's the Office Use section at the
bottom of the form, and it is shaded, as
| | 00:26 | Office use sections often are.
| | 00:29 | Now we could type 'For office use only'
on this form as you often see with paper
| | 00:35 | forms; however, we don't need to.
| | 00:38 | In InfoPath 2010 we can actually
ensure that the user won't even see this
| | 00:43 | form section, so they won't be
tempted to type in it at all, and we'll do
| | 00:47 | that by using views.
| | 00:52 | As you may recall from earlier, a view
is simply one way to look at this data set
| | 00:57 | here, one set of controls and other
containers that allow a user to enter data.
| | 01:04 | If I want to have different ways to
view this data, I can store all of those
| | 01:09 | different views in the same template.
| | 01:12 | Let's go to the Page Design tab
because this is where we work with views.
| | 01:16 | When we create a new form in InfoPath,
it is the default view, and it is named
| | 01:21 | view1--great name for it.
| | 01:24 | This view is actually the complete
form, and so what I'm going to do is I'm
| | 01:28 | going to change the name of this view.
What I'll usually say is something like all fields.
| | 01:35 | This is my developer's view, so I've
sometimes also called it Developers.
| | 01:41 | I keep one version of the form that's
my view of it in every single form that I
| | 01:47 | create, because when we start to create
other views each of them will simply be
| | 01:54 | a variation of the total
form, with all of its sections.
| | 01:58 | So I'll take the form, save it for myself,
and then start deconstructing it for my users.
| | 02:04 | Let's first create that form that we
want the users to see that does not
| | 02:08 | include this section area.
| | 02:11 | I'm going to begin, because I'm here
already, by doing a Ctrl+A to copy the whole
| | 02:17 | view and say Ctrl+C to copy.
| | 02:21 | Now I'm going to create a new view, and
this is going to be the new default view.
| | 02:28 | So, I could call this default, I could
call this User Data Entry, and notice that
| | 02:36 | I'm allowed to place spaces here.
| | 02:39 | So it begins, as every view does,
with a table, but I don't want it.
| | 02:43 | I'm going to delete the table, hold
Ctrl and hit V, and paste my entire form in.
| | 02:49 | I now have two views, and they're
identical, and I can choose them here: the
| | 02:53 | Developers view and the User Entry view.
| | 02:57 | In the User Entry view, I do not want
to have this section appear, so it's
| | 03:02 | easy to take care of.
| | 03:03 | I'll scroll to the bottom and delete it.
| | 03:06 | Now when a user previews this in the
User Entry view, notice no section at the
| | 03:15 | bottom for office use only.
| | 03:19 | Now I want to create a view for the
folks who are going to complete this request.
| | 03:25 | So let's go back to Page Design.
| | 03:27 | Let's create another new view, and I'm
going to call this new view OEC Use,
| | 03:34 | Office of Electronic Communications.
| | 03:36 | Once again here's my table.
| | 03:38 | I don't want it, and I'm
simply going to paste this in.
| | 03:42 | Now, if there was any information on
this form that the OEC folks didn't need,
| | 03:47 | for example, the instructions on the
top on how to use a form that they still
| | 03:51 | need to provide, I can delete that,
and indeed I can actually delete this whole row.
| | 03:56 | They don't need to have
that kind of instruction.
| | 04:00 | And it may be that as I scroll down
I would find other information that
| | 04:04 | they simply didn't need, but this
appears to be approximately the view that
| | 04:08 | they would require.
| | 04:09 | So now if I go back to Preview, what
I'll find is the User Entry view that has
| | 04:16 | instructions, the Developers view
which has everything, and the OEC Use view
| | 04:23 | that does not contain those instructions.
| | 04:25 | There's one other view I'd like to provide.
| | 04:28 | I've allowed users to suggest category
and department interest information, but
| | 04:33 | the folks in our OEC department are
perfectly capable of abstracting that out of
| | 04:38 | the post description.
| | 04:40 | So I'm going to provide an express
form for people who do not feel a need
| | 04:44 | to provide post category information,
department info information, or news information.
| | 04:51 | So those three sections I won't need.
Additionally, they won't require this OEC,
| | 04:57 | Office of Electronic
Communications Use Only section.
| | 05:01 | Now, this is where we begin to want to
make sure that we have a really good
| | 05:06 | process around this.
| | 05:07 | If I begin with the OEC Use section,
I'll have to remember to delete this as
| | 05:12 | well, and also I will forget, perhaps,
that the OEC Use section doesn't include
| | 05:18 | basic information for users.
| | 05:20 | So my discipline is that I will
always go back to the entire set. This is
| | 05:26 | everything that could possibly be here,
the master developers Form, and create a
| | 05:31 | new view from here
that's called Express Request.
| | 05:37 | Delete the table. I still have the
same stuff on the clipboard that I
| | 05:41 | had before, everything.
| | 05:45 | I'm going to create my Express view,
Express Request, my Post, but deleting this
| | 05:53 | repeating table, this repeating table,
this entire section, this heading, and
| | 06:02 | all of the extra space.
| | 06:03 | Now again, I don't want my user to see
this section either, so we'll simply delete it.
| | 06:12 | Cool. Let's go to see how
it looks. Home > Preview.
| | 06:17 | So here's my Express request. The Preview
will always open with whatever I just created.
| | 06:23 | Nice and short, but if a user wants to
do something more complex, there is the
| | 06:28 | detailed user entry form with all of
these additional fields. Very slick.
| | Collapse this transcript |
| Creating a print view | 00:00 | In addition to the views that we've
created for Express Request, for Office Use,
| | 00:05 | and for User Entry, we might want
to create a print view for this form.
| | 00:10 | Let me begin with a pretty significant caveat.
| | 00:14 | If you know that you want to create a
form that will print on two pages, it's
| | 00:20 | really helpful to start from
scratch with a two-page form.
| | 00:23 | Each of the page layout templates is
essentially creating a place that you could
| | 00:28 | insert a page break.
| | 00:30 | So if we go into a new form for just a
moment, on a blank form, I can put a page
| | 00:35 | break below this page, but not within it.
| | 00:38 | So if I knew that I wanted to have a
two-page form, I should start with a two-page form.
| | 00:44 | And if I don't want a title on the
second page, I simply delete that row.
| | 00:51 | Right now, if I were to take this into
Print Preview and take a look at it, I
| | 01:01 | have a one-page form with two
pages, so to speak, within it.
| | 01:07 | However, what I have is the
capability of inserting a page break.
| | 01:11 | If I click between the forms and
press Enter, then and only then is my Page
| | 01:17 | Break button enabled.
| | 01:19 | I can't insert a page break here or here
or here, but between these pages, I can.
| | 01:25 | And now I can create a form
that will print on two pages.
| | 01:29 | If I already have a form with controls
and I need it to print on two pages, I'll
| | 01:34 | simply insert another page and
move some controls to that page.
| | 01:43 | With our form, that would be incredibly
difficult to do, and the reason is that
| | 01:47 | this form, which was designed to be
used on screen, has a number of sections.
| | 01:53 | And while I can't put a page break
anywhere but between pages, I can't have
| | 01:58 | a section span pages.
| | 02:00 | And so with my very long Post section in
this form, that's all going to print on
| | 02:06 | one page every single time I
print it, from here on down.
| | 02:10 | So the only possible place to insert a
new page for me that would be worthwhile
| | 02:14 | in my form would actually be here.
| | 02:17 | And I could consider inserting another
page template and moving this to the page.
| | 02:21 | It's as easy as every other time
we have cut and paste in the form.
| | 02:24 | But that would give me such a small
area up at the top that it's really
| | 02:28 | not worthwhile for me.
| | 02:30 | This is largely a browser-based form
and browser users are used to forms
| | 02:34 | printing at unusual places, and with
the huge amount of expandability we've
| | 02:38 | placed in this form, we're not that concerned.
| | 02:41 | I do, however, want to create a print
view, and I want to create a print view
| | 02:45 | because I would like to have a view
that is going to print in black and white,
| | 02:50 | that doesn't have shading on it,
and that would print all of the fields that
| | 02:54 | were necessary from the User Entry form.
| | 02:58 | We can also create a print view
for our Express User Entry form.
| | 03:02 | So let's start with our User Entry form,
New View, and call it Print User Form.
| | 03:14 | Once again, you'll remember that we
have a table that we need to get rid of.
| | 03:19 | I can switch back to my User Entry form,
do a Copy All, Ctrl+A, Ctrl+C, switch
| | 03:28 | back to my Print User Form view, and paste it.
| | 03:32 | Now what I'd like to do is change the colors.
| | 03:39 | There is a mostly-black-and-white form.
| | 03:41 | Now when I print this, I don't
need to have this row any longer.
| | 03:45 | The user has already filled it out.
| | 03:46 | We don't need to have instructions.
| | 03:50 | So that's a print view of my
user form. Looks pretty good.
| | 03:54 | I could strip out anything else I wanted.
| | 03:56 | If you really want to save some space,
you can do things like change this to a
| | 03:59 | smaller font, subheading.
| | 04:01 | I can also place a header
and footer in this view.
| | 04:04 | For example, I might want to have a
header that had the Short Date or the Long
| | 04:10 | Date, and I can print that anywhere
I'd like. And perhaps I'd like to have a
| | 04:15 | footer that has some other information in it.
| | 04:18 | Notice that it will pick up
basically the settings for the Text Box field
| | 04:23 | and use them here in terms of font
formatting, but there is a Short Date in my header.
| | 04:31 | And if I now go to Print and preview it,
there's my Short Date up here at the top.
| | 04:38 | I can enter other text if I wish,
like the text printed on and so forth.
| | 04:43 | I can say that the default print is to
print in Collated view, 1 copy, users
| | 04:48 | can overwrite these.
| | 04:49 | And finally, I can say I would like
to Print Multiple views, and what that
| | 04:52 | allows you to do is to create
sort of an omnibus print for a form.
| | 04:57 | We wouldn't do that for our form,
but you might have a form where users fill out
| | 05:01 | one part and then another and another.
| | 05:03 | No matter what view they print from,
you want to make sure that they include
| | 05:07 | both this information and that information.
| | 05:10 | So you choose that and set that as your
default settings for printing the form.
| | 05:14 | The user still can always
choose another view to print it.
| | 05:19 | Once I have my information set for
Print Settings, I should also take a look at
| | 05:24 | Page Setup, and you'll notice that
almost everything here is set for default.
| | 05:28 | Default paper, default size.
| | 05:30 | If you have a form that always has
to print at a particular printer--for
| | 05:34 | example, you create a form
that needs to go to purchasing--
| | 05:39 | you could set it so that it always
printed by default to the purchasing
| | 05:42 | department's inbound printer.
| | 05:44 | Not a bad way to make sure that it gets
there if they want to have a printout as
| | 05:48 | well as an electronic copy every single time.
| | 05:52 | But I'm liking this print version, so
we're going to go ahead and simply leave that.
| | 05:57 | And remember, we could click Express
Request and create a print view here just
| | 06:02 | as easily, and probably should,
simply because the people who use Express
| | 06:07 | Request will wonder, where did
all these extra fields come from?
| | 06:10 | So here's our new view, Print Express Request.
| | 06:18 | You know how this works.
| | 06:20 | Let's go back to Express Request,
Ctrl+A, Ctrl+C, back to Print, drop it in,
| | 06:32 | change its color, get rid
of this row. Looking good.
| | 06:40 | So, quickly and easily, we can create different
views that are going to be used for printing.
| | 06:47 | In the next movie, we'll see how to
make these print views more easily
| | 06:51 | accessible for the users.
| | Collapse this transcript |
| Setting view properties | 00:00 | Each view has a set of properties, and
those properties are used to determine
| | 00:05 | when the view will be available,
whether or not it's the default, and if a user
| | 00:10 | prints while they see this view,
what print view should be used.
| | 00:14 | So let's go ahead and click on Properties.
| | 00:17 | We're currently looking at the Express
Request form. And you'll notice on the
| | 00:22 | General tab the name, which you we
could change here, the fact that it is not
| | 00:26 | the default, and that it is shown on the
view menu when users are filling out the form.
| | 00:32 | So what that means is that when we
look at the preview, that it will appear
| | 00:39 | on this dropdown list.
| | 00:47 | If we want to set this as the default
view because we'd like most users to be
| | 00:51 | able to fill out the short form,
we'll simply choose that here.
| | 00:55 | We can choose to use a background color
or background picture, show scroll bars,
| | 00:59 | and so on, in this form.
| | 01:01 | Now I'm going to click on Print Settings.
| | 01:03 | In the prior movie, we created a print
view especially for this particular form,
| | 01:10 | a black-and-white view that
doesn't have any of the explanatory text.
| | 01:14 | So I'm going to click this dropdown and
choose the corresponding print view, and
| | 01:19 | that will now be used as the default
view when a user is looking at this view
| | 01:24 | and chooses to print it. Take a look.
| | 01:29 | If we go Home and we preview this view,
and then we go to File > Print > Print
| | 01:36 | Preview, take a look.
| | 01:37 | It switched views for us.
| | 01:39 | That's how easily we can make this happen.
| | 01:42 | Now, let's go back and
choose our Developers view.
| | 01:50 | When I look at the properties of the
Developers view, I'm actually going to make
| | 01:54 | this a view that is not available to users.
| | 01:57 | I don't want them to see this.
| | 01:59 | This is my development copy.
| | 02:01 | We're just going to hide it back
here. And now when we preview, notice, no
| | 02:10 | Developers view anymore.
| | 02:13 | And then finally, I'll go back to
Page Design properties, but first, let's
| | 02:20 | switch to the User Entry version.
| | 02:24 | Now we set up a print view for this as well.
| | 02:26 | So, let's click Properties, and on
Print Settings, say, if a user is using the
| | 02:31 | long form, then use this print view.
| | 02:37 | So, when we preview, we'll
see a much shorter list.
| | 02:42 | It actually only has five items on it.
| | 02:45 | It has User Entry and its corresponding
print form, OEC Use, Express Request and
| | 02:53 | its corresponding print form.
| | 02:55 | If I don't want users to be able to
switch to the print view here, I can simply
| | 03:00 | not have them appear on the menu.
| | 03:02 | I can shorten this list to be only the
forms that people would actually fill out
| | 03:06 | on screen. Simple enough to do.
| | 03:08 | Go to Page Design, choose our first
print view, set its properties so it does
| | 03:15 | not show on the view menu, go to our
other print view, set its properties so
| | 03:22 | that this also will not
be shown on the view menu.
| | 03:25 | You might wonder what
happens with our third form view.
| | 03:29 | We have this OEC Use view.
| | 03:31 | If we print this, how does it print?
| | 03:35 | Well, it will print using the default
settings for a view, which means that it
| | 03:40 | will print using itself.
| | 03:42 | If we want to create a different
view for OEC to print from, we can, but
| | 03:45 | there's really no need.
| | 03:47 | Let's go back to Home. Choose Preview.
| | 03:51 | You'll see our short list here, with
three choices: User Entry, OEC Use,
| | 03:55 | and Express Request.
| | 03:57 | Here's our default.
| | 03:59 | Now, Express Request, now that we've
made it our default, User Entry probably
| | 04:02 | deserves another name that says
something like Detailed Request.
| | 04:07 | Let's switch back to Page Design
and switch to our default form.
| | 04:11 | So here's our user experience.
| | 04:13 | When we go Home and click Preview,
our user will initially see the
| | 04:18 | Express Request form.
| | 04:20 | Now they can say, no, I'd like to
make it Detailed Request and get a
| | 04:23 | longer form. Excellent!
| | 04:25 | And if I'm working in OEC, I can
pull up the form for my use. Works fine.
| | 04:32 | I'm going to close this preview.
| | 04:35 | In the next movie, we're going to make
it even easier yet, for our users to be
| | 04:39 | able to switch from one view to the next.
| | Collapse this transcript |
| Using buttons and rules to switch views| 00:00 | We have our Express form open,
and I'd like to be able to add a button so
| | 00:05 | that the user could look at this form and go,
oh, I want to switch to the detailed form.
| | 00:09 | And that way I can actually hide all
the form views on the menu, or leave them
| | 00:14 | there. But the button
provides better functionality.
| | 00:17 | I'd like to put the button at the top
of the form, rather than part way down.
| | 00:21 | And so I'm going to begin by
creating space for the button.
| | 00:25 | I'm going to switch to my Table tools
and create a cell over here, actually
| | 00:30 | split this into three, so that I have
a place for a button without switching
| | 00:36 | this all the way over to the left.
| | 00:38 | In other words, if I start by putting a
cell here, notice that this is no longer
| | 00:43 | where I need it to be.
| | 00:44 | But if I put a cell here--
don't let that scare you too much--
| | 00:48 | I can then simply move this title
back, and it will be centered between
| | 00:59 | these two cell borders.
| | 01:02 | Now I want to put a button here.
| | 01:03 | So let's see how tight I can get that and
still keep in the middle. That looks good.
| | 01:08 | So I'm going to go back to the Home tab,
go to Controls, and choose a button.
| | 01:18 | And I have a button.
It sticks over the edge of the page some.
| | 01:20 | So I'm going to pull it back, try to help it
fit here, right-click, and set its properties.
| | 01:27 | I'd like this to say Show Detail.
| | 01:30 | Now I'll say OK, and that all fits. Lovely.
| | 01:34 | The button looks great, sort of,
but it doesn't do anything.
| | 01:37 | So two more things I want to deal with.
| | 01:39 | One is I want to assign an action to the button.
| | 01:42 | I'm going to choose Add Rule and say,
when this button is clicked, switch
| | 01:46 | views, and the view that I want to switch to is
the first one that's selected, Detailed Request.
| | 01:52 | Say OK. Let's make sure it works.
| | 01:54 | Go over to Preview. It looks good. Show Detail
switches me to the detailed form. That works.
| | 02:05 | Now I would also open up the detailed
form and create a button there that says
| | 02:10 | Show Express Form, right?
| | 02:12 | So that no matter which form the user
was in, they could quickly get to what to
| | 02:16 | them feels like another form and what
you and I know is simply another view.
| | 02:20 | Let's go ahead and name this rule.
| | 02:23 | If it's fired by a button, I'll usually
start it with 'btn', and this is going to
| | 02:26 | be ShowDetail. That works.
| | 02:30 | I can format this button if I wish.
| | 02:33 | I have borders and shading available.
| | 02:35 | When I do, it will take those rounded
corners and actually square them off a
| | 02:39 | little bit, but I can choose a
color that will go better with my theme.
| | 02:45 | So let's choose something like this perhaps.
| | 02:48 | That's a little garish.
| | 02:50 | We'll go back into Borders and
Shading and choose a little bit further down
| | 02:54 | the color spectrum.
| | 02:57 | That's a nice-looking button, and it works.
| | 03:02 | Now there's another way you
can create a button as well.
| | 03:04 | You have the ability to create
what's called a Picture button.
| | 03:07 | It helps if you have a
picture that works to begin with.
| | 03:10 | So I created a couple of pictures in
Microsoft Paint. Unless you're a better
| | 03:15 | artist than I am, I don't
recommend it, but you'll get the idea.
| | 03:18 | I'm going to say that I'd like to insert
a picture button, and by default it has
| | 03:24 | this small icon on it, and I'm going to
set its properties, which are primarily
| | 03:31 | choosing the picture to show.
| | 03:33 | So again, here's my fine work over
here in Microsoft Paint, and I create a
| | 03:38 | button, and that works.
| | 03:41 | And I can now assign an action to it and
| | 03:44 | add a rule for when this button is clicked.
| | 03:49 | If I chose a larger picture,
then I'll have to resize it.
| | 03:53 | So if I choose Picture button again,
and go to Picture Button Properties, and I
| | 03:58 | choose, for example, this set of
penguins, and say Insert, I'm going to end up
| | 04:05 | with a button that's
slightly larger than my form.
| | 04:09 | It's a big button because that's a big picture.
| | 04:13 | So I can right-click on the picture and
just try to size it to the cell, which was sad.
| | 04:19 | Let's look at formatting
this picture, if we could.
| | 04:21 | It says right now it is 768 pixels, and
its width is 100% of the space that it
| | 04:29 | has, so we could knock this down to
something like 35 pixels and see if we start
| | 04:35 | getting a button of a
reasonable size. There we go.
| | 04:37 | So we have some chubby little penguins
here, and if we assign a rule to that,
| | 04:42 | for example when this button is clicked,
let's switch to a print view for this
| | 04:51 | form, and now we'll take
a look at it in Preview.
| | 04:58 | And if I click on the penguins,
I will switch to the print view.
| | 05:03 | Now, that may seem overwhelmingly
clever and certainly the penguins are cute,
| | 05:08 | but there's nothing about penguins that tells me
that that's a print button or a print function.
| | 05:14 | So the next thing I have to do is invest
even more time in either providing user
| | 05:19 | training that say, when you see
penguins, think the letter P, think print, or
| | 05:24 | providing some text nearby, or
putting some text on top of it.
| | 05:27 | So again, unless you have a picture
that really fits the purpose and will tell
| | 05:33 | your user, here is what this does,
at least as easily as text will,
| | 05:38 | you should probably stick with
regular buttons and format them if you wish.
| | 05:42 | So this is how you use a button to take
action in Microsoft InfoPath Designer.
| | Collapse this transcript |
|
|
12. Publishing OptionsUnderstanding submit options| 00:00 | So, very shortly, we're going to be
distributing this form to users.
| | 00:04 | They'll be filling it out
and then doing what with it?
| | 00:08 | Well, the very last setting that we
need to make before we publish a form is to
| | 00:12 | specify how the completed form will be
sent on to the proper person or location.
| | 00:18 | We'll find the submit options here on the
Data tab in Microsoft InfoPath Designer.
| | 00:24 | Let's take a look at those
options in a little depth.
| | 00:27 | There are broadly two choices of
how you will set up your submits.
| | 00:32 | The first is that you want the user,
when they've completed the form, to click
| | 00:36 | Submit, and it goes to one place.
| | 00:39 | For example, we could submit
that form to a SharePoint library.
| | 00:44 | This is what I think of as the gold
standard, because once I've submitted a
| | 00:48 | whole bunch of forms to the SharePoint
library, I can do other work behind the
| | 00:53 | scenes to create views that allow users
to do aggregate things with all of these
| | 00:57 | forms that have been submitted.
| | 00:58 | You're going to learn
about this in the next chapter.
| | 01:01 | But if I don't have a SharePoint
library, or if all of my potential users don't
| | 01:06 | have access to it, or if I simply want to
send forms out and get them back, I can
| | 01:12 | submit by email. Or I can set up my
form to use a different submit method.
| | 01:17 | For example, I can submit to a
database using a web service.
| | 01:22 | In some prior versions of InfoPath,
you could actually submit directly to a
| | 01:27 | SQL Server database.
| | 01:28 | Now we need to actually put a web
service in there to make sure that you and I
| | 01:33 | can't do unintentional damage with forms.
And the other possibility is that we
| | 01:37 | might submit to SharePoint using a
data connection like a web service, rather
| | 01:42 | than submitting directly to the SharePoint library.
| | 01:45 | So you'll learn how to submit to a
SharePoint library in the next chapter, and
| | 01:50 | how to submit by email in this chapter.
| | 01:53 | The other submit methods we'll leave
for another more advanced course. But what
| | 01:57 | if we want to submit to more than one location?
| | 02:00 | For example, we might want to submit to
a SharePoint library and send someone an
| | 02:07 | email with the form in it at the same time.
| | 02:10 | Well, SharePoint is set up, by default, that
it will handle one submit option at a time.
| | 02:16 | So if you want to create two or more
submits, there is a way to do that.
| | 02:20 | You're simply going to use rules, like
we did for conditional formatting or for
| | 02:25 | switching between views, to
be able to submit the form.
| | 02:28 | You're write one action rule for each
submit action, so one action rule that's
| | 02:34 | submit to SharePoint,
one that's submit by email.
| | 02:37 | When you use rules, you can write as
many rules as you wish and submit to two or
| | 02:43 | more locations anytime you'd like.
| | 02:45 | Submit by email, submit to SharePoint
library, or set up your submit options
| | 02:52 | to allow you to use rules, and you'll
write those rules here by clicking the
| | 02:57 | Form Submit button.
| | 02:58 | It is only enabled after you've said
that you want to set your Submit Options to
| | 03:04 | allow users to submit the
form using rules, right here.
| | Collapse this transcript |
| Submitting using email| 00:00 | So I'm ready to take my form
and create a submit using email.
| | 00:05 | Let's click on the Data tab of the
ribbon, and here are our submit options, but
| | 00:11 | I'm simply going to choose to email.
| | 00:13 | The Data Connection Wizard opens, and this
looks like the header of an email form.
| | 00:18 | So I'll begin by typing the email
address that I would like this form return to.
| | 00:23 | So if I've created a form for people
to submit information to me, it will
| | 00:27 | probably be my email address.
| | 00:29 | However, I could talk to my IT or IS
department and have them set up a special
| | 00:35 | mailbox for this that I could then access.
| | 00:38 | By having a separate mailbox, I make it
possible for another user to easily help
| | 00:44 | me process these forms.
| | 00:46 | But I'm going to send this to myself.
| | 00:50 | I can then copy someone
and I can blind copy someone.
| | 00:55 | I can also hit the fx button here
and pull a field up out of the form.
| | 01:00 | For example, if I wanted to copy the user,
I have their email address right here.
| | 01:07 | So I could go back to my form, insert
a field or group, for requester, take
| | 01:14 | their email address, and say OK,
| | 01:18 | verify my formula, and now they'll get
copied on this email, so they'll easily
| | 01:24 | know that this was sent on to me as well.
| | 01:27 | In this subject, I can put anything I choose.
| | 01:30 | I can also pick up fields out of the form.
| | 01:34 | So, for example, this is a Post Express
Request from a certain person, so let me
| | 01:40 | insert a function for concat, and I'm
going to put "Express Post Request from,"
| | 01:48 | space, quote, get rid of the
second field, and then go in and put the
| | 01:55 | requestor's last name.
| | 01:58 | Verify my Formula. So the subject will
be "Express Post Request from" that user's
| | 02:04 | last name, right here.
| | 02:07 | Now in Outlook I can create rules
that would route anything that had this
| | 02:13 | particular subject begins with
Express Post Request from to a particular
| | 02:18 | folder in my inbox or forward it to someone
or any other rule I can establish in Outlook.
| | 02:24 | So taking the opportunity to start
this particular subject line with
| | 02:29 | something that I can recognize in Outlook
in a rule is a really smart way to handle this.
| | 02:34 | I can put other information in here if I wish.
| | 02:36 | If this is coming to me, I could
simply omit it. Or I could provide more
| | 02:41 | information if it was going to
another user. I'll click Next.
| | 02:45 | I can send only this active view of the form.
| | 02:48 | It will actually be
embedded in the email message,
| | 02:51 | so I'll see this form. Or I
could send the form as an attachment.
| | 02:55 | If I send it as an attachment, or if I
post this form on a SharePoint site, then
| | 03:02 | I should come up with a
better name for it than form.
| | 03:05 | So I could, for example, create using a
concat function again, a pretty decent
| | 03:12 | kind of file name for this, so
that I can automatically save it--
| | 03:16 | the sort of thing where we all go in and
put the users name in it, then delete this
| | 03:22 | field, put a space and a dash, and then
add their title from the Post section.
| | 03:31 | So, unless there is someone else with
the same post title and last name, this will
| | 03:36 | end up being unique.
| | 03:37 | I could also store the
date and anything else I want.
| | 03:40 | If I wish, I could begin this by saying
that it's a Post Request, remember
| | 03:44 | to put that in quotes, and I might as
well add the space and hyphen right here,
| | 03:50 | and then put a comma.
| | 03:51 | So Post Request, the
person's lastname, and posttitle.
| | 03:54 | Let's verify that Formula.
| | 03:56 | It says it has no errors. And say OK.
| | 03:58 | So when I or another user receives the
email with this attached form and want to
| | 04:04 | save it in a network share or in a My
Docs folder, it should have a unique name.
| | 04:09 | If this is coming back to me, I
already have the form template;
| | 04:13 | however, I can attach the current template,
so that any other user can open the form.
| | 04:18 | Remember again, if I'm simply sending
the data so they can see it, I might as
| | 04:22 | well only send the active view
of the form. I'll click Next.
| | 04:26 | This is my Email Submit.
| | 04:28 | That's a default name,
and this is my main submit connection.
| | 04:32 | This is the only way I'm
going to submit this form.
| | 04:35 | So when the user is done and they
click it, it will leave by email with the
| | 04:39 | settings that I just provided.
| | 04:41 | If I want to go back and see the
submit options for this form, I can
| | 04:45 | click Submit Options.
| | 04:46 | It says E-mail. I can manage this,
and it will let me modify it, which is
| | 04:51 | another way to see all of this same
information again and make any changes
| | 04:55 | that I need to make.
| | 04:57 | With the Submit Options set,
we're now ready to publish the form.
| | 05:01 | We won't be able to allow a user to
use it until we do, but as soon as we
| | 05:06 | publish it, a user will be able to open
the form, fill it out, click the Submit
| | 05:11 | button, and actually have the
contents of this form go somewhere.
| | Collapse this transcript |
| Distributing using email| 00:00 | With our Submit Options set, we're now
ready to publish and distribute this form.
| | 00:05 | Now even though we're using email as a
method, we could still publish this on
| | 00:10 | SharePoint. But we're going to focus
first on publishing this either on a
| | 00:14 | network share or simply
distributing directly to an email list.
| | 00:19 | Let's click File in our form,
and you'll notice that we've taken care of the
| | 00:23 | Submit Option, so this is grayed out,
but we never ran the Design Checker.
| | 00:28 | This isn't a bad thing for us
to do every time we publish.
| | 00:32 | So let's take a look.
| | 00:33 | It says, I believe you're going to use
InfoPath Filler to fill this out--yes, we are--
| | 00:38 | please check its design.
| | 00:40 | And really quickly, InfoPath ran
through all of the fields on the form, all of
| | 00:44 | the controls, and says, it's fine. All right!
| | 00:47 | If it had found errors, we would refresh it.
| | 00:50 | This is just another part of testing.
| | 00:51 | You know how to do this.
| | 00:53 | So the Design Checker now shows as
checked, and we're ready to publish our form.
| | 00:57 | The form isn't published yet, so we
can't publish to its current location.
| | 01:02 | We can publish to a network
location or to a list of email recipients.
| | 01:08 | If we publish to a network
location, we can still email from there.
| | 01:12 | So, I'd like to spend just a
moment discussing these two options.
| | 01:16 | If I have a form that I periodically
distribute only by myself, I'm the primary
| | 01:22 | provider of this form to people,
then I could use email as my method.
| | 01:27 | I could simply email it to the
ten people I'd like to use it now.
| | 01:30 | If I make some changes in it, it doesn't matter.
| | 01:33 | I'm the only source for this form.
| | 01:35 | However, if others in my workplace are
going to also use this form, I should
| | 01:41 | publish it to a network location or file share,
even if my intention is to share it by email.
| | 01:48 | So let's see what it looks like to
publish this to a list of email recipients.
| | 01:51 | I simply click E-mail, and it says,
"What do you want to name your form template?"
| | 01:57 | Well, Email on Network Share is the
exercise name, but we'd actually name this
| | 02:02 | Web Post Request because the user
will be able to switch between views.
| | 02:07 | They have a nice button that allows
them to do that. Let's click Next.
| | 02:11 | And then it says when a user receives
this in an Outlook folder--the user being
| | 02:16 | not the person who fills it out,
but eventually me using the data--the eventual
| | 02:21 | recipient of this form, might they want
to expose some columns that they could
| | 02:26 | actually include in a view in that folder?
| | 02:29 | And I actually would.
| | 02:31 | I'd like to be able to know who sent
this to me, for example. And I can rename
| | 02:37 | this to be Last Name, and I'd
like to add their first name.
| | 02:43 | I'll follow exactly the same process if I
publish in SharePoint, to put columns together.
| | 02:49 | And then I would like to know, also, the date
that they provided it, but it won't be today.
| | 02:56 | I'll actually want that to say at the
top Date or Submitted--shorter yet.
| | 03:04 | And then I'd like to add
the title of their posts.
| | 03:09 | That's all I want for right now.
| | 03:11 | Now I could have multiple
post titles in there, and this gets a
| | 03:14 | little interesting.
| | 03:15 | Why does this one say first?
| | 03:18 | Well, because Posttitle actually appears
in a repeating section, posts, so there
| | 03:24 | could be more than one.
| | 03:25 | I have choices if I choose Posttitle.
| | 03:28 | it can show me the first one;
| | 03:30 | It can show me the last one;
| | 03:32 | it can tell me there are four in here--
| | 03:34 | that's what count would do--or it could
take all of those titles and merge them
| | 03:38 | together so I could read them all.
| | 03:39 | I'm a little more excited
about that myself. All right!
| | 03:43 | So I'll click Publish to create an email
message that contains this form template. Okay?
| | 03:52 | I'll need to sign in, and here's my
email message that contains the template.
| | 04:01 | So I can easily send this to a
distribution list, to one or more recipients,
| | 04:06 | I can copy people on it, I can write a
brief introduction and I can send it.
| | 04:11 | When the recipient receives
it, this form is ready to go.
| | 04:15 | Notice that it will do
everything that they want it to do.
| | 04:17 | They can switch back and forth between views.
| | 04:20 | And when they're all done, they'll
actually have a Submit button here that will
| | 04:24 | return it to the designated email recipient.
| | 04:28 | Actually, that's me.
| | 04:29 | So I could save this form and use it
again later, or I can simply send it to a
| | 04:34 | bunch of people right now.
| | 04:36 | It's really easy to go in each time and
just say create a new email message with
| | 04:40 | this version of the form.
| | 04:42 | That's how we will publish a form
using email as the publishing method
| | 04:47 | in InfoPath 2010.
| | Collapse this transcript |
| Publishing to a network share| 00:00 | This is exactly the same file that we
used in the last movie when we used email
| | 00:06 | as our publishing/distribution method.
| | 00:10 | We can use the same file because when
we use email as our publishing method, we
| | 00:14 | just open up the InfoPath form
each time and ship it out again.
| | 00:18 | So let's publish this in a different way now.
| | 00:21 | Let's say that we want to publish the
form and instead of publishing it to
| | 00:25 | a list of email recipients, we'd like to
publish this to a network location or file share.
| | 00:31 | Now if I publish this in a file share,
other people have to be able to get to it.
| | 00:36 | So this isn't on your My Docs
folder on your computer normally.
| | 00:39 | This is somewhere in a folder, perhaps
in your organization you have a Transfer
| | 00:44 | folder or a Share folder, that other
people have the right not to place things in
| | 00:49 | but to read things from.
| | 00:50 | That will work just fine.
| | 00:52 | And note that your users are going
to have to be able to access InfoPath
| | 00:57 | Filler to complete the form that we
publish here in a network location, or the
| | 01:03 | one that we sent by email.
| | 01:04 | So let's choose Network Location, and we
will be asked to find a place to publish it.
| | 01:09 | So this folder already needs to be set
up somewhere. And I'm going to browse
| | 01:15 | out to my network location, and I
actually have some shared folders here that
| | 01:21 | users can have access to.
| | 01:23 | And I'm going to create a new folder in
my public share space and I'm going to
| | 01:29 | call this InfoPath Forms. That'll work.
| | 01:34 | Now I need to give this a file name,
and this will be the file name that the
| | 01:38 | template will have in this location.
| | 01:40 | Its current name is the name that
I'm using here as an exercise file.
| | 01:46 | You might think of this as my
production environment, but what this really is
| | 01:50 | this is a post request form.
| | 01:53 | So I'm going to say put it in that
new folder, call it Post Request Form.
| | 01:58 | Notice that it changed my template
name here as well. Let's click Next.
| | 02:03 | It says, "If all users can access the location
you entered in the previous step, click Next."
| | 02:08 | Same question I asked you.
| | 02:10 | Okay, however, if users access this
template by using a different path, enter it here.
| | 02:16 | Let me give you an example of that.
| | 02:18 | For example, you might have created a
mapped drive for one of your network shares.
| | 02:23 | It might be drive L. If what it says
here is drive L\Post Request Form, you need
| | 02:29 | to go back and redo that network path in
such a way that it would work for other
| | 02:34 | users who haven't mapped that drive.
| | 02:37 | So you can go follow drive L out to
that folder, right-click on the folder,
| | 02:42 | choose its Properties,
and that's what belongs here in this box.
| | 02:46 | If you have a question about what
should be here, just step away from your
| | 02:50 | computer for a minute right now, go
find a colleague real quickly, and have
| | 02:54 | them navigate to the folder, because it's
their path that needs to be here in this link.
| | 02:59 | Otherwise, you'll still be the only person
who can access the form. Let's click Next.
| | 03:04 | It says this is where it's going,
and I'm going to publish this form.
| | 03:07 | Now I can open the form template from
the published location, and I'm going to
| | 03:12 | say I want to open this form.
| | 03:14 | It says a server has to
be contacted. I know that;
| | 03:17 | it's stored on a server.
| | 03:19 | And here's my form.
| | 03:20 | So now this is the user experience of your form.
| | 03:23 | We're seeing it for the first time.
| | 03:25 | The user can go in and fill it out.
| | 03:27 | When they're all done, they click the
Submit button, and it will be saved.
| | 03:31 | Where will it be saved?
| | 03:32 | It's published on the file server, ah,
but it's not submitted there.
| | 03:37 | That's where it's distributed.
| | 03:39 | This form, like the last one, when it's
submitted, will be emailed back to me.
| | Collapse this transcript |
| Viewing the files InfoPath Designer creates| 00:00 | There's one more way that you can
publish that I just want to show you briefly
| | 00:04 | because the odds are good you won't
have a need for it, and yet if you do,
| | 00:07 | it's really pretty cool.
| | 00:09 | Every time you look at an InfoPath form, it
actually is a whole group of files put together.
| | 00:14 | There is the schema that
we see in the field list.
| | 00:18 | There is a style sheet that
creates each of the different views.
| | 00:22 | And all of these files together are
combined in the InfoPath Designer and
| | 00:27 | Form Filler so that you can
have one unified template.
| | 00:31 | But you can extract those files and
separate them, and you do that on the
| | 00:37 | Publish category by
choosing Export Source Files.
| | 00:40 | So simply click here. It will choose
the folder that the form is in already,
| | 00:45 | so if you created a folder for InfoPath
development, for example, that's not a bad place.
| | 00:51 | But I'm going to use a folder
called Source Files, and click OK.
| | 00:55 | And it says, "The form cannot be
signed when saving as source files.
| | 00:59 | It will need to be signed
again each time it's opened.
| | 01:03 | To sign the form permanently, sign
a certificate and publish the form."
| | 01:07 | I have not much idea what it's trying to
tell me here, but that's okay because I
| | 01:11 | don't want to sign the form.
| | 01:13 | I simply want to save it.
| | 01:15 | And that's what it looks like.
| | 01:16 | So now I have a form.
| | 01:19 | It's actually called Source Files.
And if I go back to that file location in my
| | 01:26 | exercise files, these are all of the
files that it takes to be able to create
| | 01:32 | one InfoPath template.
| | 01:34 | So here's my view called
ExpressRequest, and it's actually a style sheet.
| | 01:39 | Here's another view, another
style sheet. So each time we created a view, we
| | 01:44 | created a new style sheet.
| | 01:45 | There's something called sampledata.
| | 01:47 | We have very little sample data;
| | 01:49 | largely what we have in our
form is a few placeholders.
| | 01:53 | We also have a schema that we were
creating every time we added a new field to
| | 01:59 | our data source or changed the type of a field.
| | 02:02 | We have the XML document that is called
the template itself, but really what we
| | 02:08 | expect to see when we look at the
template is, more properly, the manifest.
| | 02:13 | So all of these different files come
together to create one single InfoPath template.
| | 02:18 | If someone were to ask you, does
that template you created have a schema?
| | 02:22 | You could say, yes it does,
and it's actually right here.
| | 02:26 | And you can open these files.
| | 02:27 | You can open the schema files and the XML files.
| | 02:31 | There are free tools to do that, things
like XML Notepad or Notepad++, that are
| | 02:37 | available, and here's what that file looks like.
| | 02:40 | And if you looked at this, you
would actually at this point be able to
| | 02:43 | understand pretty much what's going
on here, because we have, for example, a
| | 02:47 | requestor, a
newcontentarea, posts, and officeuse.
| | 02:52 | And in requestor, we have
elements called reqemail, reqfname.
| | 02:58 | It looks ugly, and I'm glad we never
had to type it, but this is the schema
| | 03:03 | that's part of our InfoPath template.
| | 03:06 | So again, anytime you'd like to be able
to extract those files from an InfoPath
| | 03:10 | template you've created, let's go
ahead and choose File > Publish > Export
| | 03:16 | Source Files, choose a location, and say OK.
| | Collapse this transcript |
|
|
13. Publishing a Template in SharePointPublishing InfoPath templates in SharePoint| 00:00 | When you're going to distribute a form
by publishing it as a web browser form in
| | 00:05 | SharePoint, or even as a Form Filler
form in SharePoint, you have two choices.
| | 00:11 | You could go in, if you wished, and set
your submit options first and say I'm
| | 00:16 | going to submit this to a SharePoint library.
| | 00:19 | You can also publish the form, create
the library during the act of publishing,
| | 00:26 | then come back and set your
submit options, and publish it again.
| | 00:31 | Even though there are more steps in
that second way of doing it--publish
| | 00:36 | and create a library, then come back, set
the submit options, and then publish again--
| | 00:42 | I actually prefer the second method.
| | 00:45 | From time to time, I've created a
library first and submitted a form to that
| | 00:50 | library only to have some issues
where fields aren't kept together like I
| | 00:56 | feel they should be.
| | 00:57 | So it feels really solid to me to
follow the tried-and-true method of creating
| | 01:03 | form libraries by publishing forms.
| | 01:07 | Let's begin by choosing File.
| | 01:09 | We're going to use the Design Checker.
| | 01:10 | We checked this form in a previous
movie, but there are three warnings, none
| | 01:15 | of which are critical.
| | 01:16 | We are happy with how our form looks.
| | 01:19 | And because there aren't red critical
warnings with an X through them, we know
| | 01:23 | that there are some things that won't be
supported, but that the form can be published.
| | 01:27 | So I'm going to close the
Design Checker. I'm fine there.
| | 01:30 | It will continue to bother me to check
the Design Checker until it comes up with
| | 01:34 | no errors, but I'm fine there,
and now I'm going to publish my form.
| | 01:38 | I'm going to publish my
form to a SharePoint server.
| | 01:42 | First, I need to be able to enter the
URL for my SharePoint server here, and one
| | 01:48 | other thing: that SharePoint server
must be running InfoPath Forms Services.
| | 01:53 | If no one else in your organization is
using InfoPath, it's possible your server
| | 01:58 | was set up without InfoPath Forms Services.
| | 02:01 | In that case, you need to
talk to your IT department.
| | 02:05 | If you have recently been in your
browser, you'll find that there's a list of
| | 02:09 | your history that's
obtained from Internet Explorer.
| | 02:13 | So in my case, I can simply begin
typing, and I've only gone to one site in
| | 02:19 | the past two days, or however long my history is,
that starts with the letter L. So that's good.
| | 02:25 | Right arrow.
| | 02:26 | The next portion is the word,
sites, and the next is central.
| | 02:30 | Also, there is a significant
dropdown list for once I start typing here.
| | 02:35 | So once I get to http:// and type
some other information like ld, I'll have
| | 02:41 | lots of other choices in my list.
| | 02:43 | I can also copy and paste out of my browser.
| | 02:46 | So, a lot of different ways to get here,
but I have to know the location of
| | 02:49 | my SharePoint site.
| | 02:50 | Notice that I'm pointing to a site, not
to a library, and I don't have any text
| | 02:55 | at the end that says .aspx.
| | 02:57 | If I do, normally the Publishing
Wizard will know what to discard here.
| | 03:02 | So now we're going to click Next,
and the check box Enable this form to be
| | 03:07 | filled out by a browser should be turned on.
| | 03:10 | If it is not, you probably just ran the
Design Checker in the mode where it was
| | 03:14 | looking at the InfoPath Form Filler.
| | 03:17 | As soon as you've chosen web browser as your
file type, this check box should be turned on.
| | 03:23 | You're going to publish this to a form library.
| | 03:26 | If you wish to publish site content
types or administrator-approved form
| | 03:31 | templates, please be in
conversation with your Information Services or
| | 03:35 | Information Technology department
because they control this at least, and
| | 03:39 | probably both of these
options. Let's click Next.
| | 03:43 | I would like to create a new
form library; that was the point.
| | 03:47 | So I'm going to click Next.
| | 03:50 | This is Web Post Requests.
| | 03:52 | Now when this library gets created,
it will have the URL, and every place I
| | 03:59 | provide a space in a URL, when the
web address itself is shown, spaces are
| | 04:05 | replaced with three characters,
| | 04:07 | the Percent sign, a 2, and a 0, because
that's the symbol for a space in a URL.
| | 04:14 | Because of that, I'm actually going
to do a little bit of a trick here.
| | 04:18 | I'm going to get rid of
those spaces for right now.
| | 04:21 | It's not going to look as good for a
description, but I will be able to change it.
| | 04:25 | And actually, if I can go even shorter,
it's probably good because I might have
| | 04:32 | relatively long file names that people
want to attach to forms in a library.
| | 04:37 | So the shorter I can be with what has
to appear in every URL, the better off my
| | 04:42 | users are, ultimately.
| | 04:44 | And this library is being created.
| | 04:47 | This is a place where "Users complete
and submit Web Post Requests and requests
| | 05:01 | for New Content Areas.
| | 05:04 | For more information, please contact," or an
extension, or just don't allow more information.
| | 05:16 | Figure that when we're giving people
permission to get here that we're giving
| | 05:20 | them information in that
process. Let's click Next.
| | 05:24 | Now we have the ability to choose some
fields out of our list here, and say when
| | 05:28 | we publish this form in InfoPath or in
an Outlook folder, we would like to make
| | 05:34 | sure that those columns appear.
| | 05:36 | And it's not that these are the
mandatory and then there are other optionals.
| | 05:40 | The only way that we can send columns
to a display from InfoPath to SharePoint
| | 05:46 | and Outlook is by doing it either now
during publishing or by doing it through
| | 05:52 | promotion and then publishing,
which I'll show you in a bit.
| | 05:55 | So I'm going to say I would really like
to know who it was who submitted this form.
| | 06:02 | I want to know their first name, and I'm
going to name it First, but it's this field.
| | 06:07 | I'd like to know their last name,
and rather than use the tag, these are
| | 06:12 | coming from my field list.
| | 06:14 | These aren't labels.
| | 06:15 | These are my tags. And I'd also
like to know two other things.
| | 06:21 | I'd like to know what date I submitted the form.
| | 06:26 | Now I can actually find that out
another way because as soon as this form hits
| | 06:30 | SharePoint, SharePoint is going to say,
hmm, when did this file get created, and
| | 06:35 | it will keep that as its created date and time.
| | 06:38 | So I don't necessarily
need to get that from here.
| | 06:41 | I could get that from somewhere else.
| | 06:43 | So rather than promote that field,
I'm going to actually choose a couple of
| | 06:47 | other fields that I would like to have.
| | 06:50 | First I'd like to know if this item is
news, and this is a true/false, and my
| | 06:55 | choice down here, there is
a function that says first.
| | 06:58 | You might wonder, why do I
see a function for this one?
| | 07:01 | Well, it's because this is in the
post area, which is a repeating area.
| | 07:06 | So it's saying, okay, there could be
five posts in here. Which one would you
| | 07:10 | like to know this about?
| | 07:12 | Well, first, I could say, show me just
the first one, but if there are five and
| | 07:16 | the first one is not news, what if the
other four are? Or I could say why don't
| | 07:21 | you count the times that is news is true?
| | 07:25 | And that would tell me either 0, 1, 2, 3, 4,
or 5, and that seems to make some sense to me.
| | 07:33 | So I'm going to grab that field because
then I know how many news items I have.
| | 07:39 | In the same way, I can go in and
count anything else I'd like to know.
| | 07:43 | I could count, for example, how
many posts there were in general.
| | 07:47 | So I could take a look at the posttitles
and say, tell me how many posts there are,
| | 07:52 | just count them.
| | 07:54 | And I could call this Num Posts.
| | 07:57 | Those are the things that I'd like to see,
| | 07:59 | the first name, the last name of the submitter.
| | 08:01 | I'll pick up the date from SharePoint.
| | 08:04 | I'll find out how many of the items
in it were news and how many total
| | 08:07 | items there are in here.
| | 08:09 | That's probably enough for now.
| | 08:10 | If I change my mind, this
is easy enough to change.
| | 08:13 | I'm going to click Next.
| | 08:15 | It says okay, I'm going to create a
form library at this location using
| | 08:19 | InfoPath Forms Services.
| | 08:21 | I'm going to now click Publish.
| | 08:25 | You may or may not see a
Windows Security dialog at this point.
| | 08:29 | It depends on how the security has
been set up in your organization.
| | 08:34 | Assuming that you are posting this
on a SharePoint site where you have
| | 08:37 | appropriate permission, you should
simply be able to enter your password, click
| | 08:42 | OK, and then wait for a moment.
| | 08:48 | After you've appropriately entered your
credentials, SharePoint will post your template.
| | 08:53 | We did the pre-checking in the Design
Checker, so there's no reason to believe
| | 08:58 | that this would not publish successfully.
| | 09:00 | But occasionally, you'll get some
information back that says it did not.
| | 09:05 | We can now say we'd like to open that
form library that we just created and
| | 09:09 | look at it, and we can additionally say
we would or would not like to open the
| | 09:13 | form in the browser.
| | 09:14 | I'm simply going to open the library and open
the form from the library by clicking Close.
| | 09:21 | Here's our brand-new PostReq library.
| | 09:25 | Not a lot going on in it yet, but when I click
Add document, notice what opens. There's my form.
| | 09:35 | I can't submit it yet.
| | 09:37 | If a user clicks Save, they'll get a message,
| | 09:39 | even if they choose still to save it,
this says you can only save this file here
| | 09:44 | and they'll have to provide a file
name, and it'll be a little weird.
| | 09:47 | That's not the user
experience we'd like to have.
| | 09:50 | I'll show you how to go ahead
and fix that in a little bit.
| | 09:53 | So, we've posted our very first form
here. That seems to work pretty well.
| | 09:58 | We figured out how to send columns here,
and that worked, and now we can go back
| | 10:03 | to Microsoft InfoPath, and the next
thing that we'll do is we will set up our
| | 10:08 | submit back to that SharePoint library,
so that when the user clicks Submit, the
| | 10:13 | form stays right where it is.
| | Collapse this transcript |
| Promoting columns to SharePoint| 00:01 | You don't have to wait until you
publish a form to determine what fields out of
| | 00:05 | our data source we'd like to
see in Outlook or in SharePoint.
| | 00:10 | You can pre-assign those by
making them promotable properties.
| | 00:15 | Let me show you how you'll do that.
| | 00:17 | This is particularly useful if you
intend to submit a form to more than one
| | 00:22 | location, because you can
set this all in one place.
| | 00:25 | This is a form that we just got done
publishing and when we published it, we
| | 00:29 | actually chose four columns that we
decided that we wanted to have in SharePoint
| | 00:34 | based on four of the field properties here.
| | 00:37 | I'm going to go to File, not to regular
Options but to Form Options and choose
| | 00:42 | Property Promotion, because the work
that we did promoting these fields into
| | 00:48 | SharePoint is actually captured
right here and stored in the form.
| | 00:53 | So if I wish, I could have started by
adding my promotable properties here.
| | 00:59 | I can also edit them here.
| | 01:01 | Now, until I publish, I'll have a
mismatch between this form and what the library
| | 01:06 | has in it. But if I change these
properties, publish my form again, then the
| | 01:12 | properties that are
promoted to SharePoint will change.
| | 01:16 | I want to offer a caveat here.
If you are promoting a large number of
| | 01:21 | properties out of a form--let's say, 40, 45--
| | 01:26 | you can expect that you will add a
property here or during publishing, and that
| | 01:32 | the first time you do it,
| | 01:33 | it may not actually make it.
| | 01:35 | It just seems to be an issue when
you're publishing a large number of
| | 01:39 | properties as columns.
| | 01:41 | But with the number that we have, I'm
not all that worried about it, and I'd
| | 01:44 | actually simply like to know if there's
been any request in this particular form
| | 01:51 | or any other that says, I'd like to
have a new content area. So, one way to do
| | 01:55 | that is to say, well show me if
there's a new content area requested.
| | 01:59 | I could modify that and simply say New Area.
| | 02:03 | If it's blank, I know there isn't one.
| | 02:05 | So you see how easy it is for me to be
able to very quickly go in and change my
| | 02:11 | properties that I wish to promote,
whether it's to SharePoint or to Outlook
| | 02:15 | folders for forms that are submitted by email.
| | 02:19 | And then, because I've published this
form once, I can now quick-publish this form,
| | 02:26 | publishing it again in the same location.
You may be prompted to enter your credentials.
| | 02:32 | You wait for a moment, and you notice
that the form was published successfully.
| | 02:36 | How would I know that that new
column had actually been captured?
| | 02:41 | Well, if I open my form in a browser,
I don't actually see it. The form looks
| | 02:46 | the same, whether the
properties are promoted or not.
| | 02:49 | However, if I look at my view of all
documents and refresh it, I should expect
| | 02:54 | to see the New Area column
right here in my library.
| | Collapse this transcript |
| Submitting a form to a SharePoint library| 00:00 | So we published our form and
created this library here in SharePoint.
| | 00:05 | Now if we create a new document, we
need to tell it that the submit event is to
| | 00:10 | put it right here back in this library.
| | 00:14 | I'm going to save myself a little bit of
time and I'm going to select my URL here.
| | 00:19 | I don't need the part that says, forms,
which means it's this, and all items,
| | 00:24 | which is actually the view
that I'm seeing right now.
| | 00:27 | I just need everything from here on back,
and I can right-click and copy that,
| | 00:32 | or Ctrl+C once it selected.
And let's slide back now to our InfoPath form.
| | 00:38 | I'm going to click submit options, and you'll
find out that I haven't set any up already.
| | 00:43 | I can choose to SharePoint library,
but I want to remind you that if I wanted
| | 00:49 | to submit this form both to a library
and email it to someone at the same time,
| | 00:55 | I would need to go to the Submit
Options dialog and choose to Perform custom
| | 01:01 | actions using Rules. But if I'm just
submitting to SharePoint, I can do that right here.
| | 01:07 | I'm prompted to enter the name of my
library, and I just copied it out of the
| | 01:12 | address bar in my browser, so Ctrl+V to paste.
| | 01:15 | Notice it wants to paste the
whole thing, but I don't need it.
| | 01:19 | And now it says, as users are
submitting forms, what will you name the form?
| | 01:25 | So this will appear in the
title. If I name it form,
| | 01:28 | then the first person who submits a form,
it will submit, and the second person,
| | 01:32 | because I'm not allowing overwrite,
will be told, I'm sorry. We're full up.
| | 01:36 | We already have somebody named form.
| | 01:38 | So let's go ahead and create what we
hope, really hope, will be a unique name,
| | 01:44 | because that's the purpose here.
| | 01:46 | I'm going to insert the concat
function, and I'm going to choose fields that I
| | 01:51 | believe will make very good sense
and create a totally unique experience.
| | 01:56 | So first, I'm going to insert the
requestor's last name. That's this field right here.
| | 02:03 | Next, I'm going to insert, simply
typing from the keyboard, a quote, a dash,
| | 02:09 | a quote, and a comma.
| | 02:11 | Now I'm going to insert another field,
and the field that I'm going to choose
| | 02:16 | this time is the title of the first post.
| | 02:23 | Now, I'm going to click after this
comma and do another dash, and a comma, so
| | 02:27 | quote, dash, quote, comma.
| | 02:30 | So now I have the person's last name
and the post title, and you might think
| | 02:35 | that would be enough, and you know many
days I would too, but if I'm in a really
| | 02:39 | large organization with a number of
employees who could have the same last name,
| | 02:44 | or a small place with tons of nepotism,
then I could have a lot of people who
| | 02:48 | have the same idea for a post
who have the same last name.
| | 02:53 | So I'm going to double-click here, and
we're going to pick up one more field,
| | 02:57 | which is I'm going to pick up the submit date.
| | 03:00 | Let's verify this formula.
| | 03:02 | Now, as I told you previously, I'm going
to know what this date already because
| | 03:08 | SharePoint is going to track it.
| | 03:09 | The reason I'm using it here is the
odds of two people with the same last name
| | 03:14 | posting exactly the same title on the
same date really lowers the odds that
| | 03:19 | I'll have a conflict.
| | 03:21 | So there's my form name. I'm all set.
| | 03:25 | Now if I wanted to, I could have
put some more text in front of this.
| | 03:28 | I could've said, form from or whatever,
but usually if I lead with something
| | 03:33 | like a title or a last name,
I'm in pretty good shape.
| | 03:36 | Let's click Next, and this is
automatically called a SharePoint Library Submit.
| | 03:44 | This is the default submit connection.
| | 03:47 | I can create other connections if I
wish, and line them up using rules in the
| | 03:52 | Submit Options dialog box.
| | 03:54 | Let's click Finish.
| | 03:57 | Now, our form sitting here on our
computer knows how it is to be submitted, but
| | 04:03 | the version that's sitting in my
library is still sitting there thinking, I wish
| | 04:08 | I could submit somewhere. I have to
update this template here in the library.
| | 04:13 | In other words, I have to publish my
form again, so that what I just did on my
| | 04:18 | computer will be here as well.
| | 04:21 | So let's go to File.
| | 04:23 | I've published it once. Do take a
moment and make sure this is the right place.
| | 04:27 | If you're not sure this is a live
hyperlink, you can click it and go out to your
| | 04:31 | library and make sure it's the right place.
| | 04:33 | Let's click Quick Publish.
| | 04:37 | If you were prompted to publish
before, you'll be prompted again.
| | 04:45 | And sometimes you'll be prompted a second time.
| | 04:51 | It says my form template has
been published successfully.
| | 04:54 | Now I'm going to open this form in
the browser, and what I'll see is my form
| | 04:59 | looks almost exactly like it did
before, with one new exception.
| | 05:05 | Here on my toolbar I can now submit
this form to my SharePoint Library.
| | 05:11 | Let's take just a moment and see how that works.
| | 05:14 | So I've got some data entered.
| | 05:15 | I think I have caught
all of the required fields.
| | 05:17 | If not, I'm sure I may know soon.
| | 05:24 | Notice that when I'm in a text field
I have editing tools available to me.
| | 05:27 | I can do some inserting of a table in
this rich text box, up here, no rich text
| | 05:34 | tools, because I'm in a plain
text box, but I'm all ready to go.
| | 05:38 | I'm going to submit this form.
| | 05:40 | Here I am back in my
library. That quick it happened.
| | 05:43 | There is the name that I created,
last name, title, today's date. Again, I
| | 05:51 | told you SharePoint would tell me when
it was changed, but it has right here
| | 05:54 | and who changed it last.
| | 05:57 | First name, last name, one item that's
news, one post, nothing in a new area.
| | 06:03 | I'm looking happy here.
| | 06:06 | So that's what it takes for us to take a
form that's already been published into
| | 06:10 | a form library and set up the submit
so that the form will return right here.
| | 06:15 | Even with only one form in this library,
you can probably begin to see the power
| | 06:21 | of publishing all of our forms to one place.
| | 06:24 | It allows for easy management by the
folks who have to respond to all of
| | 06:28 | these web post requests.
| | Collapse this transcript |
| Creating SharePoint library views for InfoPath forms| 00:00 | So here we are back in our PostReq
folder, and we've asked a couple of other
| | 00:04 | people in our office to jump in and
make up some test data, just to try it out.
| | 00:09 | Testing is as important for this site which
we are going to launch as it is for our form,
| | 00:15 | so it's helpful to have some friendly
users who are willing to come in and check
| | 00:20 | this out before we
launch this site for everyone.
| | 00:23 | So here is one view of the site, and
already when we are looking at just about
| | 00:29 | eight or nine new items, it's clear
that this view probably won't be enough.
| | 00:35 | When we have 50 people, all of this
pent-up demand, entering new items when we
| | 00:39 | launch this site within our organization,
we are going to wish that we had views,
| | 00:44 | and it's better if we can anticipate
and create them upfront, because then as
| | 00:49 | we're showing people how to use the
site, we are also showing them the views.
| | 00:53 | So I want to quickly show you
how to create a view in SharePoint.
| | 00:56 | If you want to know more about this,
I'd like to encourage you to look at the
| | 01:00 | SharePoint Essential Training Course in
the lynda.com Online Training Library,
| | 01:05 | but just enough to get you going so
you understand what we're doing here and
| | 01:09 | the relationship between this view
that we see and the InfoPath form that we
| | 01:13 | published to create this library.
| | 01:15 | You'll recall that we specified some
categories of information, some fields
| | 01:21 | from our data source, that we wanted to
promote as properties, or columns, here in SharePoint.
| | 01:28 | So the name which we created in our
form when we set up the submit event.
| | 01:33 | The first and last name of the user
which we promoted as a property, the number
| | 01:37 | of posts, the area, for example, of the form.
| | 01:41 | Let's take a look at how we can modify
the fields that we promote here as columns.
| | 01:48 | So let's go back to InfoPath. Here's
our Web Post Request, and this is as good a
| | 01:54 | time as any to point out that you
need to keep a copy of this template in a
| | 01:59 | place that's pretty pristine.
| | 02:01 | If anyone else goes in and modifies
this template, if you had someone else who
| | 02:05 | had permission to do so, and you need
to repost your template, the one on the
| | 02:10 | site will not have a backup.
| | 02:12 | So you always want to keep one copy of the
template as it is currently posted in SharePoint.
| | 02:19 | Keep it in a folder, for example, that
says 'template-do not modify'. Then you
| | 02:24 | can make a copy of it and modify
to post and repost it, for example.
| | 02:29 | So let's go to File > Form Options >
Property Promotion, and here are the fields
| | 02:35 | that we are sending over
to be columns in SharePoint.
| | 02:39 | I'd like to add a couple of other fields.
| | 02:41 | For example, we want to know right now
what department the requestor works in so
| | 02:48 | we can see where our new ideas are coming from.
| | 02:51 | I can type in 'Dept' or 'Department'.
| | 02:56 | This is a good thing to do right now
because if you forget, you'll have to come
| | 03:00 | back here again and do this all over.
| | 03:02 | And then the other thing is I know
how many posts have been provided, but I
| | 03:06 | don't have any idea what categories they fall
in, or what kind of information is in the posts.
| | 03:11 | So I'm going to add two
additional categories from the posts area.
| | 03:16 | First, I'd like to know the post category
of at least the first item that's posted.
| | 03:22 | So, let's get them all and
simply merge them together.
| | 03:30 | We have to choose either first, last,
count, or merge because postcategories is a
| | 03:35 | repeating group and therefore there can
be multiple occurrences of postcategory.
| | 03:40 | So postcategory, Categories, merge.
| | 03:52 | And finally, I'd like to actually see some
information about the post itself, posttitle.
| | 03:58 | Now, remember that posts is also
repeating, so my choices are first, last, count,
| | 04:03 | or merge, and I think just
the first one would be fine.
| | 04:07 | Now, let's merge those as well.
| | 04:10 | I have the first post title.
| | 04:11 | It's part of our field name.
| | 04:13 | So let's just call this Titles.
| | 04:17 | So now I have seven categories that I am
going to throw over the wall. Let's say OK.
| | 04:24 | I'm going to actually save this with a
new name, and I'll tell you it doesn't
| | 04:33 | matter what name we give it here.
| | 04:34 | This is only our name, because
in SharePoint this will simply be
| | 04:39 | called template.xsn.
| | 04:43 | Let's say File then, and we
can Quick Publish our form.
| | 04:47 | Quick Publish sort of rips
through and does an express publish.
| | 04:52 | It's possible that we will publish something,
and it won't get caught in the Quick Publish.
| | 04:56 | And if that's the case, you can simply
go to File > Publish and publish that
| | 05:01 | template again, starting from scratch--
| | 05:04 | the longer publish method, as
opposed to this express publish.
| | 05:10 | Dialog boxes, if you're prompted to
do so, based on your environment.
| | 05:22 | See how this is working.
| | 05:24 | We are published successfully.
| | 05:26 | Now, I don't care about my form.
| | 05:28 | I simply care about what's going on
over here in my browser, and I'm going to
| | 05:31 | come in here and refresh.
| | 05:34 | Here are my new Department,
Categories, and Titles.
| | 05:37 | Depending on the settings in your
organization for your SharePoint server, I
| | 05:42 | would expect that you would
actually see information in all of these
| | 05:47 | right now. There is a department that's a
required field and you would be able to see it.
| | 05:51 | Occasionally, you'll have the kind of
set up I have here where there is not
| | 05:56 | necessarily that level of trust
between the development environment, and this
| | 06:01 | is a test environment.
| | 06:03 | So because this is a test environment
and not a real environment, I'm simply
| | 06:07 | going to open and close one of those
forms, and you'll notice that when I do,
| | 06:12 | SharePoint again says, "Oh, there is a form.
| | 06:15 | It has properties. What was that again?"
And it goes and grabs those properties.
| | 06:19 | Likewise, if I go, for example,
here and simply close it,
| | 06:24 | I don't even have to do anything.
| | 06:26 | It just makes SharePoint look at this again.
| | 06:29 | Notice that I had two posts and that
the Categories are both in the Bicycling
| | 06:36 | area, or one didn't specify a category, actually.
| | 06:39 | And here are the two items:
Test - Bike Trail Signage, Test a
| | 06:43 | Fundraiser Concert.
| | 06:44 | So this is how that merged field
with the duplicate titles in it looks.
| | 06:49 | If you have 500 posts and you change
something in a view that's critical for you
| | 06:54 | and it looks like you're going to have
to go back through and open all of these,
| | 06:58 | there are actually some programmatic
methods that you can look forward to
| | 07:01 | quickly run through an update
all of these, but this looks good.
| | 07:05 | Now here's one view. In my
library, I can create new views.
| | 07:09 | So I can create custom views that sort
by department or group by department.
| | 07:14 | I can create views that show the progress.
Has this been completed or not, and by whom?
| | 07:21 | To create a new view, it's very easy to do.
| | 07:23 | You just click the Create view button.
| | 07:26 | You choose Standard view if you'd
like the kind of views we've been seeing,
| | 07:30 | or Datasheet view if you'd like something more
like Excel, or you start from an existing view.
| | 07:35 | Give it a new name.
| | 07:38 | Here, you're creating a public view
because if not it's just for you and no one
| | 07:43 | else will ever see it, and then you
simply adjust the columns and categories,
| | 07:48 | the sorting, the filtering, and so on.
| | 07:51 | Again, if you're going to spend a lot
of time in SharePoint, as an InfoPath
| | 07:55 | developer, I want to encourage you
to take a look at the SharePoint
| | 07:59 | Essential Training Course.
| | 08:00 | One more thing I'd like to help you
fix before we are done looking at this
| | 08:04 | particular view and this library.
| | 08:07 | When we created this library, I said,
let's not put a space in the name, then
| | 08:12 | let's have a nice short stubby name so
that up here in the URL, it looks good
| | 08:17 | and doesn't take up a lot of space,
and unlike Shared Documents, for example,
| | 08:20 | doesn't take up three characters with this
%20, and I told you I'd show you how to fix this.
| | 08:26 | To change this name here, we are going
to go in the Library tools to Library >
| | 08:33 | Library Settings > Title, description,
and navigation and say that this is the
| | 08:39 | Web Post Requests library.
| | 08:43 | Notice I don't have a way in this
library to change its URL, but I do have a way
| | 08:49 | to change its name on the
Quick Launch bar right here.
| | 08:54 | Using InfoPath, I can create a great form.
| | 08:57 | Posting it to SharePoint makes it
readily available to lots of people as my
| | 09:01 | test users will attest.
| | 09:03 | By creating views, I make it easy
for people to see that their form was
| | 09:07 | actually posted, and to be able to
analyze where our forms are being submitted
| | 09:12 | from and by whom. And finally, by
adding some of the back-office fields, the
| | 09:17 | fields that the OEC staff will fill out,
I can make it possible for someone to
| | 09:21 | submit a form and come right back to
this site to see whether it's in process
| | 09:26 | and whether it's been completed.
| | 09:28 | A nice complete solution from
submit to feedback, back to the user.
| | Collapse this transcript |
| Modifying InfoPath forms published in SharePoint| 00:00 | This is my InfoPath template that I've
used to post in a SharePoint site and
| | 00:05 | create a solution in my workplace to be
able to submit new web post requests and
| | 00:11 | get feedback about how that process is
going once they've been submitted, so
| | 00:16 | this is a very important template for me.
| | 00:18 | Sometimes I'm the only person doing
development, and in that case all I have to
| | 00:22 | do is guard this template, and when I
get ready to make a change to the site, I
| | 00:28 | can simply modify this form and then repost it.
| | 00:31 | For example, if after we've been using
this form for a while there is a request
| | 00:37 | to add another content area, I can do so.
| | 00:40 | If there is a request to delete a
content area--for example, somebody says we
| | 00:45 | are not going to use that optional section
anymore, take it out of the form--I can do that.
| | 00:50 | When I delete these fields, however,
I'll be reminded that we've actually got
| | 00:59 | data sitting in forms. All of the forms that
sit out on the site already have this data.
| | 01:06 | So I can lose this data pretty easily
out of all of those forms, because the new
| | 01:10 | form will simply throw it away.
| | 01:12 | It won't show it any longer.
| | 01:14 | So sometimes when somebody says,
"I'm not sure we need this," I say, "Ah,
| | 01:18 | that might be fine," but an
alternative to me getting rid of this area is
| | 01:23 | simply to come into the form itself
and say I'm not going to provide a
| | 01:28 | section for that anymore.
| | 01:30 | So we're not going to have a place to
be able to put new content now, and that
| | 01:34 | will work just fine.
| | 01:36 | So by simply deleting the optional
section, I keep all of the data that's already
| | 01:41 | been entered in those forms.
| | 01:42 | If that's the case, I'm going to
actually save a copy of this first that says
| | 01:46 | Post Request Template with new content
area, because if somebody changes their
| | 01:52 | mind--often you'll find people who say,
well, "You know, I don't think I want that,"
| | 01:56 | and then three months later they'll say,
"We really need that back," and it's nice
| | 02:00 | to be able to say, "Well, we
had it once. We can have it again."
| | 02:04 | So, significant request to change the
template warrant you saving a copy of it as
| | 02:09 | it was, but this becomes and
remains my master template.
| | 02:14 | This should always look exactly like the
template that's sitting on my web site.
| | 02:19 | But what if it doesn't?
| | 02:20 | I have clients where I'm one member of
a development team. I might create the
| | 02:25 | initial InfoPath form, and after that,
other people have the ability to update it.
| | 02:30 | I don't have the master
form anymore on my computer.
| | 02:34 | Now, we'll set up a process that says
well, the master template should be kept in
| | 02:38 | such and such a location, but what if
that doesn't happen? Or what if you believe,
| | 02:43 | for whatever reason, that the template
that's here that you might want to modify
| | 02:48 | already doesn't match the
template that's sitting out on the site?
| | 02:52 | Well, in that case, you can always modify
the template that is stored here right now.
| | 03:00 | Go back to your Library, go to your
Library Settings, choose under the General
| | 03:07 | Settings area, Advanced Settings,
and you'll notice it says Document Template.
| | 03:13 | I told you that no matter what you
named it, this would be its name here in
| | 03:16 | SharePoint, but this will let you
directly edit the template that's stored
| | 03:21 | right here right now.
| | 03:23 | So if I click Edit Template and I may
be prompted. You're used to this by now on
| | 03:28 | your system, but wait for me.
| | 03:33 | So here's the template in Design mode. Notice
it's not called template.xsn here. This is a copy.
| | 03:41 | I've got one sitting out on the site,
and it's still chugging along, letting
| | 03:45 | users submit new forms.
| | 03:46 | This is a copy of it,
but it is an exact copy of it.
| | 03:50 | So now I can make my
modifications here and do two things:
| | 03:54 | one, save this as my current form
template and two, republish this template
| | 04:01 | then back to the site.
| | 04:03 | So whether you're working in sort of
solo development environment and know that
| | 04:08 | you have the best template version
always that you'll modify, or you're working
| | 04:14 | in a shared environment and need to
go back and grab the template off the
| | 04:19 | SharePoint site, regardless, anytime
you want to modify this template, you can.
| | 04:24 | I encourage you to hide controls or
remove controls rather than ever delete
| | 04:29 | content until you've had enough time
to truly evaluate what the effect of
| | 04:34 | deleting those fields would be.
| | Collapse this transcript |
|
|
14. Advanced Data TechniquesUnderstanding data connections| 00:01 | In the fabulous forms that we've
created up to this point, anytime we've wanted
| | 00:05 | to provide a user with choices, we've
done that by creating a dropdown or a
| | 00:10 | combo box that actually had a
manual list entered into it.
| | 00:15 | So, for example, if we wanted to allow
the user to choose a department name or
| | 00:23 | choose a category, we typed a list.
| | 00:25 | Let's go take a look at that control
for just a moment and make sure that we
| | 00:30 | remember how we created those.
| | 00:36 | So again, here in the properties of this
combo box, we typed each of these entries in.
| | 00:43 | In the Department list at the top of the
form, again this is a place where we did
| | 00:47 | more typing. And for short lists
that don't change much, that's fine.
| | 00:52 | But what if we have a longer list, or a
list that's outside of our control that
| | 00:56 | someone else maintains?
| | 00:58 | In that case, it's very tempting for
us to try to get information from an
| | 01:03 | external data source.
| | 01:04 | Let's take a look at how we would do that.
| | 01:10 | In this Data Connections form, I'm ready
to create data connections to a lot of
| | 01:14 | different places that you'll see in the
next few movies, but when I want to set
| | 01:18 | up an external Data Connection, I use
the Data tab. I can get data from a number
| | 01:24 | of different places, from a web service--
two different kinds SOAP and REST,
| | 01:30 | possibly SOAP dish, maybe that comes later.
| | 01:33 | Data that's stored in a SharePoint List,
a very typical way to get information,
| | 01:36 | particularly for a form that I am
publishing back to that same SharePoint site.
| | 01:41 | The odds are that there might
be some good data there for me.
| | 01:45 | From a data connection established on a
SharePoint server that would normally
| | 01:49 | point to a list but could point
somewhere else in SharePoint. And then the
| | 01:53 | catch-all, from other sources, from a
database or from an XML file.
| | 01:58 | If I'm using a database then I need to
be able to instruct Microsoft InfoPath on
| | 02:04 | how I'm going to connect to that
database, and I have to make sure that it's in a
| | 02:08 | place that the form can access, or from
an XML file, and an XML file is a file
| | 02:17 | that I can actually keep along with this form.
| | 02:21 | Before we start creating external data
sources, which are really cool, because if
| | 02:25 | I have a list in SharePoint somebody
else is maintaining that I don't have to
| | 02:29 | retype, that's great, and if every time
the list changes my form can connect to
| | 02:34 | it and get a refreshed dropdown
list, that's even better for my users.
| | 02:39 | So what's the possible downside?
| | 02:41 | Well, one downside is that if I'm
connecting to, for example, a SharePoint list
| | 02:46 | to grab data for my form, I have to
ensure that every person who uses my form has
| | 02:52 | access to that same list.
| | 02:54 | It has to be stored on a site,
preferably where I've also posted my form, which
| | 02:59 | means that I've lost the
ability to email that form to others.
| | 03:02 | The downside of using web services
is that I need to involve other people
| | 03:07 | to write them for me.
| | 03:08 | The odds are pretty good that I'm not
going to write my own SOAP web services
| | 03:12 | or REST web services.
| | 03:13 | Once they exist, I can use them over
and over again, but someone needs to
| | 03:17 | create them and give me the ability to use them,
and I need to understand how to use their methods.
| | 03:23 | From other sources, if I'm connecting
to a SQL Server database, I need to have
| | 03:28 | permission to connect to a SQL Server database.
| | 03:31 | If I don't have all of the information
I need to go find it and then to connect
| | 03:36 | to it, I won't be successful here if I
don't know what table my data is in.
| | 03:41 | And so once again, I'll be needing to work
with my IT department in order to do this.
| | 03:46 | The final reason is that in a complex
organization where we have different user
| | 03:52 | domains, different parts that follow
the @ in your email address, if I try to
| | 03:59 | create a form that's based on a
SharePoint list in my domain and then want to
| | 04:04 | share it with another professional or
another support person in another domain,
| | 04:08 | the odds are very good that that form
will not work, and that they'll have a lot
| | 04:12 | of difficulty with it.
| | 04:13 | So the assumption behind publishing
forms with external data connections is this:
| | 04:19 | you're going to publish a form that
only contains data connections that are
| | 04:24 | within your own domain, on your server
or server farm, and only share it with people
| | 04:30 | who are similarly positioned.
| | 04:33 | You're going to understand when you do
this that that form can't be used offline
| | 04:38 | and probably can't be distributed by
email unless the source you use is an XML
| | 04:44 | file that can be bundled right
along with the form template.
| | 04:48 | So given those caveats and concerns,
the next thing we're going to do is we're
| | 04:53 | going to find out how to create data
connections to SharePoint lists and to XML
| | 04:58 | files that we can include with our template.
| | Collapse this transcript |
| Creating a data connection to a SharePoint list| 00:01 | In this simple form, we're going to
include two external data sources:
| | 00:05 | one from SharePoint and one from an XML file.
| | 00:09 | We're going to create a dropdown here
to contain some information that we're
| | 00:14 | going to go grab from SharePoint.
| | 00:16 | So I'm going to start back here by
grabbing a control, and I'd like a dropdown list.
| | 00:22 | The dropdown list is going to get
information from a SharePoint site list.
| | 00:27 | So let's go to our SharePoint site,
and there is a list, as opposed to a library.
| | 00:32 | Libraries hold documents; lists hold
things that look like Excel lists broadly.
| | 00:41 | And as a matter of fact, you can
choose to see the item in a datasheet view,
| | 00:44 | which will look exactly like Excel.
| | 00:46 | So here's my list, and I want to bring
back these partner names into my form.
| | 00:52 | Now I see a partner Last Name and a
partner First Name, but I'd like to
| | 00:56 | bring their whole names.
| | 00:57 | So the first thing that I should do is a
little bit of research here to find out
| | 01:01 | if the data that I want exactly is here.
| | 01:05 | I'm going to go to List and take a look in the
view that's only here is the All contacts view.
| | 01:12 | This is it. So let's go modify this view, and I'm
scrolling down and looking for a field
| | 01:18 | called Full Name,
and there it is. So, it exists;
| | 01:22 | it's just not shown in that view
because the First and the Last Name are there.
| | 01:26 | So I don't have to display this field
in the view to be able to use it in a
| | 01:30 | dropdown list, but it doesn't hurt for me to
see it there as I'm working back and forth.
| | 01:35 | This shows every field that will be
displayed and every field, or what are called
| | 01:41 | columns here in
SharePoint, that exists in the data.
| | 01:44 | It's a lot of fields.
| | 01:45 | I'd like to place Full Name
second in the list, right behind the
| | 01:50 | Attachments column.
| | 01:52 | And when I do that, it will push Last
Name and First Name and such down the list.
| | 01:56 | There's two OK or Cancel buttons:
| | 01:58 | one at the top, one at the bottom.
| | 02:00 | I'm going to click OK, and notice
that here's the Full Name field that I
| | 02:04 | actually want to grab to be able
to use it back in my InfoPath form.
| | 02:09 | So let's go back now to InfoPath.
| | 02:11 | Let's bind this dropdown list control
to partners, just so we're clear that
| | 02:17 | that's what it's for, and delete our
extra field that was created. And now
| | 02:23 | let's add an external data source.
| | 02:25 | We can do that explicitly here by
creating it first, or we can create it right
| | 02:30 | here in the control.
| | 02:31 | Let's right-click and go to the Drop-
Down List Box Properties, and say we want
| | 02:36 | to get choices from an external data source.
| | 02:39 | And the Drop-Down List Box
Properties says you don't have any.
| | 02:43 | We'll need to add one. And when
I click Add, I'll be taken to the
| | 02:47 | Data Connection Wizard.
| | 02:48 | Now just so you know, if I'd said I
want to create a connection to a SharePoint
| | 02:53 | list, I would start in
the Data Connection Wizard,
| | 02:56 | so it's really the same thing, except
I get a little bit of a head start by
| | 02:59 | starting with the control.
| | 03:00 | It's slightly different because it
knows that I'm going to either be
| | 03:05 | receiving or submitting data.
| | 03:07 | And it's got Receive already marked,
so I won't be prompted to provide
| | 03:11 | this information later.
| | 03:13 | So I'm going to receive data for a
list because we wouldn't have a user
| | 03:17 | type into this list;
we'll have them choose from it.
| | 03:19 | I'm going to click Next, and it says,
where do you want to get this? And we are
| | 03:22 | working with a SharePoint
library or list right now.
| | 03:26 | It wants to know where it is.
| | 03:27 | Now, I can begin typing this, or I can
simply go back, and it's right here, and I
| | 03:32 | do not need this part because
this is the name of the view.
| | 03:36 | This is our aspx page.
AllItems.aspx is always a view.
| | 03:42 | Anything.aspx is going to be a view in a list.
| | 03:45 | So I want all of this, and I can right-
click or copy or Ctrl+C to copy, swing
| | 03:50 | back into InfoPath, and let's paste this
in here with a Ctrl+V. It would love to
| | 03:56 | give us more information.
| | 03:57 | Take a look. Here are all
these different views here.
| | 04:00 | We don't need them. We're set.
| | 04:02 | Click Next.
| | 04:04 | Now if I had only put in this much, it
would actually still find, or allow me to
| | 04:10 | work my way down to the library.
And I want to choose Partners.
| | 04:15 | It's a contacts list of suppliers,
vendors, consultants, and other partners.
| | 04:19 | I'm going to click Next. And now
the question is, what fields do I want?
| | 04:25 | I have to choose the ID field.
| | 04:27 | I don't have a way not to choose
it, but I don't have to show it.
| | 04:30 | And the field that I want is
the Full_Name field right here.
| | 04:34 | I'd like to also sort this list by the
person's last name so that they're in
| | 04:39 | alphabetical order, and click Next.
| | 04:42 | This choice is about how data or
whether data should be stored in the form.
| | 04:47 | There are some forms that
users will often fill out offline.
| | 04:51 | For example, if you have a salesperson
who's making calls in a lot of different
| | 04:55 | businesses during the day, unless they
have a National Broadband Card, the odds
| | 05:00 | are good that there are times that
they're offline, but they may still want to
| | 05:04 | be able to fill out a form
while they're meeting with a client.
| | 05:07 | If you have users who will use this
form in that way--typically, people using
| | 05:13 | the InfoPath Form Filler, right, because
that's your offline Form tool--then you
| | 05:18 | might say, go ahead and store a
copy of this data in the form template.
| | 05:23 | There are some issues with this.
| | 05:25 | If someone takes this computer, then
they'll have access to that information.
| | 05:28 | So if this was the list of all your
customers, this is really a bad idea.
| | 05:33 | And if all of your users will be
online, it's really not necessary.
| | 05:37 | But if you will have large number of
Form Filler users who will want to open
| | 05:41 | this form and use it offline, and it's
not incredibly sensitive data and your
| | 05:45 | computers are well secured--
| | 05:46 | a lot of 'ifs', but you hear the chain of
thought here--then you'll want to store
| | 05:50 | a copy of data in the form template.
| | 05:53 | So here's my name for the data connection.
| | 05:56 | It's actually named after the
dropdown, which is named after the field.
| | 06:00 | That's not a bad data connection,
but often I will put an sp in front of it, so
| | 06:05 | I know that it comes from SharePoint.
| | 06:07 | This check box says that as soon as
the form opens, InfoPath will go to
| | 06:12 | SharePoint, knock on the door, and say, give me
the information that I need for this dropdown.
| | 06:17 | Because this is a dropdown that's
central to this form, that makes sense.
| | 06:22 | If, however, this was a dropdown that
retrieved a lot of information in an
| | 06:26 | optional section of the form, I
might actually not check this box.
| | 06:31 | In that case, InfoPath will wait
until the point at which the user actually
| | 06:37 | clicks that dropdown to populate it.
| | 06:40 | So you need to choose if it's
going to be used most of the time.
| | 06:44 | If it's not in an optional section
of the form, then it makes some sense,
| | 06:48 | particularly if it's close to the top,
to automatically retrieve the data on
| | 06:52 | the form's open event.
| | 06:54 | Let's click Finish.
| | 06:56 | Now we've connected, and we've created
a data connection that we could use at
| | 07:00 | other times in other places in this form.
| | 07:03 | We have two things left to do, however.
| | 07:05 | Right now, it's simply
going to show us a list of IDs.
| | 07:09 | We're going to need to change this,
but let me show you how it would work
| | 07:12 | right now if we said OK.
| | 07:15 | Home, and to Preview, and see how that data
connection looks. And right now, it says 2, 3, 1.
| | 07:22 | That's that ID field that
was supplied automatically.
| | 07:27 | We want the Full Name field.
| | 07:29 | So let's close the preview.
| | 07:30 | Let's go back into the control properties,
and rather than ID, 1, 2, 3, let's choose
| | 07:37 | the Full Name field.
| | 07:39 | This is the value when the user chooses that
will be stored according to the data source.
| | 07:46 | This is what's displayed in the dropdown list.
| | 07:49 | So it's actually possible to have the user
choose the full name and store the ID if you wish.
| | 07:54 | These are two separate
properties of this control.
| | 07:57 | I'm going to say OK, go back to
Preview, and now let's take a look at our
| | 08:03 | external data source from a
SharePoint list with full names.
| | 08:07 | Let's close the preview.
| | 08:11 | So that was easy enough to do.
| | 08:13 | If I decide at some point I no longer
want this data source, I don't want this
| | 08:17 | data connection, perhaps there's only
ever three names in it, and it's easier
| | 08:22 | simply to type them in because that
avoids all the issues about how I can
| | 08:26 | distribute this form across domains, or
whether or not it has the information it
| | 08:31 | needs even in an offline mode.
| | 08:33 | So if I decide that I no longer need
this data connection, I can actually remove
| | 08:37 | it here, and I should remove it, even
though I don't need to do that first,
| | 08:44 | because choosing to enter my choices
manually is a simple option here in the
| | 08:49 | list box property, and then I simply
add those three people's names here.
| | 08:54 | So whether I want to use a data
connection or choose to use a manual list is a
| | 08:59 | matter of how I'm doing
the development for my form.
| | 09:02 | But if I want to get a great external
data source from SharePoint, it's really
| | 09:06 | easy to do that here in InfoPath 2010.
| | Collapse this transcript |
| Creating a list or combo box based on an XML file| 00:01 | I've found it useful in the past to create
a dropdown list that doesn't connect to
| | 00:06 | an external data source that's as far
away as a SharePoint list, or a server, but
| | 00:11 | connects to an external data source
stored with the template, an XML file.
| | 00:16 | The reason I might do this is that I
get a new XML file with some data in it on
| | 00:21 | a routine basis, for example, once a
quarter, once a month, and I can attach
| | 00:27 | that to my template and send the
template out and have the good data source for
| | 00:31 | that month. Whether that data
source is a list of customers, a list of
| | 00:35 | suppliers, locations, whatever the list
is, it's a list that doesn't update so
| | 00:41 | dynamically that I feel people have
a need to connect to it directly.
| | 00:46 | And because I can include an XML file right
here in the template, it creates a nice
| | 00:52 | offline form for use out in the field
by people who aren't always connected
| | 00:57 | when they are using forms.
| | 00:58 | Obviously, in this case I am talking
about a form that will be used with the
| | 01:02 | InfoPath Form Filler because if it was
a web form, it would make more sense for
| | 01:07 | me to store that and retrieve the
information from a SharePoint list, another
| | 01:11 | process that I can use.
| | 01:14 | So I am going to add a new connection,
and I can either start with my Drop-Down
| | 01:20 | List or My Multiple Selection List
or a Combo Box, or I could start by
| | 01:26 | creating the connection.
| | 01:28 | I am going to start with a combo box.
| | 01:31 | As always, InfoPath is very
happy to create a field for me.
| | 01:35 | So I am going to be very happy to
delete it and to rebind this to locations.
| | 01:44 | Remember also, if I simply undo those
steps and get rid of this control, that I
| | 01:50 | always have the possibility of just
right-dragging locations here, releasing it,
| | 01:54 | and choosing Combo Box, and then
I simply have some deleting to do.
| | 01:59 | So here in my locations combo box, I
want to right-click and set the Combo Box
| | 02:05 | properties to Get choices
from an external data source.
| | 02:09 | This is the same process I followed
initially to connect to a SharePoint list.
| | 02:13 | I am going to go ahead and add
a connection to receive data.
| | 02:20 | You never need to worry about whether
you're receiving or submitting here.
| | 02:23 | If it's data coming into the
form, you're always receiving it.
| | 02:27 | And I'd like to use an XML document.
| | 02:29 | I will now be asked to find
out where that XML document is.
| | 02:34 | If I click Resource Files, I can actually
add this into the form template right now.
| | 02:40 | You'll find this in your exercise file folder.
| | 02:42 | It's called locations.
| | 02:44 | So I am going to say OK.
| | 02:46 | If I simply clicked Browse, it wouldn't
be part of my resource files, but I want
| | 02:50 | it right here with the template. And it
asks for a name for this data location,
| | 02:56 | and just as I put 'sp' before SharePoint
List, I am going to name the connection
| | 03:00 | starting with 'xml' for an XML list.
| | 03:04 | Now, this data is going to be right
here. The question is do I want to
| | 03:08 | automatically retrieve it?
| | 03:09 | No network connection is needed.
| | 03:11 | When I open the form, it will simply
find the file that's with it and fill that
| | 03:16 | dropdown for me, and that sounds like a
great idea, so I will leave this check
| | 03:19 | box checked and say Finish.
| | 03:22 | Now, I'd like to show
you this xmlLocations file.
| | 03:26 | If you spend a lot of time working
with XML, I want to recommend that you get
| | 03:31 | one of the free or low-cost
XML editing tools, at least.
| | 03:34 | For example, you could look at
Microsoft's XML Notepad, or you could look at an
| | 03:41 | application called Notepad++.
| | 03:44 | Both of these are free and allow you
to edit and view XML. If you simply want
| | 03:49 | to look at XML though, it can present itself
to you in a really basic form in a browser.
| | 03:54 | So I am going to go over to Internet
Explorer and take a look at our XML file.
| | 03:59 | The XML file has a structure and a
schema just like our field list does that we
| | 04:05 | created when we created the form.
| | 04:07 | This one is actually a root, and inside
the root there is a location, and it's a
| | 04:12 | list of locations over and over again.
| | 04:15 | The location has a street, a city, and a state.
| | 04:19 | So these are all retail locations from
New Orleans back to Ventura, California.
| | 04:25 | That's what it looks like.
| | 04:27 | Let's go ahead then and choose the
repeating group or field where the entries
| | 04:32 | are stored, and this should look
markedly familiar from our glance at the XML.
| | 04:37 | I'd like to look in the Location group,
and in that group it's chosen the first
| | 04:46 | field. I actually want to choose the City field.
| | 04:51 | So I have the ability to present
simply that city list out of locations.
| | 04:56 | Let's click OK and then click Preview, and
let's see how this second dropdown looks.
| | 05:02 | There is our list.
| | 05:03 | Now, this is the list in the order
in which it appears in the XML file.
| | 05:08 | It's not in an alphabetical order by city.
| | 05:11 | We might want to sort that XML file.
| | 05:14 | We could open it up in Excel, sort it,
and resave it if we wish. We could also do
| | 05:20 | that in some of the XML editors.
But here's our list of locations from our XML
| | 05:25 | file that's stored here in our template.
| | 05:30 | Imagine instead of a short list of
locations, we have a list of 1,000 customers
| | 05:34 | that is updated on a
monthly basis, a quarterly basis.
| | 05:38 | The power of that tied with this
template is that it automatically loads when
| | 05:43 | the template loads, whether I
have wireless access or not.
| | 05:47 | If I am a salesperson out in the field
and want to complete orders, I can go
| | 05:51 | make sure that my customer is on the
list and have all of that customer's
| | 05:54 | information accessible one click
away here in Microsoft InfoPath.
| | 05:59 | If I go back to the Data tab and look
at Data Connections, I will find that
| | 06:03 | I have xmlLocations.
| | 06:05 | I can modify this location if I wish in
the same way that I might have modified
| | 06:11 | a SharePoint list data connection.
| | 06:14 | Additionally, if I click Resource Files,
I will see a list of all of the files
| | 06:19 | that are stored in the template.
Right now there is only one, Locations.xml.
| | 06:24 | If in the future I want to update
this, all I need to do is to remove and
| | 06:30 | then re-add this list.
| | 06:32 | When I remove it, it drops
the version out of the template.
| | 06:35 | When I add it again, I will get
the new version that's been updated.
| | 06:39 | A nice simple way to provide a
package of information that accompanies my
| | 06:43 | template, an external data source
created from an XML file here in
| | 06:48 | Microsoft InfoPath.
| | Collapse this transcript |
|
|
15. Advanced Templates and Template PartsCreating and using template parts| 00:00 | If you are creating a fair number of
forms in your organization, what I'm going
| | 00:05 | to show you next will change the way you work.
| | 00:07 | You have the ability to take part of a
form and save it as a template, and then
| | 00:12 | you can reuse that sub-portion of a
form in all the templates that you create.
| | 00:18 | We have actually two sections of this
form that might make sense to use that way,
| | 00:22 | and let me show you both of them.
Because if we go to our Developers view, at
| | 00:27 | the bottom, we have a section that's
for the use of the office that says when
| | 00:32 | was the work done, who did the work,
and what the notes are, and this kind of a
| | 00:36 | section is used over and
over and over again in forms.
| | 00:39 | So, it makes it for a good template part,
but we are going to use this section
| | 00:43 | up here at the top, which is called in
our field list requestor, but you could
| | 00:47 | think of as submitter.
| | 00:48 | It's a basic section that says, who are
you and how do we find you and when did
| | 00:53 | you submit this form?
| | 00:54 | Now we have some formatting here
that's unique to this form, some bolding and
| | 00:58 | things that we will want to probably
take off of our template part, but we're
| | 01:01 | going to click here to select the section.
| | 01:05 | So what I'm selecting here is I'm
selecting four text boxes, one date picker,
| | 01:09 | one dropdown list, all of the labels,
the table, and the section control itself.
| | 01:14 | I'm not selecting the field
list here because I actually can't.
| | 01:18 | Let's now copy this, and let's go to
File > New, and create a template part.
| | 01:26 | If I'm always going to use this in
the InfoPath Filler, or I want to use
| | 01:30 | InfoPath Filler controls, or
did in the section that I copied,
| | 01:34 | I might want to choose InfoPath Filler.
| | 01:36 | But I know that if I choose Blank
template part, that while this is a
| | 01:41 | web template part, I won't have a
control here that can't also be used
| | 01:45 | in the InfoPath Filler.
| | 01:46 | So it's a little more generic when I do that.
| | 01:49 | Notice I have a blank field list here, and
I'm going to paste my copied section here.
| | 01:56 | Now, as I said, there might be some
items that I want to unbold that were bolded
| | 02:00 | here in that one form.
| | 02:04 | So let's clean that up, and then
let's start creating our field list.
| | 02:08 | So in myFields, I'm going to insert a
group because every section, remember,
| | 02:13 | aligns, or is bound, to a group.
| | 02:16 | In myFields then let's add a group for
this section, and let's call it submitter,
| | 02:25 | because it doesn't matter if this is
an employee or a recipient or requester,
| | 02:31 | they are probably always the submitter.
| | 02:35 | And I'm going to really quickly bind
this section over here to the group.
| | 02:40 | Right-click on the section,
Change Binding, bind it to submitter.
| | 02:44 | There is my binding.
| | 02:46 | I can see the icon right up here.
| | 02:47 | Now I'm going to add six fields.
| | 02:51 | I'm going to add a First Name field.
| | 02:52 | I pressed Enter one too many times.
| | 02:58 | I'm going to add an lname
field. Click Add Field.
| | 03:02 | I am going to add emailaddress.
| | 03:08 | I'm going to add todaysdate, and
remember that this is of the Date type,
| | 03:15 | so I'll want to change my
data type right here right now.
| | 03:20 | I want to add an email address and
finally, I need to add the department.
| | 03:32 | Now, I have all my fields, and I'm
going to really quickly bind to my controls.
| | 03:37 | You'll want to do this in the same order I did.
| | 03:40 | You will want to bind the group
before you bind the individual controls, or
| | 03:44 | you'll get a chance to do this twice,
because when I bind a group to a section,
| | 03:50 | any controls in there that are already bound,
the binding is removed, even if it was right.
| | 03:55 | So make sure that you bind the section
first and then the individual controls
| | 04:01 | that are within the section.
| | 04:09 | I misnamed to field here,
| | 04:11 | so we'll go back and get that in a second.
| | 04:16 | This one is Email Address.
| | 04:17 | This one is supposed to be
Work phone. So let's fix it.
| | 04:22 | That looks good.
| | 04:23 | Now, notice that this is an optional section.
| | 04:26 | As soon as I placed a group in it, it's
optional, and it may be that many of the
| | 04:30 | parts that you create would be
optional some if not all of the time.
| | 04:35 | However, this is almost
never going to be optional,
| | 04:37 | so I'm going to change
its control type right now.
| | 04:40 | Right-click on Optional Section,
change the Section Properties.
| | 04:44 | The difference between a section and
an optional section is that an optional
| | 04:49 | section either is not in the form by
default or can be removed. So check this out.
| | 04:55 | I am going to turn that check box off.
| | 04:57 | It says include the section and don't
allow users to delete it, and when I apply
| | 05:01 | it, this is no longer optional.
| | 05:05 | Notice that I don't have any
formatting behind this section.
| | 05:08 | I don't have a page design in a template.
| | 05:11 | When I insert, my tables
don't really have any colors.
| | 05:14 | That's as it is intended because when I
take this template part and insert it in
| | 05:20 | another template, I'll be
using the theme from that template.
| | 05:24 | This is really ready to go.
| | 05:26 | I can't think of anything more we
need to do with it, other than save it.
| | 05:29 | So, let's click Save, and we
need to find a place to put it.
| | 05:34 | Now, I actually have a folder called
Office Templates with an InfoPath Template
| | 05:39 | Parts folder inside of it.
| | 05:42 | This will simply let you put this anywhere.
| | 05:45 | So, choose a place.
| | 05:47 | Another good place would be if you
have a folder for InfoPath development.
| | 05:51 | Keep them all in there because your
collection of template parts is a toolbox,
| | 05:55 | and you don't want to leave your
tools scattered all over the office.
| | 05:58 | We're going to call this SubmitterInfo,
and if there was more we want to say, we
| | 06:03 | could say SubmitterandPhone.
| | 06:09 | But this is, we could just call this
Submitter, and I am going to save this. All right!
| | 06:15 | So now, let's go ahead and close this,
and we are ready to create a new form
| | 06:21 | based on our template part.
| | 06:23 | So I'm going to close this form that I used
earlier, and I'm going to create a new blank form.
| | 06:30 | Now this is the only part of this
that might feel confusing to you at all.
| | 06:35 | If I go to Insert, I won't find any
place that says Template Part. And if I go
| | 06:41 | to Data, there's nothing here, or Developer.
| | 06:45 | That's because we need to make the
template part available, and it's really cool
| | 06:49 | how we are going to do this.
| | 06:51 | Let's go to the Controls list
down the Home tab in InfoPath,
| | 06:55 | click the dropdown, and say I'd
like to add a Custom Control.
| | 07:00 | It says, "Controls that are not
compatible with the current view compatibility
| | 07:04 | settings will be hidden."
| | 07:05 | For example, if you created a template
part that includes controls that can't be
| | 07:09 | used in a browser, it won't be shown.
| | 07:12 | It will be hidden while you are creating
a form that is going to use a web browser.
| | 07:19 | But I'm going to add this.
Here's Template Part, Next.
| | 07:23 | Find my Template Part.
| | 07:26 | Because I just created it,
I had no trouble finding it.
| | 07:29 | This is the last folder I had opened.
And I'm going to click Open and Finish.
| | 07:34 | It's called Submitter, and this
is the first time I've posted it,
| | 07:37 | so it's version 1.0.0.1.
| | 07:39 | I am going to click Close and OK.
| | 07:43 | Now, I'm ready to use my template part.
| | 07:47 | Click to open the Controls gallery,
and there's a new section at the bottom
| | 07:51 | called Custom, and here is your
fabulous template part that you just created.
| | 07:56 | Click to insert it in your document.
| | 08:00 | Here's your section. Here are
your Fields. Absolutely lovely!
| | 08:06 | So feel free to create and use
template parts for any significant
| | 08:11 | building blocks that you are using
as you're creating your template for
| | 08:16 | your organization.
| | Collapse this transcript |
| Importing an Excel form| 00:00 | If you already have a form that you
created in Microsoft Excel, you can use that
| | 00:06 | form as a great jumping-off point to
create an InfoPath form. Let me show you.
| | 00:12 | I have a form that I created in
Microsoft Excel, and it's an expense form.
| | 00:23 | So we're going to take a look at this,
and you'll find this same expense form
| | 00:26 | in the exercise files.
| | 00:28 | It is called Expense Form. Here it is.
And the way it works is that a user
| | 00:34 | enters some basic information, like a
date, and these items here are filled in.
| | 00:42 | And then they enter airfare, the amounts.
And the totals are done by the day and
| | 00:49 | by the week. And then they put in a
purpose and sign it either digitally, or
| | 00:55 | right now they simply type their name in.
| | 00:58 | That's good enough, and they enter
today's date, the date they are going to send
| | 01:02 | this off, and that's the form.
| | 01:05 | There's a separate tab in the
workbook where they paste receipts.
| | 01:08 | All of these things are clues because
if I want to place to paste receipts,
| | 01:12 | my finished form should have the
ability to be able to go in and either copy
| | 01:19 | and paste, that would be a rich text
box, or to click and attach an actual
| | 01:24 | receipt that I scanned.
| | 01:26 | So this is my form in Excel, and I want
to be able to post these to a SharePoint
| | 01:32 | site and be able to extract information,
like what week they were for, what the
| | 01:37 | purpose was, have they have been
approved, what was the total amount submitted,
| | 01:41 | by what employee, and how has it been
handled since then through the approval
| | 01:46 | and payment process.
| | 01:48 | Sort of a grand way to post that's going
to make it really easy for the folks in
| | 01:53 | our payables department to manage this.
| | 01:56 | So let's close this form here in Excel.
And because it does some calculations and
| | 02:02 | I entered some data, it wants to know
if I want to change this template, and I'm
| | 02:06 | not going to save it.
| | 02:07 | Now this is a template, but I could do
the same thing with a blank form that I had.
| | 02:12 | I don't need to have control
of the template to do this.
| | 02:14 | Let's go to InfoPath Designer and choose
in the Advanced Form Templates section,
| | 02:19 | Convert Existing Form. Two choices:
| | 02:24 | there is an importer for
Excel and an importer for Word.
| | 02:27 | I'm going to choose Excel and click Next.
| | 02:30 | I now need to browse to my file location.
| | 02:33 | So I am going to click the Options button.
| | 02:42 | I can choose to import
only the layout of the from;
| | 02:45 | the layout and the form fields, which
is the default; or to chose Layout and
| | 02:51 | form fields and do some specific
settings here around how tables are
| | 02:55 | detected and so on.
| | 02:56 | I am simply going to keep the
default this time and click OK.
| | 03:00 | We will come back and do this
again using Layout only in a moment.
| | 03:03 | Let's click Finish.
| | 03:05 | We will watch as the Import Wizard actually
works really hard converting this form layout.
| | 03:11 | It says it was imported successfully.
| | 03:13 | If you have a lot of merged cells in
your form, it might import unsuccessfully.
| | 03:21 | Other things that will give you
issues tend to be object- and table-related,
| | 03:25 | perhaps there is a link to an external
data source that it doesn't understand,
| | 03:29 | but most of the time, you'll get a
successful import, or at least an import.
| | 03:33 | Now let's go judge the success ourselves.
| | 03:36 | Here's our field list, and it is mighty, and
long and here is our form. Pretty amazing.
| | 03:43 | These are actually all extra
columns, and where do they come from?
| | 03:47 | Well, they are columns that
were in that Excel worksheet.
| | 03:52 | Likewise, down below we will see rows
that were in that Excel worksheet, and
| | 03:56 | there are ways for us to get rid of
this ahead of time by simply hiding
| | 03:59 | those columns and rows.
| | 04:01 | Let's take a look though, at what we did get.
| | 04:03 | Let's ignore the extra stuff.
| | 04:04 | For example, right here, we got a field.
| | 04:07 | Now it interprets this as a
repeating table, which is kind of interesting.
| | 04:11 | When we go into Preview mode, it
actually will know that it has three lines in
| | 04:18 | the repeating table. But it's a little
funky that it thinks you might want to
| | 04:21 | have four or five lines in an address.
And we can think about whether we actually
| | 04:25 | like that or not, or whether we think
that we want to make this not a repeating
| | 04:29 | table and simply three items.
But here's our first form field, our second.
| | 04:35 | All of our fields are here.
| | 04:37 | Now if you imagine the time that it
would take for you to place all of
| | 04:41 | these fields on a form, you begin to
appreciate what a sizeable head start we've gained here.
| | 04:48 | So if I want to go back in my form in
Excel and get rid of what are clearly
| | 04:53 | hidden columns, as opposed to columns
that have been removed, I can do that. Or I
| | 04:58 | can try to get rid of those here and
simply say that I'd like to delete some
| | 05:04 | columns, until they are gone.
| | 05:09 | But notice that it kind of
makes my form change a little bit.
| | 05:12 | So the easiest thing for me to do here is to
go back into Excel and open my template again.
| | 05:26 | And you'll notice that in Excel, part of
what makes this look like a web sort of
| | 05:30 | a template is that we are missing the
column and row headings, and those kind of
| | 05:36 | attributes, they've actually been turned off.
| | 05:38 | So we can go over to view and say
let's turn our headings back on, and you see
| | 05:42 | all of these extra columns that are here.
| | 05:45 | So if we decide that we want to
get rid of these here, we can select
| | 05:52 | every single one of them.
| | 05:53 | It's just here in our form. And we can
choose to delete those and see if that
| | 06:01 | makes a difference when we import.
| | 06:04 | It might also make a difference if
we simply hid them better, rather than
| | 06:08 | painting a format over them.
| | 06:10 | So again, choices that you have
here that you can complete in Excel.
| | 06:16 | That looks better. Might
give us a better head start.
| | 06:20 | So let's save this again and close it, and
let's go give this another shot here in InfoPath.
| | 06:29 | I'm going to close this version.
| | 06:31 | I could save it if I wanted to have
some iterative choices as I go along, but
| | 06:35 | I'm going to say don't save in this case.
| | 06:37 | Convert Existing > Excel Workbook, go back,
find my form. I still want the same options,
| | 06:45 | Layout and form field.
| | 06:48 | Let's see how it does this time.
| | 06:50 | Now presumably, it might be marginally
faster because it doesn't have to deal
| | 06:54 | with all those extra columns.
| | 06:55 | Let's say OK and see what we get.
| | 06:58 | You still have a fair number, but
certainly not as many as we did before.
| | 07:06 | So that starts to take
us in the right direction.
| | 07:08 | How would I attack this form now?
| | 07:10 | I would simply go in and begin naming my fields.
| | 07:15 | This is WeekEnding, and every one of
these is going to come in as text,
| | 07:19 | so I have to say that this is a date field.
| | 07:23 | It says that we'll rename.
You are used to this message.
| | 07:25 | We don't have any data.
| | 07:27 | We are happy people. And then I
would go and say, this is actually not a
| | 07:30 | repeating table right here, much as it
might like to think it's a repeating table.
| | 07:35 | So I'm going to simply change the control here.
| | 07:38 | Well, I have to make it non-
repeating first in my data source,
| | 07:41 | so let's remove this group altogether,
because I don't have a repeating group here.
| | 07:49 | And then I will have the ability to bind
this to some field that I create in a moment.
| | 07:53 | So I can create a new field or a new
group that's a non-repeating group, and
| | 08:04 | let's call this AddressInfo and
go ahead and create a group now.
| | 08:15 | And within that group, I can add the
fields that I need, which are FullName,
| | 08:25 | StreetAddress, CityStateZip.
| | 08:32 | And I'm going to bind this field to
FullName, and then I'll need to insert two
| | 08:44 | more fields underneath that.
| | 08:46 | Likewise, I can go and
rename all of these other fields.
| | 08:50 | I just have to figure out what I would
want to name them. There are a lot of
| | 08:53 | different fields here and because I'll
want to do math with them over here, it
| | 08:57 | becomes important what I name them.
| | 08:59 | Two possible ways to think about this.
| | 09:02 | This is the start date and the end
date; that's pretty straightforward.
| | 09:05 | This is where the person is going to that day.
| | 09:08 | So you could call this MON_To, TUE_To,
so that you can track the day, and
| | 09:22 | these will be text.
| | 09:23 | So by naming them with the weekday in
them, okay, then when you get to the end,
| | 09:30 | it will make sense when you create a formula.
| | 09:33 | So if I named this 'travel', this is
Monday travel, and a user is going to enter
| | 09:44 | a decimal value here.
| | 09:49 | Likewise, they will do the same in Tue Travel.
| | 10:03 | That means when I get all the way out
to the end, this field, which will be
| | 10:07 | Total Travel or SubTot_Travel, is going
to have a formula in it, and that formula
| | 10:23 | is going to start with my Monday
travel plus my Tuesday travel and so on.
| | 10:31 | And because I'm going to create a formula
for Travel, Ground Transportation, Hotel,
| | 10:36 | Breakfast, and so on,
| | 10:37 | this is one good way to do it, and I
will always know what's in that control.
| | 10:41 | Now one more thing that you want to think
about is this is in bad need of grouping.
| | 10:47 | So my question is, am I going to group this by
day or am I going to group this by function?
| | 10:55 | And that's a real question.
| | 10:57 | There are benefits to doing each.
| | 10:59 | You can simply think about how you
might like to do this. But I will tell you
| | 11:03 | that I would tend to group
all of the travel together.
| | 11:07 | Travel Mon, travel Tue, travel Wed,
and travel so on, all the ground
| | 11:12 | transportation together in one group.
| | 11:14 | So you'll be creating some groups,
grouping these, and putting this together, and
| | 11:17 | when you're all done, you are going to
have a really slick-looking form with a
| | 11:21 | great data source behind it.
| | 11:23 | Now, let's go do one more thing.
| | 11:27 | Let's close this. And you might prefer,
and some people do, to start by simply
| | 11:37 | saying give me the layout out of that form.
| | 11:39 | It will give me enough of a head start.
| | 11:44 | In that case, simply choose the first option.
| | 11:50 | The layout is really
pretty easy for you to get it.
| | 11:52 | It's the very first thing that happens in
the form. And you'll notice then no field list.
| | 11:59 | It's empty. It will stay empty, but a
nice-looking form with the layout only.
| | 12:06 | Let's throw this one away and
look at one more way to do this.
| | 12:12 | Let's convert this, and this time
after we choose our file, we choose Custom
| | 12:20 | Options. And what I'm going to say is
that I don't care if there is an empty cell
| | 12:26 | that has borders around it.
| | 12:27 | I don't want to include it.
| | 12:29 | To only give me text boxes where
there are cells containing formulas, cells
| | 12:34 | containing numbers, or cells that are
referenced by the formulas. Say OK. Finish.
| | 12:41 | Again, we are going to get a slightly
longer layout here in a number of fields.
| | 12:50 | But notice, when we do this, that in
this case I know that if there is an empty
| | 12:58 | cell somewhere with a border around it--
that I simply bordered it accidentally--
| | 13:02 | that's it's not showing up in my field list.
| | 13:04 | So, for example, right now, there
won't be a field here or a field here, even
| | 13:10 | though they have a border. Make sense?
| | 13:13 | So these are all the different tools
that you can use to take this form and jump
| | 13:18 | in and say, I'd like to start with this
here in Microsoft InfoPath. One more thought.
| | 13:25 | Just because you have this form, doesn't
mean this is the best way that you would
| | 13:29 | tackle travel expenses in InfoPath.
| | 13:32 | You might choose to do something very
different that was trip based, rather than day based.
| | 13:37 | You might, for example, have a layout
in a repeating table where someone chose
| | 13:42 | the date out of a date picker, entered
the day, if you even care, and then entered,
| | 13:49 | imagine this table in the center rotated
90 degrees and across the top was our Travel,
| | 13:55 | our Ground Transportation, our Hotel,
our Breakfast, Lunch, Dinner, and Other, and
| | 14:01 | each row would simply be
part of a repeating table.
| | 14:04 | So don't be afraid to imagine, if I had
had InfoPath when I designed this, would I
| | 14:09 | still have laid it out this way?
| | Collapse this transcript |
| Importing a Word form| 00:00 | Another way to get a jumpstart on an
InfoPath template is to start with an
| | 00:04 | existing Word form or Word form template.
| | 00:07 | In the New category, double-click on
Convert Existing, and choose InfoPath
| | 00:13 | importer for Word documents, and click Next.
| | 00:16 | I am going to now browse and find my
document, and it's called PledgeForm-Word.
| | 00:25 | This was actually created in Word 2010.
| | 00:28 | We can look at the options.
| | 00:30 | I am going to choose the default
options, which will give me some form fields, or
| | 00:35 | Layout only, or Layout and form fields.
| | 00:39 | Because I've chosen Layout and form
fields, and it includes every possible
| | 00:44 | conversion setting. This is the most rigor
InfoPath can bring to this particular import.
| | 00:51 | Let's click OK. Click Finish.
| | 00:55 | Notice that the form template was
imported successfully, but there are issues,
| | 00:59 | and we can see the Design Checker, which will
be opened when we click OK and open the form.
| | 01:05 | So rather than seeing our field list,
we see the Data Checker, and it says,
| | 01:09 | "Objects may be positioned incorrectly,"
and I am guessing that we might be
| | 01:12 | talking about this picture.
| | 01:15 | Because it was positioned using the
Word tools for positioning a picture, here
| | 01:20 | in InfoPath, we would, of
course, put this in a table,
| | 01:23 | so it's no longer a floating picture.
| | 01:27 | This image also has a lot of white
fill, and we have a background that's
| | 01:31 | not white in this form.
| | 01:33 | So this might be a good time to
delete this image and simply go back and
| | 01:37 | paste the image that we had originally
again, because the original didn't
| | 01:42 | have this fill behind it. So here we go,
| | 01:46 | a pretty nice-looking layout.
| | 01:47 | From time to time, we'll also lose a
space or something, but let's take a look
| | 01:51 | and see what data we brought in.
| | 01:55 | So, on the Data tab, choose Show Fields--
I don't need the Design Checker anymore--
| | 02:00 | and you will notice one whole field right here.
| | 02:03 | This is a place where there is an explicit
text box that doesn't have a prompt in it.
| | 02:09 | The other text boxes tended to have
placeholders, and they're mostly being treated as text.
| | 02:16 | This is the best we can do to have this one
field, and truly it's not that much in the way.
| | 02:21 | We can keep this field that works, and
then for all of the other fields, we'll
| | 02:26 | need to provide containers for them anyway.
| | 02:29 | So we will add text boxes and name
this Title, click here, and if you simply
| | 02:39 | select the text that's there already and
drop in a control then you can name it.
| | 02:49 | Our field has a name, and so on.
| | 02:51 | So we can work our way through
dropping new fields into this form.
| | 02:55 | The layout itself looks pretty good,
| | 02:57 | Ss we've got something out of it that
saves us some time, not as much as we had
| | 03:02 | when we were importing Excel.
| | 03:03 | The rule to take away from this is
that InfoPath is really good at walking
| | 03:09 | through an Excel workbook and figuring
out where there are cells and formulas.
| | 03:13 | It doesn't take the hints that we've
provided using the Word form fields in
| | 03:18 | exactly the same way.
But again, we get a better start.
| | 03:22 | Our new InfoPath form is going to look
very similar to the form that was created
| | 03:28 | and used for a month or
ten years in Microsoft Word.
| | 03:32 | So we'll start this with a regular
user base comfortable with our form.
| | 03:37 | That's a good way to move forward.
| | Collapse this transcript |
| Creating a template based on an XML or schema file| 00:00 | If you happened to have an XML file or
a schema file for XML, you can create a
| | 00:07 | new template based on that schema.
| | 00:11 | This probably isn't going to happen to
you all that often, but it's happened to
| | 00:15 | me a couple of times, so
let's talk a little bit about it.
| | 00:18 | If somebody who's given you an XML file,
for example, to use as a dropdown list
| | 00:23 | elsewhere in an InfoPath form,
something that we did in the last chapter,
| | 00:28 | you could then create a form that would
allow you to add items to the XML file.
| | 00:34 | Or you could create that form, post
it on a SharePoint site, and have an
| | 00:39 | interface to be able to
add items to the XML file.
| | 00:43 | More typically, what you'll have is
somebody will actually have a schema that
| | 00:48 | they've used in Microsoft Excel or
Microsoft Word or some other application, and
| | 00:54 | it's been exported and they
say, what can I do with this?
| | 00:57 | Here's a description of what my data
looks like, but how in the world would I
| | 01:01 | create a form that goes with this?
| | 01:03 | So let's choose Advanced Form Templates >
XML or Schema, and again, either will do.
| | 01:08 | We'll be prompted to supply an XML
document, which could already have values
| | 01:15 | filled in, and instance of that XML
where somebody's typed everything in, or a
| | 01:21 | schema, the description of what the
data that could be allowed in that document
| | 01:25 | would look like. And we'll
have our Locations document here.
| | 01:30 | You might remember that we used this
document earlier to be able to include
| | 01:36 | a list of locations, along with our InfoPath
template, so that it was used easily offline.
| | 01:43 | Let's go ahead and open this, click
Next, and we'll be asked, do we want to
| | 01:47 | place any other schema or XML
document in the main data source?
| | 01:53 | We might, for example, have a schema
for locations, another schema for products
| | 01:59 | that we carry and we're trying to put
together a list that would allow people to
| | 02:02 | choose a location in a product.
| | 02:05 | What it's asking is, is this the
route of the schema, or do I need to create
| | 02:11 | a higher-level route?
| | 02:13 | I'm going to say, nope.
This is it. Then it'll say, oh okay.
| | 02:15 | Well, then locations is at the
top of my schema. Click Finish.
| | 02:21 | It says, "The structure of the XML will
provide the data source for the form, but
| | 02:26 | there are also some values in here.
| | 02:28 | Do you want to use them as the
default data in your template?"
| | 02:32 | I'm going to say no normally,
because I want to throw away the data, but
| | 02:36 | because we're a little familiar with
this data, I'm going to say yes, so that we
| | 02:40 | can see it, because it
will help us make more sense.
| | 02:44 | So here's our Fields list, here's
Location, and you might remember that we had a
| | 02:50 | retail location on Market Street in Ventura.
| | 02:52 | It simply pulls in the data out of the
very first of the eight or nine records
| | 02:57 | that are in here, so that we can see this.
| | 03:00 | How would we create a form?
The same way we always do.
| | 03:04 | We'd use a Page Layout template, drop it
in place, add some tables, and then we
| | 03:10 | would add controls right here.
| | 03:15 | So I want to include the street,
right drag, put in a text box.
| | 03:20 | If I want to show all of the
locations in here, I can actually put in a
| | 03:24 | repeating text box, and I can see then all
of the various locations that are in here.
| | 03:30 | Notice that this comes up and says, it's
repeating. Or what I could choose to do
| | 03:36 | is I could choose to right-drag the
entire location and say, I would like a
| | 03:40 | repeating table, and doesn't that
look about like we would expect it to?
| | 03:44 | Let's go into our Preview mode,
and notice here are all of those items in the
| | 03:49 | list, with the ability for us to add yet another.
| | 03:53 | So I can quickly and easily create a
form to expand that XML document that I
| | 03:59 | included as a resource file for my form
or any other XML document that I wish.
| | 04:05 | Very easy to do. Simply start with
your XML or your schema and import it
| | 04:12 | into InfoPath.
| | Collapse this transcript |
|
|
ConclusionWhat's next| 00:01 | Well, here we are at the end of the course.
| | 00:03 | So what's next for you in InfoPath 2010?
| | 00:07 | I have some suggestions.
| | 00:09 | There are some specific areas of
exploration that would provide fruitful for you
| | 00:14 | if you've enjoyed this course up until now.
| | 00:16 | First, I didn't cover every
single control in this course.
| | 00:21 | For example, there is a SharePoint
Group Picker if you're working in a
| | 00:24 | SharePoint environment, or
an External Data Control.
| | 00:28 | For development with a tablet PC user
in mind, there's an Ink Picture Object,
| | 00:33 | and there's a wonderful Master Detail
Container that can only be used if you're
| | 00:38 | using the InfoPath Filler.
| | 00:40 | So you could take a look at all of
those options if they fit your needs in your
| | 00:44 | particular environment.
| | 00:46 | You could also take a look at the
ability to embed an InfoPath form inside a
| | 00:52 | page in SharePoint using the InfoPath Web Part.
| | 00:56 | So if you're using SharePoint 2010,
that's a good direction to go in.
| | 01:00 | And then finally, there's a lot more
that can be done with rules, provided that
| | 01:05 | you're using the Form Filler tool.
| | 01:07 | So how would I learn more
about any of these topics?
| | 01:10 | If you'd like to know more about
schemas and XML and how you might work in that
| | 01:15 | space, whether you're creating XML
resource files to a company templates for
| | 01:19 | offline use or you just would like to
have a far better understanding of what's
| | 01:24 | under the hood of InfoPath, I'd like to
refer you to Joe Marini's XML Essential
| | 01:29 | Training course on the lynda.
com Online Training Library.
| | 01:33 | If you're developing InfoPath and
you're in a SharePoint environment in your
| | 01:38 | organization, even if you're not a
SharePoint user, I want to encourage you to
| | 01:42 | learn more about SharePoint.
| | 01:44 | These two tools go together so
beautifully that it's almost a shame to have a
| | 01:50 | SharePoint server sitting there and
not know how to use it for your forms.
| | 01:54 | Simon has a great course on the lynda.
com Online Training Library for SharePoint
| | 01:59 | 2010 Essential Training.
| | 02:01 | And I'd like to give a callout here and
thank him for setting up the SharePoint
| | 02:05 | server that I've used during this course.
| | 02:07 | So you have a lot of different
directions you can go in at this point depending
| | 02:11 | on what your individual
development environment is.
| | 02:15 | I encourage you to try all kinds of
different approaches to form development.
| | 02:21 | See what it looks like to create a
simple form that gets returned to you by
| | 02:25 | email, even if you're in
that SharePoint environment.
| | 02:28 | And if you have a few folks who can
use the Form Filler that will give you an
| | 02:32 | opportunity to check out those other
tools that aren't supported in browsers.
| | 02:36 | Whatever you do, I hope you have a
fabulous time developing forms in
| | 02:40 | InfoPath Designer 2010.
| | Collapse this transcript |
|
|