Jump to content

Mouse Movement and Copy & Pasting


Recommended Posts

Currently, I have reached an issue. I'm trying to copy these names and numbers then putting them into a text file. I'm currently using two monitors. I already figured out how to copy, then paste into a text file. I was using mouse movement (Move to a certain pixel), but I noticed some of the names were mismatched.

What I'm trying to copy is this: http://bans.i3d.net/index.php?p=banlist . You click on a name, then a whole bunch of info pops up, then I want it to copy the name of the user, and the Steam ID. I'd love for a script in which I go through each one, copying the two text (Just the name and Steam ID), then pasting it into a separate text file I have open on my 2nd monitor.

What I'd like to do is click a user, then highlight the name, copy it, then paste it into a txt file. Then it would go back to the page, highlight the steamid, copy it, then paste it into the text file again. It would continue down till the last user, then it would scroll back up and press the next button, then it would repeat itself.

It would look somewhat like this: http://puu.sh/hJWfC.mp4 , but with everyone on the page.

 

I guess a good way is making the mouse go like this (By color coding): http://puu.sh/hJWsz.mp4

I'd love for some help! :D

 

Link to comment
Share on other sites

You should rather try to parse the html file than doing it by mouse. With parsing the html you can avoid repeating this tedious task 3250 times and donate the multiple of software clicks to people in need.

This is one of the basic sliding panels:

<!-- ###############[ Start Sliding Panel ]################## -->
            <tr>
        <td colspan="7" align="center">
          <div class="opener"> 
                        <table width="80%" cellspacing="0" cellpadding="0" class="listtable">
              <tr>
                <td height="16" align="left" class="listtable_top" colspan="3">
                                    <b>Ban Details</b>            
                                </td>
              </tr>
              <tr align="left">
                <td width="20%" height="16" class="listtable_1">Player</td>
                <td height="16" class="listtable_1">
                                      Jaenas
                                  </td>
                <!-- ###############[ Start Admin Controls ]################## -->
                                <td width="30%" rowspan="11" class="listtable_2 opener">
                  <div class="ban-edit">
                    <ul>
                      <li><a href="#" onclick="" target="_self"><img src="images/demo.gif" border="0" alt="" style="vertical-align:middle" /> No Demos </a></li>
                    </ul>
                  </div>
                </td>
                                <!-- ###############[ End Admin Controls ]##################### -->
              </tr>
              <tr align="left">
                <td width="20%" height="16" class="listtable_1">Steam ID</td>
                <td height="16" class="listtable_1">
                                      STEAM_0:0:117472517
                                  </td>
              </tr>
                            <tr align="left">
                <td width="20%" height="16" class="listtable_1">Steam Community</td>
                <td height="16" class="listtable_1"><a href="http://steamcommunity.com/profiles/76561198195210762" target="_blank">76561198195210762</a></td>
              </tr>
                                          <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Invoked on</td>
                                <td height="16" class="listtable_1">09/05/2015 23:46</td>
                            </tr>
                            <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Banlength</td>
                                <td height="16" class="listtable_1">Permanent </td>
                            </tr>
                                                        <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Expires on</td>
                                <td height="16" class="listtable_1">
                                                                            <i><font color="#677882">Not applicable.</font></i>
                                                                    </td>
                            </tr>
                            <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Reason</td>
                                <td height="16" class="listtable_1">Ban evasion (FS)</td>
                            </tr>
                                                        <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Banned by Admin</td>
                                <td height="16" class="listtable_1">
                                                                            CONSOLE
                                                                    </td>
                            </tr>
                                                        <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Banned from</td>
                                <td height="16" class="listtable_1" id="ban_server_3603">
                                                                            Please Wait...
                                                                    </td>
                            </tr>
                            <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Total Bans</td>
                                <td height="16" class="listtable_1">No previous bans</td>
                            </tr>
                            <tr align="left">
                                <td width="20%" height="16" class="listtable_1">Blocked (0)</td>
                                <td height="16" class="listtable_1">
                                                                    <i><font color="#677882">never</font></i>
                                                                </td>
                            </tr>
                                                    </table>    
                    </div>
                </td>
            </tr>
            <!-- ###############[ End Sliding Panel ]################## -->

It looks like alot but the goal is simple. You want to filter the Player and the Steam ID. This is just a big string that you can read and strip down to the key parts.

So you want to find the fixed patters that encloses that information and then separate it from the important stuff.

Take a look into the String management section in the autoit help file.

 

If you can write a script that returns the Steam ID from following segment I will post the script that scraps all player names and Steam IDs directly from the website to a text file:

<td width="20%" height="16" class="listtable_1">Steam ID</td>
                <td height="16" class="listtable_1">
                                      STEAM_0:0:117472517
                                  </td>

 

To help you start:

Save the segment above to a new .txt document (call it segment.txt), create a new autoit file next to it. Now the following code will enable you to work with the segment.

Local $hFile = FileOpen(segment.txt)
Local $RawString = FileRead($hFile)
FileClose($hFile)

; Now you can start working with $RawString

 

Edited by bootybay
Link to comment
Share on other sites

You should rather try to parse the html file. Then doing it by mouse. With parsing the html you can avoid repeating this tedious task 3250 times and donate the multiple of software clicks to people in need.

rofl-3e.gif That was the best joke I've heard in some time :)

But instead of manually parsing, the _IE* functions are probably a better way to go.

Roses are FF0000, violets are 0000FF... All my base are belong to you.

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...