New topic: ProxyIcon
<http://forums.realsoftware.com/viewtopic.php?t=29369> Page 1 of 1 [ 4 posts ] Previous topic | Next topic Author Message DaveS Post subject: ProxyIconPosted: Mon Aug 03, 2009 8:42 pm Joined: Sun Aug 05, 2007 10:46 am Posts: 1359 Location: San Diego, CA I have successfully implemented many of the Mac Icon Declares from Charles Yeomans fantastic IDeclare series.... However I cannot seem to get ProxyIcon to work Code: declare function SetWindowProxyIcon Lib "WindowsLib" (inWindow as windowptr,IconRef as ptr) as integer call GetIconFromExtension(ext,16,&c000000) if me.iconref<>nil then OSError=SetWindowProxyIcon(w,me.iconref) GetIconFromExtension normally returns a 16x16 picture of the desired icon, but for this all I wanted was the me.IconRef value that it sets [and it DOES set one].... However that last line... crashes my app... w is a window and is not NIL _________________ Dave Sisemore MacPro, RB2008r3.1 Top timhare Post subject: Re: ProxyIconPosted: Mon Aug 03, 2009 9:56 pm Joined: Fri Jan 06, 2006 3:21 pm Posts: 5973 Location: Portland, OR USA You probably need to pass the window's Handle, not the RB window object itself. The declare doesn't know what a window (RB object) is. Code:if me.iconref<>nil then OSError=SetWindowProxyIcon(w.Handle,me.iconref) Tim Top DaveS Post subject: Re: ProxyIconPosted: Mon Aug 03, 2009 11:10 pm Joined: Sun Aug 05, 2007 10:46 am Posts: 1359 Location: San Diego, CA If I do that... I get "Parameters are not compatible with this function" _________________ Dave Sisemore MacPro, RB2008r3.1 Top Jonathon Post subject: Re: ProxyIconPosted: Tue Aug 04, 2009 1:45 am Joined: Fri Sep 30, 2005 5:54 pm Posts: 1877 Location: Great Falls, Montana USA Dave, You mentioned a few times that your were a Windows coder first then moved to Mac. Do you ever use Windows anymore, or just stopped cold turkey? When you did, was some of your clients upset or it didn't really matter? _________________ Jonathon Software Devlopement: http://www.medalertpc.com Surplus Hardware: http://www.semielectronics.com RB2005 R4 Pro for Windows XP Pro/SP2 Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Page 1 of 1 [ 4 posts ] -- Over 1500 classes with 29000 functions in one REALbasic plug-in collection. The Monkeybread Software Realbasic Plugin v9.3. http://www.monkeybreadsoftware.de/realbasic/plugins.shtml [email protected]
