HAT & Web Adapter Conflict?

Mar 7, 2012 at 4:03 PM

I've created a Custom Web Application Adapter for the tab that displays the CRM Case Entity.  I built a SaveCase automation to mimic the saving of a case.  The only way the automation appears to work is if I change the Adapter on my Control to use the HAT Automation Adapter instead of my web adapter which eliminates the custom functionality I developed in my Web Adapter.

I guess the question, is can I still have my Control use my custom web adapter, while certain actions use my configured automations?  Is it possible to trigger the automation from my custom web adapter?

In my action, should I be including the WorkflowXAML as opposed to pointing it at a current .xaml file?  I'm just wondering if these 2 things can co-exist within a single control.

Hopefully this makes sense, just trying to see whether I need to rebuild my Web Adapter events as .xaml workflows so I can still include some of the automations as well.

Jeremy

Mar 7, 2012 at 5:33 PM

To be a little more clear, I have a hosted control that sits in the workflow pane.  This has a drop-down with some options for the agents to trigger in CCA.  What I am trying to do is have the option execution an automation within the session.  I've got an action setup on the Hosted Control that references a workflow assembly compiled in the UiiAutomations project that comes with CCA.

Ideally, what I'm trying to do is have the drop-down execute the automation by Firing the Action for this Hosted Control  The automation:

- Checks for the CRM Case Application (has a Web Adapter setup and configured for URL manipulation)
- Triggers a Click on the Request Tab
- Then Triggers a Click on the Save Button

The automation works like a charm when it's configured against my Web Hosted Control for the Case Entity, but I can't seem to get it to execute when it's called from the Hosted Control I built.  I've copied the DDA data from the UII Inspector to both the Case Web Hosted Control and the WPF Hosted Control with the drop-down to trigger the automation.

Is it just not possible to do this or do I need to Execute the Workflow similiar to how the Workflow Explorer does it?

Jeremy

Mar 7, 2012 at 7:33 PM

Sorry for the post, I figured it out.  In case anybody else runs into this:

1. In your custom Adapter project, add a reference to Microsoft.Uii.HostedApplicationToolkit.DataDrivenAdapter.dll

2. Add this to your using statement

3. Override the Initialize method to create your DDA Instance and to assign the InitStrings/Object

4. Now handle your custom action in the DoAction method and call dda.ExecuteControlAction(<name>);

I found the solution under the Using DDA's in the Custom Application Adapters section of the UII Development Help File

Jeremy

Aug 21, 2012 at 10:21 PM

Hi Jeremy,

I'm stuck with this same issue, only difference is mine is a Windows application so my class derives from ApplicationAdapter but otherwise I'm on a very similar situation, some custom code on the adapter, some functionality as workflows and when I change the adapter from HAT to the custom one the workflows don't get to run. Can you please elaborate on points 3 and 4?, what type do you use as DDA on point 3, at the end of your DoAction do you call base.DoAction ?, 

Thanks.

David.