bellas Posted June 16, 2010 Share Posted June 16, 2010 selam ben programda Bir tuş yapacam ve o tuşa basildiginda Xp çözünürlük ayarlarini örnegin 1024-768 yapacak.. bu kodlamayı nasil yapabilirim ? Quote Link to comment Share on other sites More sharing options...
MostWanted Posted June 16, 2010 Share Posted June 16, 2010 -- arguments: width, height, Depth, Freq, Permanent (0 false, 1 = true) ChangeDisplaySettings(800,600,16,70,0)[/CODE] Global Kısmına; [CODE]--[[ function name: ChangeDisplaySettings Arguments: width, height, Depth, Freq, Permanent (0 false, 1 = true) Returns: 0 = The settings change was successful. 1 = The computer must be restarted in order for the graphics mode to work. -4 = An invalid set of flags was passed in. -1 = The display driver failed the specified graphics mode. -2 = The graphics mode is not supported. -3 = Windows NT only: Unable to write settings to the registry. Description sets the users screen res ]] -- Global function for the screen settings, !!!DO NOT EDIT!!! function ChangeDisplaySettings(width,height,Depth,Freq,Permanent) args = width..", "..height..", "..Depth..", "..Freq..", "..Permanent result = DLL.CallFunction("AutoPlay\\Docs\\DLLDisplaySettings.dll", "ChangeDisplaySettings", args, DLL_RETURN_TYPE_STRING, DLL_CALL_STDCALL); if result == "0" then local hWnd = Application.GetWndHandle(); local WndSize = Window.GetSize(hWnd); local ScreenRes = System.GetDisplayInfo(); local NewPos_X = (ScreenRes.Width - WndSize.Width)/2; local NewPos_Y = (ScreenRes.Height - WndSize.Height)/2; Window.SetPos(hWnd, NewPos_X, NewPos_Y); else if result == 1 then err = "The computer must be restarted in order for the graphics mode to work" elseif result == "-4" then err = "An invalid set of flags was passed in" elseif result == "-1" then err = "The display driver failed the specified graphics mode" elseif result == "-2" then err = "The graphics mode is not supported" elseif result == "-3" then err = "Unable to write settings to the registry" end Dialog.Message("Error", err, MB_OK, MB_ICONNONE, MB_DEFBUTTON1); end end[/CODE] Fonksiyonun açıklaması üstünde yazmaktadır.Son olarak dll'sini vereyim; [CODE]http://rapidshare.com/files/399765429/DLLDisplaySettings.dll[/CODE] Projenizin Doc klasörüne atın.Ondan sonra en üstteki komutu hangi butonla değiştirecekseniz artık onun On Click evresine koyun.. Quote Link to comment Share on other sites More sharing options...
sakaci_79 Posted September 1, 2013 Share Posted September 1, 2013 Dll linkini tekrar verebilirmisiniz Quote Link to comment Share on other sites More sharing options...
MostWanted Posted September 3, 2013 Share Posted September 3, 2013 Buyrun http://rapidshare.com/files/635921605/DLLDisplaySettings.dll Quote Link to comment Share on other sites More sharing options...
sakaci_79 Posted September 4, 2013 Share Posted September 4, 2013 Win 7 dede işe yarar mı? Quote Link to comment Share on other sites More sharing options...
reyiz Posted September 4, 2013 Share Posted September 4, 2013 (edited) Çalışmıyor maalesef. Nircmd isimli küçük boyutlu bir programla bunu yapabilirsiniz. Diyelim çözünürlüğü 1024*768 yapmak istiyorsunuz, bu komutu kullanmalısınız: nircmd.exe setdisplay 800 600 32 Sondaki kısım ekranın renk ayarını değiştirir. Girilmesi zorunludur. AMS ile bu şekilde kullanabilirsiniz: File.Run("nircmd.exe", "800 600 32", "", SW_HIDE, false); Nircmd: http://www.nirsoft.net/utils/nircmd.zip Edited September 4, 2013 by reyiz Quote Link to comment Share on other sites More sharing options...
sakaci_79 Posted September 4, 2013 Share Posted September 4, 2013 bunu win 7 için anlatırmısın Quote Link to comment Share on other sites More sharing options...
reyiz Posted September 4, 2013 Share Posted September 4, 2013 Windows 7'de çalışıyor zaten. Quote Link to comment Share on other sites More sharing options...
sakaci_79 Posted September 4, 2013 Share Posted September 4, 2013 malisef çalışmıyo dediniz ya o yüzden sordum Quote Link to comment Share on other sites More sharing options...
reyiz Posted September 4, 2013 Share Posted September 4, 2013 Konuda anlatılan yöntem çalışmıyor. Benim anlattığım çalışıyor. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.