04-16-2010 05:17 AM
I have an anoying problem. My graphincs card is $#!£. Everythime I restart my work laptop I have to reset the screen resolution settings.
Does anyone know:
1) How to Set the display resolution of Windows thriugh LabVIEW?
2) How to select the output device (Monitor, laptop, Laptop & monitor)?
3) How to detect the output device?
I need a better machine, I can't have one, so I need to create a VI to make my life easier.
Cheers
James
04-19-2010 05:05 AM - edited 04-19-2010 05:06 AM
Hi James W,
Thank you for contacting National Instruments. Regarding your query, I think you're going to need to look at the Windows API for most of the details on how to do what you want to do. So far, I have found the following details:
1. There is a registry Key that stores the screen resolution, it is located here
HKEY_CURRENT_CONFIG>>System>>CurrentControlSet>>Control>>Video and then drill down from here (I think the large hex value changes between machines).
I can't recommend changing your registry without first backing everything up. You can use the registry VIs within LabVIEW to make this change.
2. I am not sure, I think you will probably need to call some part of the Windows API. I would recommend having a look at MSDN to track this one down.
3. Again, I am not sure. Once you have found the corresponding DLL/Registry Key, you will be able to call them and access them through LabVIEW.
I hope this helps,
Many thanks,
04-19-2010 06:56 AM
Thanks Andrew,
I was hoping someone might have done this before.
As:
1) the values may change between machines
2) it requires messing with the registry. (Big no no for me)
I won't be trying this. but thanks for the pointers.
James