Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Need way to get URI of Foreground Window.
Forum Updated to NodeBB v4.3 + New Features

Need way to get URI of Foreground Window.

Scheduled Pinned Locked Moved General and Desktop
4 Posts 2 Posters 852 Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • mannclearyM Offline
    mannclearyM Offline
    manncleary
    wrote on last edited by
    #1

    I'm able to get the window title (using the following) but need a way to get the URI of the Foregound Window.

     TCHAR wnd_title[256];
     HWND hwnd=GetForegroundWindow(); // get handle of currently active window
     GetWindowText(hwnd,wnd_title,sizeof(wnd_title));
     QString retVal = QString::fromUtf16((ushort*)wnd_title);
     return retVal;
    
    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      hi and welcome
      what URi?

      mannclearyM 1 Reply Last reply
      0
      • mrjjM mrjj

        hi and welcome
        what URi?

        mannclearyM Offline
        mannclearyM Offline
        manncleary
        wrote on last edited by
        #3

        @mrjj The URi associated with the Foreground Window. I'm getting the window title, but need a way to get the URi. Thanks.

        mrjjM 1 Reply Last reply
        0
        • mannclearyM manncleary

          @mrjj The URi associated with the Foreground Window. I'm getting the window title, but need a way to get the URi. Thanks.

          mrjjM Offline
          mrjjM Offline
          mrjj
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @manncleary
          what window are you talking about?

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved