Announcement

Collapse
No announcement yet.

Rotating desktop

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Rotating desktop

    I've seen someone with code to rotate your pictures on your desktop -
    I've got about 10 digital drawings from a guy that passed away, old aircraft pics, like to rotate them.....(Glenn Angus pics)...

    If someone has a program that is reliable home-brewed or not a commercial spyware infested app I'd be highly interested!!!

    Source would be good too.

    Thanks,
    Scott Turchin
    MCSE, MCP+I
    http://www.tngbbs.com
    ----------------------
    True Karate-do is this: that in daily life, one's mind and body be trained and developed in a spirit of humility; and that in critical times, one be devoted utterly to the cause of justice. -Gichin Funakoshi

  • #2
    I did a yahoo search for 'rotating desktop' and the first thing that came up was desktop jiggler. Though it doesnt appear to supply source code it is, i believe, freeware.
    Client Writeup for the CPA

    buffs.proboards2.com

    Links Page

    Comment


    • #3
      Originally posted by Scott Turchin View Post
      ...code to rotate pictures...
      Another job for GDIplus.

      Comment


      • #4
        Scott,
        if it's only for 10 images then just open the folder with the pictures in and right click in the image. There is usually an option in that menu to rotate the image.

        If that's not there, just open the image in Paint. Then rotate it using Image/Flip-Rotate.

        Paul.

        Comment


        • #5
          I think in this case "Rotate" really means (Every so often, change my background), not "Rotate the angle of the picture"
          Engineer's Motto: If it aint broke take it apart and fix it

          "If at 1st you don't succeed... call it version 1.0"

          "Half of Programming is coding"....."The other 90% is DEBUGGING"

          "Document my code????" .... "WHYYY??? do you think they call it CODE? "

          Comment


          • #6
            I think the "Windows Picture & Fax Viewer" that comes with XP will do what you want. It's usually an option under OPEN when you right click. It will both rotate images by 90 degrees and rotate (slide show) through a series of images in a directory.

            Comment


            • #7
              Yes rotate in and out of being my desktop picture - I can rotate a picture in paint shop pro or adobe photoshop

              I thought there was a call to refresh desktop???

              I know where WIndows stores the BMP it uses if you call from MSIE - replacing that picture and refreshing the desktop should do it...
              Scott Turchin
              MCSE, MCP+I
              http://www.tngbbs.com
              ----------------------
              True Karate-do is this: that in daily life, one's mind and body be trained and developed in a spirit of humility; and that in critical times, one be devoted utterly to the cause of justice. -Gichin Funakoshi

              Comment


              • #8
                Scott,
                Here is one that is VB and Icons, but the general concept should be the same
                Create Desktop Shortcuts &
                Refresh the Desktop
                Engineer's Motto: If it aint broke take it apart and fix it

                "If at 1st you don't succeed... call it version 1.0"

                "Half of Programming is coding"....."The other 90% is DEBUGGING"

                "Document my code????" .... "WHYYY??? do you think they call it CODE? "

                Comment


                • #9
                  Since you are talking about changing the wallpaper, take a peek at my source code at: http://www.powerbasic.com/support/pb...ad.php?t=30746 . You should be able to modify it to suit your particulars.

                  However, you should be informed that changing the wall paper ever-so-often will cause the screen to flicker briefly. This may cause some distraction.
                  http://www.powerbasic.com/support/pb...ad.php?t=30715
                  Last edited by Mel Bishop; 22 Oct 2008, 09:38 AM.
                  There are no atheists in a fox hole or the morning of a math test.
                  If my flag offends you, I'll help you pack.

                  Comment


                  • #10
                    The ones I have seen change the page from left to right and/or top to bottom
                    without flicker like you can do with html.
                    Client Writeup for the CPA

                    buffs.proboards2.com

                    Links Page

                    Comment


                    • #11
                      And the winner is...
                      Mel -


                      Thanks- works like a champ, I just built an app that holds 10 pics, customizable timer, help-about, the works, in 1 hr...

                      I'll post a linkto this freeware app when I get home from Karate 2nite..

                      Code:
                      Function SwitchDeskTopImage(ByVal DeskTopImage As String) As Long
                      If IsFalse Exist(ByVal DeskTopImage) Then Exit Function
                      Function = SystemParametersInfo(%SPI_SETDESKWALLPAPER, 0, ByVal StrPtr(DeskTopImage),0)
                      End Function
                      Scott Turchin
                      MCSE, MCP+I
                      http://www.tngbbs.com
                      ----------------------
                      True Karate-do is this: that in daily life, one's mind and body be trained and developed in a spirit of humility; and that in critical times, one be devoted utterly to the cause of justice. -Gichin Funakoshi

                      Comment


                      • #12
                        Thanks. I look forward to getting my prize.

                        I would have posted earlier except I thought you were talking about physically rotating an image, much like a screen saver would do.
                        There are no atheists in a fox hole or the morning of a math test.
                        If my flag offends you, I'll help you pack.

                        Comment


                        • #13
                          Thanks. I look forward to getting my prize.

                          I would have posted earlier except I thought you were talking about physically rotating an image, much like a screen saver would do.
                          *LOL* I thought that was the case Mel, and if posted how I read the post would help

                          Too little time to investigate, and know full well that many of you PB'ers out there have from time to time investigated/answered/solutioned a similar concept and hoped someone would notice.

                          I look forward to what Scott posts as to what worked well for his application
                          Engineer's Motto: If it aint broke take it apart and fix it

                          "If at 1st you don't succeed... call it version 1.0"

                          "Half of Programming is coding"....."The other 90% is DEBUGGING"

                          "Document my code????" .... "WHYYY??? do you think they call it CODE? "

                          Comment


                          • #14
                            Strange thing is, this code works at work but not at home.

                            Home is XP SP3 but work is SP2 I believe, might be SP3 now...

                            No go at home....if I right click REFRESH the desktop, works fine.

                            Code:
                            Function SwitchDeskTopImage(ByVal hWnd As Long,ByVal DeskTopImage As String) As Long
                            Local lResult   As Long
                            Local lRet      As Long
                            Local ErrType   As Long
                            Local zTmp      As Asciiz * %MAX_PATH
                            
                            If IsFalse Exist(ByVal DeskTopImage) Then Exit Function
                            
                            'Find out if screensaver is running:
                            lResult = SystemParametersInfo(%SPI_GETSCREENSAVERRUNNING,0,lRet,0)
                            If IsTrue lRet Then Exit Function 'No sense switching if screesaver is on.
                            
                            'Set new image
                            'If the function succeeds, the return value is a nonzero value.
                            'If the function fails, the return value is zero.
                            lResult = SystemParametersInfo(%SPI_SETDESKWALLPAPER, 0, ByVal StrPtr(DeskTopImage),%TRUE)
                            If IsFalse lResult Then 'Function failed
                                ErrType = GetLastError()
                                MessageBox ByVal hWnd, GetLastErrorDescription(ErrType), ByVal VarPtr(CCSDesktop.szMine), ByVal %MB_ICONSTOP
                            End If
                            Function = lResult
                            End Function
                            Scott Turchin
                            MCSE, MCP+I
                            http://www.tngbbs.com
                            ----------------------
                            True Karate-do is this: that in daily life, one's mind and body be trained and developed in a spirit of humility; and that in critical times, one be devoted utterly to the cause of justice. -Gichin Funakoshi

                            Comment


                            • #15
                              Can I get someone to test this on an XP SP3 machine?

                              Or even SP2??

                              Works FLAWLESSLY on my XP machine at work, and flawlessly here on a Windows 2003 server.

                              I put a timer in for 1 minute and run this.

                              Code:
                              '==========================================================================================
                              Function SwitchDeskTopImage(ByVal hWnd As Long,ByVal DeskTopImage As String) As Long
                              Local lResult   As Long
                              Local lRet      As Long
                              Local ErrType   As Long
                              Local zTmp      As Asciiz * %MAX_PATH
                              Local iPathID   As Long
                              Local pvReserved As Long
                              
                              If IsFalse Exist(ByVal DeskTopImage) Then Exit Function
                              'Find out if screensaver is running:
                              lResult = SystemParametersInfo(%SPI_GETSCREENSAVERRUNNING,0,lRet,0)
                              If IsTrue lRet Then Exit Function 'No sense switching if screesaver is on.
                              
                              'Set new image
                              'If the function succeeds, the return value is a nonzero value.
                              'If the function fails, the return value is zero.
                              lResult = SystemParametersInfo(%SPI_SETDESKWALLPAPER, 0, ByVal StrPtr(DeskTopImage),0)
                              If IsFalse lResult Then 'Function failed
                                  ErrType = GetLastError()
                                  If ErrType <> %ERROR_SUCCESS Then MessageBox ByVal hWnd, GetLastErrorDescription(ErrType), ByVal VarPtr(CCSDesktop.szMine), ByVal %MB_ICONSTOP
                                  Exit Function
                              End If
                              '%SHCNF_PATH
                              
                              CoInitializeEx pvReserved,%COINIT_APARTMENTTHREADED
                              lResult = SHGetDesktopFolder(iPathID)
                              If Not IsFalse lResult Then 'Function failed
                                  ErrType = GetLastError()
                                  If ErrType <> %ERROR_SUCCESS Then MessageBox ByVal hWnd, GetLastErrorDescription(ErrType), ByVal VarPtr(CCSDesktop.szMine), ByVal %MB_ICONSTOP
                                  Exit Function
                              End If
                              
                              Call SHChangeNotify(%SHCNE_ALLEVENTS, %SHCNF_IDLIST, ByVal iPathID, ByVal lRet)
                              CoUninitialize
                              Function = lResult
                              'SHChangeNotify %SHCNE_ALLEVENTS, %SHCNF_FLUSH, ByVal 0, ByVal 0
                              'Call SHChangeNotify(%SHCNE_ALLEVENTS, %SHCNF_IDLIST, iPathID, lRet)
                              'Call CoTaskMemFree(iPathID)                  'free allocated memory
                              'Free bi
                              End Function
                              Scott Turchin
                              MCSE, MCP+I
                              http://www.tngbbs.com
                              ----------------------
                              True Karate-do is this: that in daily life, one's mind and body be trained and developed in a spirit of humility; and that in critical times, one be devoted utterly to the cause of justice. -Gichin Funakoshi

                              Comment

                              Working...
                              X