Programmatically change screen orientation and/or resolution?

We don't have VB.NET available and I was wondering if it is possible to create VBA code that would change:
1) screen orientation (and maybe resolution)
2) on a specific monitor (in a multiple monitor setup; we have two) 
The idea would be to put it into an Excel workbook and have the macro autorun then exit.
I see examples for C#.Net but can't find any for VBA. Maybe it's not possible. Your comments are appreciated. Thanks.
Edit: ANY MS Office application can be used as long as it can be used via a shortcut on the desktop and run automatically. "One click and done" is the idea.

Hello Doug,
I believe you can use Windows API functions to get the job done.
Anyway, the current forum is for Office Apps. I'd recommend asking VBA questions on the
General Office Development  forum instead.

Similar Messages

  • Programmatically change screen orientation and/or resolution using VBA?

    We don't have VB.NET available and I was wondering if it is possible to create VBA code that would change:
    1) screen orientation (and maybe resolution)
    2) on a specific monitor (in a multiple monitor setup; we have two) 
    The idea would be to put it into an Excel workbook and have the macro autorun then exit.
    I see examples for C#.Net but can't find any for VBA. Maybe it's not possible. Your comments are appreciated. Thanks.
    Note: ANY MS Office application can be used as long as it can be used via a shortcut on the desktop and run
    automatically. "One click and done" is the idea.

    Hi Dougmeister,
    I agree with Cindy that the VBA doesn't have function to achieve the goal. Also there is no function in Excel object for this requirement.
    The way we can achieve the goal is that using Windows API as Cindy motioned. And here is an helpful article talking about this topic:
    Office Talk: Working with VBA in the 32-bit and 64-bit Versions of Office 2010
    And about Windows API issue, I would suggest that you get more effective response from
    General Windows Desktop Development Issues forum.
    Hope it is helpful.
    Regards & Fei
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • Cat changed screen orientation from vertical to horizontal

    What key combination will reorient my display from horizontal back to vertical? Do you know someone who is looking for a cat. Ours is now looking for a new home.

    Here you go...
    http://www.dq.winsila.com/windows/windows-xp-tips/how-to-change-the-screen-orientation-in-windows-xp...
    Paul

  • How can I change screen orientation on my iPad air 2?

    How can I change the scrEen orientation on my new iPad Air 2? I do not see a lock device on the side like my old iPad has.

    Tap the padlock icon in Control Center.

  • Change screen orientation on nano

    How do you change orientation of screen on Nano 6th generation?

    Place two fingers such as your thumb and pointer finger in a pinch-like fashion on the Nano's screen and rotate them either clockwise or counterclockwise to rotate the display.
    B-rock

  • Portege M700 wont change screen orientation

    I installed the webcam driver for the M700 and each time I install it, I recieve the same error message:
    "Webcam driver open fail - Please restart camera or computer."
    I've reinstalled the drivers numerous times, and it still doesn't work.
    Therefore, I tried the msconfig method, and disabled all start up processes, and then reenabled them.
    The webcam displays the same error message, and now the screen wont change orientation when I swivel the screen.

    Regarding the error:
    *Webcam driver open fail - Please restart camera or computer*
    First of all please ensure that you are using the latest BIOS version.
    If not, update it.
    Furthermore access the BIOS settings and set it back to the default pressing the F9 button.
    Dont forget to save the changes if you would leave the BIOS.
    Additionally and webcam driver update would be advisable too
    Someone has posted this solution:
    +Shut down your computer and restart it, go to the boot screen should be F2 or F12, There is an option at the bottom of the screen that says something like load defaults or just defaults F9 on my system, Click yes to reloading defaults and save and exit, the camera should work fine after that.+
    Check it out

  • How to change screen icons and album art?

    Does anyone know of an application, or otherwise know how to change the screen icons individually, one at a time? I don't mean adding or changing to a different summerboard. Ideally, I'd like to change a few of the icons to either photographs from my files, or to some other photo or drawing of my choosing.
    While I'm asking questions, another one concerns album covers in iTunes. ITunes gives you the ability to add more than one cover to an album but I can't see how to display one other than the original one added. Also, I can't see how to delete a cover once it's been added. I was manually adding cover art for albums that didn't have any and accidently put the wrong picture on one album. Nothing I have been able to do allows me to delete that picture. I did add the correct picture but I can't get it to display. Of course, whatever I do in iTunes I'd like for it to properly sync to the touch.
    Any ideas???

    As for your first question, there is no way of changing icons without jailbraking, which we're not allowed to discuss here.
    To view more than one artwork, simply click on the little arrow appearing in the artwork window.
    To delete it, right-click, Get Info -> Artwork and delete the picture.
    Hope this helps.

  • N8 changes screen orientation to vertical on incom...

    I am using N8 in a car in horizontal position because of navigation. The phone is connected to car's hands-free audio device. Unfortunately, when a call is coming the phone changes its display to vertical which makes challenging to see who is calling while driving a car. Is it possible to change such weird behavior in some way?

    When i am in my car i connect the N8 to the cars audio using bluetooth. When a call comes in the name/number of the caller shows up on the car radios screen. No need to look at phone. So if you can pair your phone with your car radio (and that may not be possible - depends on how old your car or radio is) try that and see if it works. I do have two cars. On I can pair the phone to and the other i cannot. So i only have hands free in one car. And as talking on a mobile phone whilst driving is illegal in Australia  I only use my phone in the car that i can pair the phone to the radio. When phone rings i press a button on the sterring wheel to answer. Do not touch the phone.

  • Programmatically Changing Waveform Graph and the number of plots

    I have a waveform graph that needs to display a variable number of plots based on the number of inputs.  Is there a way to programmatically adjust the number of plots displayed on the waveform graph?

    You need to use the Active Plot input before the Plot Name(s).  Property nodes are read from top to bottom so you can alternate several pairs of ActPlot,Plot.Name;ActPlot,Plot.Name, etc.  Then wire 0,1,2,etc to the ActPlot and your chosen name to the Plot.Name right under it.  Or, use for loops and index the ActPlot input.  See the pic.
    Using LabVIEW: 7.1.1, 8.5.1 & 2013
    Attachments:
    plot names.JPG ‏37 KB

  • Programmatically changing x axis and reading y axis value of multiplot cursor on xy platform

    Hi Wonder if it is achievable. I had a go but failed!
    I cant create multiplot cursor xy graph from properties list. However it seems to be possible using cursor legend. Which is fine for my application as cursor could be created once and i do not require to show cursor legend. However, I do need to read each value of plot into numeric indicators (not cursor legend) especially when x scale is moved along the graph. Is it possible or am I asking too much?
    Best Regards
    K Waris

    Read the post just before this one! (Its mine, migth help you)

  • Screen Saver and Size of Background - Help, please!

    Hello there!
    I have a brand new Dell computer from Best Buy. With my last computer (Gateway), I was able to set up an automatic screen saver of a slideshow of pictures if my computer was not used for a certain amount of minutes.
    With this new computer, I have set up the same settings, but the screen saver NEVER comes on. I have clicked everything I need to, accepted, and saved the settings, but it never works. Any ideas?
    I decided to try and fix it myself, so I went into the Control Panel, Appearance and Personalization, Change Screen Saver, and then went into Power Settings to see if maybe the display wasn't working for this reason. I cannot remember what I did, but now the background picture is HUGE.
    To fix this, I have gone into screen resolution and display/power settings, but everything seems to be set to "recommended", so I cannot figure out what happened to make the images so large suddenly.
    1) Can you help me get the screen saver slideshow to activate?
    2) How do I get my background pictures back to normal size?
    Thank you so much for your help!!! I really appreciate it.
    Royce*****

    Wow, so sorry for the hype delayed response. it could be that your laptop was timing out for powersave before the screensaver would kick in. The best thing to do is go into your screen saver, set it to 1 minute and then let it sit for a minute without touching it (with it plugged in). It should kick in. Again, most laptops cut the monitor off after just a few minutes to conserve the power of the battery. I'm glad that the other solution worked for you =)
    “Computers have enabled people to make more mistakes faster than almost any invention in history, with the possible exception of tequila and hand guns” - Mitch Ratcliffe
    If my answer was helpful, please click the Kudos button so I know =)

  • PDFMaker changes page orientation when printing to pdf

    Hi all! I am praying for an answer. My job requires me to convert huge word documents to pdf using the pdfmaker add-in with acrobat Professional 8.1.3. My problem is as follows and has occured in two seperate documents. I have Microsoft word 2007 and run on a VIsta OS.
       So my problem is when I create a pdf from word acrobat for some odd reason changes any page's orientation that contain excel spreadsheets that have been inserted (I believe through copy and paste and they are not linked to excel). Thus I get a page with a landscape spreadsheet with a profile orientation and it cuts off the information for my client. By the way, it does the complete opposite of whatever orientation I choose.
       Here are some things I have tried: I tried saving document as a 97-2003 word file and create pdf from that version, I have changed the PDFmaker advanced settings for auto-rotate pages and tried all three options to no avail. I really need some help fast! I will love anyone who solves this problem for me.
    Thanks,
           Jason.

    GREAT NEWS!!! I FIGURED IT OUT!!!!
      Okay so after a lot of frustration and mountain dew I have figured this out, but first the problem is simpler then I listed it. So here is the actual problem:
    I had a document with multiple sections and one section was oriented landscape while the rest were profile. When printing to PDF the resulting pdf file had all sections in profile and ignored any change in orientation and cut off/cropped out elements of the pages I had in landscape orientation.
    SOLUTION:
    The solution to this problem is in two parts: 1) changing some print preview stuff in word, and 2) changing preferences in pdfmaker/acrobat ribbon.For this solution to actually work however you must have the landscaped sections sectioned off by inserting section breaks in word.
    Step 1) Go to the section where you document orientation is changed from the rest of the document. Press the office button (in 2007) and drag down to print>print preview. You will notice that your section has now reverted to profile. (Ah Ha!) Change the page orientation to landscape.
                "But wait, now my margins or elements are getting cut off" you say. Go to Page setup. Make sure that near the bottom it says "Apply to: This section"
                Now make it landscape and this changes the margins to also be landscape.
    Step 2) Click on your Acrobat tab and go to preferences. Under pdfmaker settings click advanced settings and as Bill and I have said change auto-rotate pages to individually.
    AND YOU ARE DONE!!!!!

  • Change refresh rates and resolution on another computer

    Hi, am i able to use a LAN cable from Computer A and connect to computer B then change B's refresh rates and resolution? for example from 800x600 to 1024x768 then change refresh rate from 60Hz to 75Hz. please advice thanks.

    Hi Trig,
    Thanks for your post and I hope your well today.
    There are two parts to this - in my mind:
    1. Changing Screen Resolution Programmatically From LabVIEW
    2. Use VI Server to remotely call a VI i.e. Computer A calling VI on Computer B which then runs the VI mentioned in 1. 
    1. 
    This link is a dev zone article which has code for programmatically changing the screen resolution
    http://zone.ni.com/devzone/cda/epd/p/id/1429
    Try it out. 
    2.
    VI Server
    The NI Example Finder contains some expamples for this.
    Building VI Server Applications
    http://zone.ni.com/reference/en-XX/help/371361E-01/lvconcepts/building_vi_server_applications/
    If you could provide more details, maybe versions of LabVIEW etc then maybe we can help you some more - have you got some code yet? And did you have any thoughts on how to do this?
    Another method I have consider is:
    Using a tool such that runs an exe or script which alters the resoltion.
    Then using the cmd (comand line) or in LabVIEW System Exec.vi to run the exe (via VI Server). 
    How To Change Your Screen Resolution From A Command Line
    http://desktopfeedbag.wordpress.com/2007/12/27/how-to-change-your-screen-resolution-from-a-command-line/
    Hope this helps, 
    Kind Regards
    James Hillman
    Applications Engineer 2008 to 2009 National Instruments UK & Ireland
    Loughborough University UK - 2006 to 2011
    Remember Kudos those who help!

  • How do I change the screen orientation on my lennovo yoga 13 while connected to hdmi?

    For some reason when I connect the HDMI to my projector the yoga goes to portrait view & I cant seem to  change it to landscape view.  Moving the yoga how it normally changes doesn't work, it just stays in the portrait view...im looking to watch movie's through the projector ..Please help!

    Hi penguin05,
    Welcome to Lenovo Community Forums!
       First without the projector connected
               Right click on your desktop screen and select "Screen Resolution"
                 you will get this page
    Spoiler (Highlight to read)
    Now Connect your projector and make sure that the display is now on your projector.
       under Display: Set it to your projector
                 -Change the Orientation: to Landscape View then hit Apply.
    Let me know your findings
    Regards
    Solid Cruver,
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"! This will help the rest of the Community with similar issues identify the verified solution and benefit from it.
    Follow @LenovoForums on Twitter!

  • For some reason changing my screen orientation changes some font sizes

    So when I use xrandr --rotate {orientation} to put my screen in portrait mode, then open a new application the font will be larger than usual. Example 1 (normal), Example 2 (larger). I think I know what the problem is, just not how to fix it. For some background, I'm running arch with the i3 windows manager. I've got a 24" screen with 1920x1200 resolution. Recently I uninstalled gnome, and after that is when I noticed the problems popping up.
    Here are some outputs:
    xdpyinfo (horizontal orientation)
    xdpyinfo | grep -E 'dimensions|resolution'
    dimensions: 1920x1200 pixels (508x317 millimeters)
    resolution: 96x96 dots per inch
    xdpyinfo (vertical orientation)
    xdpyinfo | grep -E 'dimensions|resolution'
    dimensions: 1200x1920 pixels (508x317 millimeters)
    resolution: 60x154 dots per inch
    xrandr (horizontal orientation)
    xrandr | grep -w connected
    HDMI1 connected 1920x1200+0+0 (normal left inverted right x axis y axis) 518mm x 324mm
    xrandr (vertical orientation)
    xrandr | grep -w connected
    HDMI1 connected 1200x1920+0+0 left (normal left inverted right x axis y axis) 518mm x 324mm
    It seems the big thing to note is that in landscape and portrait the dpi is different (96x96 vs 60x154). I think the reason for this is because in portrait the dpi calculation is dividing horizontal pixels by vertical screen length, instead of horizontal screen length and vice versa (I actually did the calculation myself to see if this was the case, and my numbers matched up).
    So I guess my question is, why is this happening, and what's the best way to go about fixing it? Also why does xdpyinfo show a different screen length than xrandr? (508x317mm vs 518x324) Xrandr is actually closer.
    Thanks!
    Last edited by CopOnTheRun (2014-06-01 21:15:38)

    A common mistake is to put code lines *after* the "exec startmyguiblah" line, and the exec command prevents any such further code from executing
    Your command is wrong - --dpi only accepts a single value
    Check with:
    xdpyinfo | grep -B1 dot
    Whereas --fbmm can change the DPI properly, since the DPI is 2 values - horizontal and vertical.
    Last edited by brebs (2014-06-01 21:45:23)

Maybe you are looking for

  • My itunes says that my ipod is synced with another library when it is not and cannot update or sync without wiping it and all its data

    My itunes says that my ipod is synced with another library when it is not and cannot update or sync without wiping it and all its data Can anyone help me

  • How to run swing applets???

    I already posed this question yesterday but i got no replies.please help me out. I understand it is a typical question and there lot of articles on it. I tried but am confused. I installed JRE1.3 which has java plug-in along with it which supports sw

  • Domains for Oracle object types

    When I create a domain for a certain Oracle object type there is no way to create some kind of inheritance tree (and there is no discriminator support it seems). On the database level I have several object types that extend a certain base object type

  • How to comple query to get correct results?

    Hello, I am having problems getting the results from a query.  I have 2 tables: Marriage table People1ID People2ID DateMarried 1 4 5/5/2014 5 7 6/5/2014 2 3 7/5/2014 People table PeopleID First Last 1 Bob Jones 2 Mary Smith 3 Steve Smith 4 Jane Jones

  • Your connection 1.1.1.1 is not private

    I have a cisco controller 2504.  We have guest internet plug into port 2 of the controller.  I have layer 3 web authentication set up in which guest see a web site and type a user name and password to get on the guest wireless internet.  However, whe