Jump to content
Daka

screen 1024x768 different screen size, how can this be possible?

Recommended Posts

Daka

Ok I have the software and I made the autoit program for it.
In the program I check if there is screen resolution 1024x768
and if it is proceed, but then I came a cross computer that has 
screen resolution 1024x768 and it passes the if statment,
but when I open that software for which I made autoit program
it is very different with buttons and all software is different so as the x an y positions.

I thought  1024x768 is 1024x768 resolution on each computer :(

Share this post


Link to post
Share on other sites
Jos

Maybe it would help to share the code where you are doing the test that isn't working, because your story doesn't make too much sense yet?

Jos

 


Visit the SciTE4AutoIt3 Download page for the latest versions  - Beta files                                How to post scriptsource        Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites
Daka

code is working perfect, but the screen on only that computer don't work :( and it has the resolution of 1024x768
 

$aClientSize = WinGetClientSize("[CLASS:TFormEtalon2]")
   ;MsgBox($MB_SYSTEMMODAL, "", "Width: " & $aClientSize[0] & @CRLF & "Height: " & $aClientSize[1])
   ;ConsoleWrite($aClientSize[0] & "x" & $aClientSize[1] & @LF)
   If Not ($aClientSize[0] = 1024 AND $aClientSize[1] = 768) Then
      ;WinClose("clientWindow")
      MsgBox(0,"Resolution","Please change your Windows screen resolution 1024x768 in order for this to work.Then run it again.")
      Exit
   EndIf

When I run this code on that computer it proceeds the if statement :(
and on that windows it state 1024x768
So maybe someone knows this issue or where can be the issue?
I'm right now not on that windows machine, but as soon I go with teamviewer I will make some screenshots

Share this post


Link to post
Share on other sites
JLogan3o13

The short answer to your question is no. 1920x1080 on my laptop looks far different than 1920x1080 on my Dell monitor.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
Share on other sites
Daka

ok thanks JLogan2o13, how the people make solution for this? 
How can I check the system so it goes to 1024x768 like on my computer?
I think I'm not only one with this problem,
maybe there is already some library (class) to achieve this?

Because the problem is that the software is then wider on that 1024x768 laptop machine
and on my own 1024x768 machine.

Edited by Daka

Share this post


Link to post
Share on other sites
Earthshine

back in the VB6 days, I wrote a function that auto resized stuff. I mean you want limits to the control sizes, don't let them get giant or too small. this is why i never write software that is display resolution dependent

 

maybe this will help.

 

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Daka

but what should be then solution for me?
Because many of things on that software 
I really need to go with with x and y position
there is no way to go on instances id :(

Share this post


Link to post
Share on other sites
Earthshine

you need to flesh out your question. i don't even know what you are trying to do. did you develop something to run at that resolution or are you testing someone else's software?

Screenshots are worth 1000 words or more, details are VERY important.

just thought of something, if you can make it run on a client machine, that software that needs to run at specific video settings, if it could just run in a window that size and you figure out where the app is, you might be able to calculate the x/y offsets.

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

also, I posted this above. I think you need to do this. I did this in the ancient Visual Basic days. make your app resolution independent. forcing a ridiculously SMALL video option on a user is unreasonable at best. I would not even run software like that dude. been doing this since the 90's, time to step it up. that's your solution.

 

I've got HUGE monitors. if you think I am going to go non-native resolution, you've got another thing coming. if you forced me to use this in a corporate environment I would not do it even.

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

one more parting thought. if you can't talk natively to the the controls, you are not using the right tool set. 

rule 1) Never write resolution dependent applications OR tests

rule 2) Never rely on x/y or any resolution

rule 3) if you can't talk to your controls through IDs and such, get a different tool. (TestComplete, Visual Studio Enterprise using Coded UI projects, etc..) 

violate any of those rules and you will be extremely unhappy

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

i installed koda and generated an auto it form. i will make it resize and post back with some sample code. koda can help you lay out your forms, then you can add resizing stuff, UDF calls that is.


My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Daka

WOW Earthshine, so I cant rely on any resolution, huh.

But as I understand the info tool that comes with autoit is only thing I have
and really many things I can't find with that tool,
even some buttons have no information,

Here under I uploaded photo where you can see what program it is,
in the right corner it is autoit program that clicks on the program 
so I don't need to click it all the time.

But many links and buttons I can't even see the id of it,
info tool dont give me much information :( acctually nothing.
I have no idea with what language is the software made,
to try to see what is the id of button or something else :(

Are there other options for this to see the id's of windows program that I have no idea how it is written or what programming language it is, besides info tool of autoit?
 
 

Screen Shot 2017-11-07 at 8.20.44 PM.png

Share this post


Link to post
Share on other sites
Earthshine

maybe this will help out. when you make the autoit form sizable, it can auto resize stuff built in. this sample can LIMIT the amount the AutoIt Form can be resized so you can possibly fit it.

https://www.autoitscript.com/wiki/Snippets_(_GUI_)#Limit_GUI_Resize

 

I copied the code and ran it, when you try to resize it it limits it, you could do this possibly with your forms? limit them to small forms so you can determine your XY coords.

  • Like 1

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

Do you have access to Windows SDK's, you can download many. It comes with a gem I love called inspect.exe, one for your platform is included. that is a wonderful tool that can see almost any control.

 

Also, the .NET CLR stuff developed by people here can help as many apps are now .NET based using Winforms or WPF

 

  • Like 1

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

here is a free inspection tool for you, get it off GitHub

https://github.com/blackrosezy/gui-inspect-tool

this is a BUNCH of free stuff, including Inspect.exe. lots of tools there.

Edited by Earthshine
  • Like 1

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Daka

WOW Earthshine thank you very much to give me view that there are more options then info tool of autoit, I will try that, because on id there is no resolution needed :)

Share this post


Link to post
Share on other sites
Daka

I was never developer for any desktop application,
maybe you know more,
so lets say this is written with java, then
the info tool should be java oriented?
Or it doesn't matter because the source code is 
converted to the machine language?

Share this post


Link to post
Share on other sites
Earthshine

Let me do some digging around I think there may be issues with Java controls but I’m not sure. I know that commercial products like test complete can handle it

Look here. You may want to look at Abbot

 

https://java-source.net/open-source/testing-tools

Edited by Earthshine

My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
Earthshine

Let me do some digging around I think there may be issues with Java controls but I’m not sure. I know that commercial products like test complete can handle it

 

https://java-source.net/open-source/testing-tools


My resources are limited. You must ask the right questions

 

Share this post


Link to post
Share on other sites
JLogan3o13

Moving this, as it really has nothing to do with deploying Operating Systems.


√-1 2^3 ∑ π, and it was delicious!

Share this post


Link to post
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

×