Intellipaat Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in BI by (11.1k points)
How can I activate Power BI Full screen mode in edge using  Power Shell

1 Answer

0 votes
by (22.5k points)
edited by

Follow the code below:

//Open IE Browser
$IE=new-object -com internetexplorer.application
//navigate the website.
$IE.navigate2("website url")
$IE.visible=$true

//Open IE in Fullscreen
$IE.FullScreen = $true

// find the hyperlink 
$fs = $IE.document.getElementsByClassName('glyphicon glyph-small pbi-glyph-fullscreen') | Select-Object -First 1

//click the button to open the powerbi report
$fs.click()
   /*
    * This assumes you have added MicrosoftWebDriver.exe to your System Path.
    * For help on adding an exe to your System Path, please see:
    * https://msdn.microsoft.com/en-us/library/office/ee537574(v=office.14).aspx
    */
    static void Main(string[] args)
    {
        /* You can find the latest version of Microsoft WebDriver here:
        * https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/
        */
        var driver = new EdgeDriver();

        // Navigate to Bing
        driver.Url = "https://www.bing.com/";

        // Find the search box and query for webdriver
        var element = driver.FindElementById("sb_form_q");

        element.SendKeys("webdriver");
        element.SendKeys(Keys.Enter);

        Console.ReadLine();
        driver.Quit(); 

    } 

Learn Power BI and become a  Power BI Developer!

Thinking of learning Power BI? Here is the opportunity provided by Intellipaat to earn a certification in Power BI Course!

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Nov 29, 2020 in BI by Chris (11.1k points)
0 votes
1 answer
asked Feb 28, 2021 in BI by dev_sk2311 (45k points)

31k questions

32.8k answers

501 comments

693 users

Browse Categories

...