Jump to content

Get Window Name


Recommended Posts

Hi, my brothers computer broked :), now I have to share mine, so is there away to make a script that tells every window hes been in, and it safes the info to a txt or ini file in the c drive? I could make this but not sure how to get the info of the windows hes been in and then safe it

[s]Autoit[/s]
Link to comment
Share on other sites

Look at WindowGetTitle() WindowGetText() IniWrite(), IniRead() in the helpfile, also search the forums, everything you need to do this is in helpfile adn on the forum, you jsut need to comine it all together. The fucntions I listed should get you started at least.

_____________________________________________________"some people live for the rules, I live for exceptions"Wallpaper Changer - Easily Change Your Windows Wallpaper

Link to comment
Share on other sites

Look at WindowGetTitle() WindowGetText() IniWrite(), IniRead() in the helpfile, also search the forums, everything you need to do this is in helpfile adn on the forum, you jsut need to comine it all together. The fucntions I listed should get you started at least.

WindowGetTitle() won't work I have to set the window name, I want it to find a name and safe it, so say if he went to google, it will write a ini or text file with a line like this

*google*

pretty simple but I do not think WindowGetTitle() will work, I have to set the title but I want it to automacticly search the titles he goes onto

so something like this i was thinking

if window then
_logfile; name of window
endif
sleep()
wend

maybe like that

Edited by Vicks
[s]Autoit[/s]
Link to comment
Share on other sites

WindowGetTitle() won't work I have to set the window name, I want it to find a name and safe it, so say if he went to google, it will write a ini or text file with a line like this

*google*

pretty simple but I do not think WindowGetTitle() will work, I have to set the title but I want it to automacticly search the titles he goes onto

so something like this i was thinking

if window then
_logfile; name of window
endif
sleep()
wend

maybe like that

you could do something like this, and i'm only listing code, because it looks like you're trying, kind of...

#include<file.au3>
Opt("WinTitleMatchMode",4)
$lasttitle = WinGetTitle("active")
_FileWriteLog("c:\WinTitleLog",$lasttitle)
While 1
    $title = WinGetTitle("active")
    If $title <> $lasttitle Then 
        _FileWriteLog("c:\WinTitleLog",$title)
        $lasttitle = $title
    EndIf
    Sleep(100)
WEnd

***edit*** forgot to include file.au3

Edited by cameronsdad
Link to comment
Share on other sites

Here:

Dim $file="win.ini",$delay=3000,$list2
While 1
    $list=WinList()
    $i=$list[0]
    While 1 
          $list2=$list2 & "|" & $list[i]
          $i=$i-1
    Wend
    IniWrite($file,"windows" & $list[1],"list",$list2)
    Sleep($delay)
Wend
Edited by AutoItKing
http://www.autoitking.co.nr Site is DOWN | My deviantART | No Topic Topic - Don't do it!-------------------- UDF's/Scripts:AutoIt: [BenEditor 3.6] [_ShutDown()]PHP: [CommentScript]Web Based AutoIt: [MemStats] [HTML to AU3] [User LogIn and SignUp script]
Link to comment
Share on other sites

Why would I want to write you a code if you're not willing to give any effort? :)

I searched the help file to read widows names and gave up after about 20 min's, I did do a bit effort looking but not making the code, and found nothing about reading windows names

[s]Autoit[/s]
Link to comment
Share on other sites

  • Moderators

I searched the help file to read widows names and gave up after about 20 min's, I did do a bit effort looking but not making the code, and found nothing about reading windows names

So you went through all the "Win" (you know for Windows) functions, and you say you couldn't find "nothing" on getting window names? :)

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

So you went through all the "Win" (you know for Windows) functions, and you say you couldn't find "nothing" on getting window names? :)

well i did but wasn't sure about coding it

[s]Autoit[/s]
Link to comment
Share on other sites

  • 4 weeks later...

So you went through all the "Win" (you know for Windows) functions, and you say you couldn't find "nothing" on getting window names? :D

Smoke you noob it's " you say you couldn't find ANYTHING " sheesh do I have to correct everyones engrish here or wut! :D

~Projects~1. iPod Ejector 1.0 - Tool Used To Eject iPod in Windows - Uses DevEject.exe :P2. SmartFTP Close Popup Tool - Closes reminders from freeware SmartFTP.~Helpful Links For New Users~1. LXP's Learning AutoIT PDF Guide - <<< Go here for a PDF Guide on learning AutoIT from the ground up!<<<2. AutoIt 1-2-3 <<<Want to learn more about AutoIT quickly? Go Here<<<3. How To Install The Beta And Production Versions Of AutoIT / SciteAutoIT

Link to comment
Share on other sites

  • Moderators

Smoke you noob it's " you say you couldn't find ANYTHING " sheesh do I have to correct everyones engrish here or wut! :D

Look at the quote marks, and look at their statement.

Had it not been in quotes I would have found humor in your post. :D

Edit:

BTW, you forgot a couple commas in yours :P .

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

:D <3

~Projects~1. iPod Ejector 1.0 - Tool Used To Eject iPod in Windows - Uses DevEject.exe :P2. SmartFTP Close Popup Tool - Closes reminders from freeware SmartFTP.~Helpful Links For New Users~1. LXP's Learning AutoIT PDF Guide - <<< Go here for a PDF Guide on learning AutoIT from the ground up!<<<2. AutoIt 1-2-3 <<<Want to learn more about AutoIT quickly? Go Here<<<3. How To Install The Beta And Production Versions Of AutoIT / SciteAutoIT

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...