Skip to main content

Notifications

Copilot Studio - General
Answered

Full question text not showing on PVA BOT

Posted on by 10

Dear Friends ,

I am at beginner level working on PVA. I have a small doubt.

In Power Virtual Agent , my full question text is not visible fully. Though in canvas I gave my full question text.

Only limited char's alone showing while testing the BOT & even after publishing.

Is there any Char limitation? . or does this related to any settings issue?

Please help to give your inputs.

 

Regards,

Karthikeyan.S

  • fernandosilva Profile Picture
    fernandosilva 785 on at
    Re: Full question text not showing on PVA BOT

    @KKShan ,

     

    Just make sure you publish your bot.

     

    Cheers,


    Fernando

  • KKShan Profile Picture
    KKShan 10 on at
    Re: Full question text not showing on PVA BOT

    Hi @fernandosilva ,

     

    Thanks a lot for your inputs. I am clear now. 

  • Verified answer
    fernandosilva Profile Picture
    fernandosilva 785 on at
    Re: Full question text not showing on PVA BOT

    Hi @KKShan ,

     

    If you don't use premium connectors, that's ok then. No further subscription is required.

     

    Cheers

  • KKShan Profile Picture
    KKShan 10 on at
    Re: Full question text not showing on PVA BOT

    Hi @fernandosilva ,

     

    Yes. I have used the below CSS script from the link (https://docs.microsoft.com/en-us/power-virtual-agents/customize-default-canvas ) you have provided & tried. Is something wrong with the script?. You can see my BOT ID filled on the script. Any issues with below script? 

     

    --------------------------

     

    <!DOCTYPE html>
    <html>
    <head>
    <title>Contoso Sample Web Chat</title>
    <!-- This styling is for the Web Chat demonstration purposes. It is recommended that style is moved to separate file for organization in larger projects -->
    <style>
    html, body {
    height: 100%;
    }

    body {
    margin: 0;
    }

    h1 {
    font-size: 16px;
    font-family: Segoe UI;
    line-height: 20px;
    color: whitesmoke;
    display: table-cell;
    padding: 13px 0px 0px 20px;
    }

    #heading {
    background-color: black;
    height: 50px;
    }

    .main {
    margin: 18px;
    border-radius: 4px;
    }

    div[role="form"]{
    background-color: black;
    }

    #webchat {
    position: fixed;
    height: calc(100% - 50px);
    width: 100%;
    top: 50px;
    overflow: hidden;
    }

    </style>

    </head>
    <body>
    <div>
    <div id="heading">
    <!-- Change the h1 text to change the bot name -->
    <h1>Contoso Bot Name</h1>
    </div>
    <div id="webchat" role="main"></div>
    </div>

    <script src="https://cdn.botframework.com/botframework-webchat/latest/webchat.js"></script>

    <script>
    const styleOptions = {

    // Add styleOptions to customize Web Chat canvas
    hideUploadButton: true
    };

    // Add your BOT ID below
    var BOT_ID = "a03622b5-18c0-4ecb-8e59-fa0b28006d4e";
    var theURL = "https://powerva.microsoft.com/api/botmanagement/v1/directline/directlinetoken?botId=" + BOT_ID;

    fetch(theURL)
    .then(response => response.json())
    .then(conversationInfo => {
    window.WebChat.renderWebChat(
    {
    directLine: window.WebChat.createDirectLine({
    token: conversationInfo.token,
    }),
    styleOptions
    },
    document.getElementById('webchat')
    );
    })
    .catch(err => console.error("An error occurred: " + err));

    </script>
    </body>
    </html>

    ----------------------------------------------------------------

     

    Regarding my 2nd question: FYI , i am not using any premium connectors. 

     

    So are you saying I need some subscription plan to see Power automate output as selectable / choice option in PVA?. Pls double confirm. 

     

     

     

     

  • fernandosilva Profile Picture
    fernandosilva 785 on at
    Re: Full question text not showing on PVA BOT

    HI @KKShan ,

     

    Have you posted the bot id on this field: 

    var BOT_ID = "<ENTER YOUR BOT ID>";

     

    If you are not using Premium connectors, that should be fine.

    If yes, you need a proper "Subscription Plan" then..

     

    Cheers,


    Fernando

     

     

     

  • KKShan Profile Picture
    KKShan 10 on at
    Re: Full question text not showing on PVA BOT

    Hi @fernandosilva ,

     

    First of all , thanks for your reply. I am using PVA within MS teams app (as its free to use). I tried the steps you have provided. But it throws below error when i tried to open. So I guess the above CSS update can be performed only on website pages which requires premium. Am I correct?. 

     

             KKShan_0-1655190381284.png

             

     

    Also I have another question.

    I am using Power Automate flow within PVA. The automate flow will filter excel file & gives the output as input to PVA. The automate output will be like list of questions. But its comes as plain text. So do you have any idea , how to can convert those output questions as selectable choice in PVA (like how we used to select questions in hardcoded method). 

     

    Is that something we can do in Power Automate?. Or do I need to do something in PVA?. Pls give me the steps to achieve (if any

     

  • fernandosilva Profile Picture
    fernandosilva 785 on at
    Re: Full question text not showing on PVA BOT

    Hi @KKShan ,

     

    If you use the canvas template like this one: https://docs.microsoft.com/en-us/power-virtual-agents/customize-default-canvas you can also create your own css overwriting the canvas csss provided.

     

    In this case, you can overwrite the default css with the one below, the options will appear os a vertical list an not horizontal. Also, the text will wrap to another line when the question is larger than the space.

     
     

     

    .react-film__filmstrip__list {
     display: block!important;
     word-wrap: break-word!important;
    }

     

     

    To center the content of the options, use this css to overwrite the default one:

     

     

    .webchat--css-bpaer-1p6cdge.webchat__suggested-action {
     -webkit-box-align: center;
     align-items: center;
     background-color: white;
     border-color: rgb(0, 99, 177);
     border-radius: 0px;
     border-style: solid;
     border-width: 2px;
     color: rgb(0, 99, 177);
     font-family: Calibri, "Helvetica Neue", Arial, "sans-serif";
     font-size: inherit;
     height: 40px;
     -webkit-box-pack: center;
     justify-content: center;
     max-width: 100%;
     outline: 0px;
     padding-left: 20px;
     padding-right: 20px;
     position: relative;
     white-space: nowrap;
     width: 100%;
    }

     

     

    Change anything as you wish.

     

    I hope it helps.

     

    Kind regards,

     

    Fernando

Helpful resources

Quick Links

Welcome to the Power Platform…

We are thrilled to unveil the newly-launched Power Platform Communities!…

Getting Started…

Welcome to the Power Platform Community! We appreciate your visit…

Welcome to the new Power Platform Community!…

We are excited to announce our new Copilot Cookbook Gallery in the Community…

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 138,300

#2
RandyHayes Profile Picture

RandyHayes 76,308

#3
Pstork1 Profile Picture

Pstork1 63,179

Leaderboard