Close
Showing results 1 to 10 of 10

Hybrid View

  1. #1

    Default

    I don't face this error using the <SetForegroundWin> only for the first window, but when I use the code with <SeForegroundWin> after each window target it does cause that error... Let me know if this works for you as worked for me

    *Resize for 1920x1080p monitor and five accounts
    Code:
    <Command ResizeAndPosition>
       <TargetWin %2%>
          <SetWinRect 1280 0 640 360>
         <UpdateWin>  
       <TargetWin %3%>
          <SetWinRect 1280 360 640 360>  
         <UpdateWin>   
       <TargetWin %4%>
          <SetWinRect 1280 720 640 360>
         <UpdateWin>
       <TargetWin %5%>
          <SetWinRect 640 720 640 360>
         <UpdateWin>
       <TargetWin %1%>
          <SetWinRect 0 0 1280 720>
             <SetForegroundWin>
         <UpdateWin>
    Last edited by muldorante : 07-21-2019 at 05:42 AM Reason: Missing information

  2. #2

    Default

    Thank you for the response! I played around a bit with the solution you recommended and found that the errors were happening less frequently, but were still occurring. In my case, I'm toggling between 3 accounts as opposed to your 5 accounts. I started to wonder whether the time needed to resize 5 windows introduced a delay long enough to avoid the errors. Incidentally, another symptom I noticed was when errors occurred I could hear 2 soundtracks playing on top of one another.

    I started to wonder whether there was a timing issue involved between switching focus to the desired window and syncing up the hidden window, which might be responsible for playing the soundtrack.

    I introduced a delay to see if it helped matters and it eliminated the errors I was experiencing. Here was the original setup that failed roughly half the time:

    Code:
    // -- run this first
    <Hotkey ScrollLockOn Ctrl F12>
        <SendPC local>
            <RenameWin "World of Warcraft" hidden-wow-1> 
            <RenameWin "World of Warcraft" hidden-wow-2> 
            <RenameWin "World of Warcraft" hidden-wow-3> 
            
    // -- run this second
    <Hotkey ScrollLockOn Shift Ctrl F12>
        <SendPC local>
            <RenameWin "World of Warcraft" wow1> 
            <RenameWin "World of Warcraft" wow2>
            <RenameWin "World of Warcraft" wow3>
    
    
    <Hotkey ScrollLockOn Shift Ctrl F11>
       <SendPC local>
            <ToggleWin wow1 wow2 wow3>
    I introduced a delay in my own version of ToggleWin:

    Code:
    // -- run this first
    <Hotkey ScrollLockOn Ctrl F12>
        <SendPC local>
            <RenameWin "World of Warcraft" hidden-wow-1> 
            <RenameWin "World of Warcraft" hidden-wow-2> 
            <RenameWin "World of Warcraft" hidden-wow-3> 
            
    // -- run this second
    <Hotkey ScrollLockOn Shift Ctrl F12>
        <SendPC local>
            <RenameWin "World of Warcraft" wow1> 
            <RenameWin "World of Warcraft" wow2>
            <RenameWin "World of Warcraft" wow3>
                
    <Command DelayedToggleWin>
        <SendPC local>
            <TargetWin %1%>
                <wait 100>        
                <SetForegroundWin>
                <UpdateWin>
    
    <Hotkey ScrollLockOn Shift Ctrl F11>
        <If ActiveWinIs wow1>
            <DelayedToggleWin wow2>
        <Else If ActiveWinIs wow2>
            <DelayedToggleWin wow3>
        <Else>
            <DelayedToggleWin wow1>
    So far, this seems to work for me without errors. After some experimentation, I settled on a wait time of 100ms (note the <wait 100> command) and no longer saw errors. I will say that adjusting the wait to be lower started to result in errors again, so it's possible you'll need to adjust this number based on your own setup.

    Note that this is working for my use case: 3 accounts running on a single computer. Hopefully this will be helpful to others experiencing this issue.

    Update:
    After playing with this config for a few hours, I'm still seeing issues. The errors are happening much less frequently, but they are still happening. Please share if you have other ideas on this issue. Thanks!
    Last edited by raikodin : 08-07-2019 at 10:42 AM

Posting Rules

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •