USD – Webpage in a Session

I love answer questions about Unified Service Desk!

The question I was asked today was how to load an external web page from a toolbar button. That is fairly simple and typically done with a global tab. But the twist here was to start a session containing that page.

Here is the answer;

  1. Create a hosted control.
  2. Create an action. (To show webpage)
  3. Create an action. (To Start a Session)
  4. Create a toolbar and toolbar button.
  5. Create a session name.

In my example I created a button called “LOAD PAGE”, this started a session and loaded a webpage into that session. If I am honest, I think I would have done this as a global tab and not made the web page part of a session. But the person asking the question specifically asked about loading a web page into a new session from a toolbar.

Plus, in the end this turned into an interesting example! As I am creating a session WITHOUT using a window navigation rule. Using a CreateSession action. A first for me!

Step One – Create a hosted control.

As with most things USD related I start by creating a hosted control, as I will need a tab to hold a web page. Mine looked like this;

Field Description
Name EXAMPLE WEB PAGE

You could call yours anything!

Display Name TAB NAME!

This is the name that will show above the tab.

USD Component Type Standard Web Application
Hosting Type IE Process

I always use IE Process and so should you!

Application is Global NOT selected.
Display Group MainPanel

Step Two – Create an action. (To show webpage)

The action to show a web page is pretty simple. I just used a navigate action.

Field Description
Name WEB PAGE – Navigate
Order 20

You will see why I 20 in a minute!

Hosted Control The one we just created, “EXAMPLE WEB PAGE”
Action Navigate

What is interesting here is that I am using a navigate action! Interesting as navigate actions do not trigger the window navigation rules, so I needed a non-standard way to start my session.

Data url=http://bbc.co.uk

This could be any webpage you want to display.

Step Three – Create an action. Create an action. (To Start a Session)

Next I needed an action to start my session as I wasn’t going to use a window navigation rule.

Field Description
Name CRM Global Manager – Create Session
Order 10

You will see why 10 in a minute!

Hosted Control CRM Global Manager

You will have a global manager, although it could have a slightly different name!

Action CreateSession
Data Blank

Step Four- Create a toolbar and toolbar button.

Next I added a toolbar button to my main toolbar. And added the two actions I had created. Mine ended up looking like this ….

Hopefully the order now makes sense! As I needed that create session action to have a lower number than the navigate action.

Obviously this is just an example, in a production version you would name the button in a better way!

Step Five – Create a session name.

The final step is to give my session a name. This again was slight non-standard! Typically sessions are started from a CRM entity. Here no entity was involved.

In the session lines section of USD settings I created a session line that looked like this;

Field Description
Order 1
Name DEFAULT SESSION NAME

Could be called anything really!

Selected Entity Blank

This isn’t normal. What is going to happen is whatever session name we pick will be used whenever a session has no entity.

Type Session Name
Display SESSION NAME!

The name I wanted to display in my application.

Hopefully this has been an interesting example and answered the question I was posed. I have found this fun to do as I’d not used a CreateSession action before. Thanks.
J

One thought on “USD – Webpage in a Session

  1. Pingback: USD – The Book | Microsoft Dynamics CRM and Unified Service Desk

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s