Hey Naterlarsen, looks like you are new to the forums so Welcome!

Just for future posts you can use code blocks to format your code so that it is 
easier for people to read your code to help you out. You can use three back 
ticks and then the short name of the language to do so like

```nim

your code

```

for your problem it is because GetWindowRect is a function that doesn't return 
the rect that you want. It returns a bool which tells you if the func was 
successful. lpRect is the param where the func saves the rect so you will need 
to do something like
    
    
    let window = FindWindow("Window Title", nil)
    var lpRect: LPRECT
    if (GetWindowRect(window, lpRect) == false):
        echo "failed to get window"
        return # quit the application
    echo lpRect
    
    
    Run

Reply via email to