UIP App Block EnterTask() method

B

bryan

I start a new task by calling OnEnterTask. Based on the TaskArguments,
I want the new task to start in one of several views. No matter what I
do, however, it always starts in the startView as specified in the
config file.

Any way to make this do what I want?

Thanks,
Bryan
 
È

ÈÎÔ¶[΢Èí]

Hi Bryan,

Welcome to MSDN newsgroup!

From your description, I think you set some "startViews" in the config
file, but you want the new task to start in one of TaskArguments which set
before. Please tell me if I have misunderstood something.

Actually, I'm confused why you not disable the view specified in the config
file. Could you please give me some details about your requirement and
concern?

I also want to know how you start a new task by calling "OnEnterTask"
method. I notice the ControllerBase class containing the EnterTask method.
We can derive it and implement the function manually. So could you tell me
how you implement it?

Happy for discussed with you, I'm looking forward your reply.

Regards,

Yuan Ren [MSFT]
Microsoft Online Support
 
B

bryan

Hi Yuan, nice to talk with you again. You must be the UIAPB expert...

If I don't specify the startView in the config file, I get an error -
it is expected by the schema. So in my OnEnterTask method, I try to
change the current view like this:

public override void EnterTask(TaskArgumentsHolder taskArgs)

// Figure out where I want to start,, then

//
// I have tried various combinations of the followowing, none of which
// seem to work - I always get the startView specified in the
// config file

this.State.NavigateValue("ViewIWantToStartAt");
this.Navigator.Navigate("NodeName");
this.Navigator.CurrentState.CurrentView = "ViewIWantToSee";

Any suggestions?

Thanks,
Bryan
 
È

ÈÎÔ¶[΢Èí]

Hi Bryan,

Thanks for your response!

At the current stage, I think your purpose is starting with another view
which not specified in the config file. Please let me know if I have
misunderstood something.

As far as I know, the value set in the config file would be loaded when the
UIP application starts. That means while the UIP application starts, it
will read the value by calling XmlReader (or something else) method to get
these values. Then the setting applies to the application. It is the reason
why we need specify the startView in the config file.

The EnterTask method is the exposed interface to make some extension; it
would not be executed automatically. Would you please to me how you
implement it, is it derived from the ControllerBase class directly?

Actually, I'm confused why not directly change the startView to a new view
which we want to navigate in the config file.
Maybe you have some specific concern. Could you please give me some
description for your detailed requirement? I suppose currently the
startView is the cart view, but you just want to start your web application
at the order view.

It's my pleasure to be of assistance, I looking forward your reply.

Regards,

Yuan Ren [MSFT]
Microsoft Online Support
 
B

bryan

Hi -
The view I want to start at is in the config file, it's just not
the default start view. EnterTask() is called when the task is started
from an already executing UIAPB task, and depending on the current
state of the application, I need to have different start views for
this second task.

For instance:

public override void EnterTask(TaskArgumentsHolder taskArgs)

{
MyObj o = taskArgs as MyObj;

if(o.foo == true){
//
// Start at foo.aspx
}else{
//
// Start at normal start view from config file

}

THis seems like something that I should be able to do.

Thanks,
Bryan
 
È

ÈÎÔ¶[΢Èí]

Hi Bryan,

Thanks for your response!

Your description makes me clear about the requirement. I'm testing for the
issue and performing some research now. I'll reply to you as soon as I get
any results. Thanks for your understanding!

Yuan Ren [MSFT]
Microsoft Online Support
 
È

ÈÎÔ¶[΢Èí]

Hi Bryan,

I'm sorry for reply late. For the current issue, I have discussed with the
expert form Enterprise Library team. The way of implement is out of scope
for newsgroup support. It is better for you if one of our PSS support
engineers supply sample how to implement your requirement. This may need
you submit a support incident in Microsoft PSS (Product Support Service).
As a MSDN subscriber, you have two free support incidents.
For your reference, I attached steps to contact Microsoft PSS here: You can
contact Microsoft Product Support directly to discuss additional support
options you may have available, by contacting us at 1-(800)936-5800 or by
choosing one of the options listed at:
http://support.microsoft.com/d-efault.aspx?scid=fh;EN-US;Offe-rProPhone

Thanks for your understanding!

Best regards,

Yuan Ren [MSFT]
Microsoft Online Support
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
474,431
Messages
2,571,677
Members
48,796
Latest member
Greg L.

Latest Threads

Top