Bot Framewok Composer - "Replace this dialog" causes an error 400 - replace

I'm building my first chatbot with bot Framework Composer and I don't succeed in building a very simple scenario.
I looked deeply in the Bot Framework Composer Documentation but found nothing helpful.
Child Scenario I want to achieve:
Bot asks/prompts 'Says something plz'
User answers/types a string, something like 'anAnswer'
Bots says "You said 'anAnswer', is it correct ?"
User types "yes" or "no"
if user typed "yes" : End of dialog
if user typed "no" : repeat this dialog
See the Bot Composer Canvas here
The problems I face :
1. "Repeat this dialog" does not work as I expected.
The emulator keeps telling me :"Recursive loop detected, AdaptiveDialog cannot be repeated twice in one turn"
I tried to turn the "Allow Loop" on "True" but it seems to result on a infinite loop (though I don't know how I can check that...)
See the "Repeat the dialog" options here
Do I have to add something in the "Options" of the "Repeat the dialog" action ?
Like where the loop have to start ? If so, how to do that ?
2. How to use "Replace this dialog" with a scenario already used ?
As I didn't succeed with the "Repeat the dialog" action, I then tried to cut in half the whole dialogue by dividing it in two dialogues. Each dialogue have one goal :
the first scenario is for asking information to the user
the second scenario is for asking confirmation to the user
See the "Ask for infos" dialog here
See the "Confirmation" dialog here
The initial goal was to "redirect" the user toward the "Ask for infos" dialog when he whant to edit what he typed previously.
But here, it results on a error : POST400directline/conversations/<conversationId>/activities
Here again there are some "options" possibles for the "Replace the dialog" action, but I didn't found anything in the documentation on this subject.
Thanks a lot for helping a newbie, I'll gladly try the solutions you bring me and make the feedback.
Have a great day,
PS : Do you know a good tutorial on Bot Framework Composer (other than the Microsoft ones ?)

Before using the Repeat the dialog action you have to clear the variable storing the user answer. The reason its looping is the bot already have an answer in memory so it wont prompt the user again.
use the 'Set a property' action and set the variable value to null before repeating the dialog

Related

I want to redirect original Error Page. (Oracle APEX 21.1)

My professora :D
I don't want to create an error process for errors that would only appear when unlucky, e.g. "ORA-00055: maximum number of DML locks exceeded".
But if I don't do anything about it, APEX show the error log screen. I don't like that thing.
Is it possible to change the error screen in the settings within the Application?
For example, displays a message "Please wait some time and then execute again" with an image of a cute cat.
Thank you for your kindness that tried to answer my question.
And imagining a picture of a cute cat :)
Haven't done this myself since I'm not that fan of cute cats when I get errors in my application but this is how I would go about doing it.
In apex the look and feel of pages, regions, buttons, lists, etc is configured in templates. So if you want to change how something looks, templates is the place to look.
Look up what template is used for the error page. Navigate to "Shared Components > Themes > #your theme# > Component Defaults" and look for "Error Page".
In my case the value is "Standard" so that needs to be changed. Navigate to "Shared Components > Templates" and look for the Page template "Standard". Take a copy and name it "My template with Cat".
Modify the template to your needs. Add the cat picture here.
Modify the Component Default in step (1) from "Standard" to "My template with Cat"
Note that this will work for apex error only. If you are encountering ORDS errors, it will go to the default ORDS error page (no idea how to change that).

Imacros for facebook like

Just started to learn Imacros, recorder macros for Facebook to like page, but when i play macros it gives me this kind of error
RuntimeError: element BUTTON specified by
TYPE:submit&&ID:u_0_1c&&DATA-OWNERID:u_0_1b&&DATA-PROFILEID:106053553060414&&CLASS:_42ft_4jy0PageLikeButton_4jy4_517h_9c6&&VALUE:1
was not found, line 6 (Error code: -921)
You problem is,
"submit&&ID:u_0_1c&&DATA-OWNERID:u_0_1b&&DATA-PROFILEID:106053553060414&&CLASS:_42ft_4jy0PageLikeButton_4jy4_517h_9c6&&VALUE:1 "
points to a spesific a specific button, I assume you want to click any like button from whatever page you are on you should choose a more general selector. On the record in imacros you can choose multiple methods of recording choose a different one.

Provide semantic grammar to OK Glass menu

When registering a menu item for the "OK Glass..." I'd like to some how provide a different semantic value to what is actually displayed. The example I have is "OK glass, find an ATM" is difficult for Glass to recognise and I'm thinking this is because it is expecting the word "ATM" instead of "A-T-M". If possible can I somehow provide these semantics into the menu whilst displaying an alternate message?
The Glass Developers Voice Command Checklist and Voice Input pages both recommend using a generic trigger under the "ok glass" menu, immediately followed by speech recognition to determine specific/unique parts of the request.
Could you use something like: "ok glass, find the nearest location for..."
... and then recognize the speech for "...A-T-M".
Here is the example used on the Voice Command Checklist:
"ok glass, find a recipe for..." (this allows users to speak "chicken kiev" and immediately see the recipe)
This approach also has the benefit of being generic enough to have your Glassware locate a number of places, not just an ATM.

Sitecore item will not go into edit mode; any suggestions on how to troubleshoot?

I have several Sitecore items (whose template is connected to an approval workflow) that will not go into Edit mode when clicking "Edit" from the "Review" tab. The same workflow is used elsewhere on the site successfully (the site is more than 3 years old), but clicking Edit in this case doesn't seem to affect the workflow state.
I've turned on verbose logging, which provides a lot of detail, but nothing to indicate any error conditions. I've been comparing how this template is configured with other "working" templates for a couple of days and everything looks Kosher, but surely I'm missing something obvious.
EDIT: The item(s) in question are imported by a data provider, and I've confirmed that for some reason Sitecore is not setting the "Workflow" and "State" system standard fields with a default value. That appears to be at least part of the issue.
EDIT 2: Followed the steps in this thread http://sdn.sitecore.net/Forum/ShowPost.aspx?PostID=45991 to use Sitecore Rocks to update all of the items to the correct Workflow State, but the update did not stick. For some reason workflow changes are not persisted for imported items.
EDIT 3: Clicking the Edit dropdown button under the Home tab displays the message "The item is currently not part of a workflow."
Standard values set correctly? Only have one Standard Values item for this template?
Generally, almost every time I run into a situation where X works on certain items, but not on others... it's a permissions issue. You've tested this as an Administrator I hope?
Sorry my suggestions are so vague, but it's hard to be specific here. We need some more information from you... When you click on Edit what exactly are you expecting to happen? I'm not entirely sure what you mean by "Edit mode" here. In Content Editor, all items are essentially in edit mode all the time... In my configuration, when I click on Edit, I am just locking the item. It does not change workflow state or create a new version.
These items are coming from a data provider... is your data provider handling Lock/Unlock calls properly? I know it's possible to use a data provider without implementing the entire Item API.

property sheet data validation

When the user clicks the OK or APPLY button on a property sheet and the program determines data on some page is invalid, how can I cause the page containing the error to be displayed along with a message box describing the error?
Currently the procedure doing the validation does the following while processing the PSN_APPLY notification.
MessageBox (hDlg, "Data must be positive!", "Error", MB_OK);
SetWindowLong (hDlg, DWL_MSGRESULT, PSNRET_INVALID);
This works ok if the page doing the validation (A) is currently displayed but if some other page (B) is being displayed, the message box appears with that page (B) being displayed, then when the message box is answered, the page with the validation error (A) is displayed. I thought about setting some flag so that when that page (A) gets the PSN_SETACTIVE notification it displays the message box but that seems kind of hokey.
Win32 API in c++, no MFC, no NET, nothing fancy.
I think the problem is in the design of your validation and it's presentation.
Am I right in thinking that you iterate through your property sheets, validate them and display a message box if something is awry? Because of course, what you have witnessed will happen, if I am on property page 3 and I wrote crap in to a field on property page 1.
The easiest solution is, when validating, note which property page the field in question is, and set that one active if the user has written crap in to one of your fields. This seems the fastest way possible.
Also, rather than spring up an annoying message box, reserve some room beneath the property pages to display a textual (red or otherwise) warning as to why, and then change to the appropriate property page, and highlight the offending control. Your validation routine can do this nice and easily as it loops through.
Even better, don't stop at the first error. One thing I HATE is correcting one field that I think is the only issue, only to be told every time I hit "OK" or "SUBMIT" that there's something else I missed.
I seriously think you should consider going the extra mile here... loop through ALL controls, and add all invalid ones to a list. Then change each offending control's background colour, tab colour etc... Then the user can work through and correct, no matter how many errors he or she made.