locked
MS CRM USD Hosted Control Automation RRS feed

  • Question

  • Hi,
        I have created Hosted application in USD for web application. Web application has login page Username , Password and Sign in Button.

    I have created USD hosted control Automation using HAT automation in visual studio.

    1) DDA automation binding  
                   

    <?xml version="1.0" encoding="utf-8"?>

    <initstring>

      <homePage useNewProcess="False">https://paytm.com/myorders/</homePage>

      <hostOnTop />

      <Extensions>

      </Extensions>

      <adapter>

        <URL>Microsoft.Uii.HostedApplicationToolkit.AutomationHosting</URL>

        <type>Microsoft.Uii.HostedApplicationToolkit.AutomationHosting.AutomationAdapter</type>

      </adapter>

      <DataDrivenAdapterBindingsCollection>

        <DataDrivenAdapterBindings>

          <Type>Microsoft.Uii.HostedApplicationToolkit.DataDrivenAdapter.WebDataDrivenAdapter, Microsoft.Uii.HostedApplicationToolkit.DataDrivenAdapter</Type>

          <Controls>

            <InputElement name="u_ID" type="InputElement">

              <ElementMatchPath>/HTML/BODY/DIV/DIV[1]/DIV/FORM/DIV/INPUT</ElementMatchPath>

            </InputElement>

            <InputElement name="u_pd" type="InputElement">

              <ElementMatchPath>/HTML/BODY/DIV/DIV[1]/DIV/FORM/DIV[1]/INPUT</ElementMatchPath>

            </InputElement>

            <ButtonElement name="u_sn" type="ButtonElement">

              <ElementMatchPath>/HTML/BODY/DIV/DIV[1]/DIV/FORM/DIV[3]/BUTTON</ElementMatchPath>

            </ButtonElement>

          </Controls>

        </DataDrivenAdapterBindings>

      </DataDrivenAdapterBindingsCollection>

    </initstring>



    2) Automation Workflow 
       
              
        


    I have hardcoded the username and password in SetCOntrolValue.It working fine. It automatically logged in to the application based on hardcoded credentials.

         Now i want to pass the values of username and password in SetCOntrolValue dynamically.
          Whenever the Hosted application opening in the USD     

      1) Retrieve the credentials from External Database table (or XML file) based on the USD hostedapplication name and  USD User. That External table columns are Hosted 

    application Name, Username, Password, USD User Detail.
      2) Pass the retrieved values in SetControlValue of username and password for Hosted control HAT automation.
       
      How to achieve this? Is this possible to achieve this using HAT DDA automation?

    • Edited by Gugan A Thursday, February 26, 2015 7:05 AM
    Thursday, February 26, 2015 7:04 AM