• ¡Welcome to Square Theme!
  • This news are in header template.
  • Please ignore this message.
مهمان عزیز خوش‌آمدید. ورود عضــویت


امتیاز موضوع:
  • 7 رای - 3 میانگین
  • 1
  • 2
  • 3
  • 4
  • 5
Title: سورس کد تغییر پس زمینه دسکتاپ(ویژوال بیسیک 6)
حالت موضوعی
#1
درود

با سورس زیر میتونید پس زمینه دسکتاپ رو عوض کنید.

کد:
''Description: A example of how to easily change the
'desktops wallpaper to your selected image using code.
'This example uses the "SystemParametersInfo" api call to
'do the work. By calling this function with a couple
'constants and specifying the image, it will quickly
'change the wallpaper on your windows desktop to the
'image you specified.
''
'
'api to set the parameters for changing the wallpaper
Private Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, ByVal lpvParam As String, ByVal fuWinIni As Long) As Long
'constants to be used with the above api
Private Const SPI_SETDESKWALLPAPER = 20
Private Const SPIF_UPDATEINIFILE = &H1
    
'will hold the path to the image
Private imagePath As String
    
Private Sub cmdBrowse_Click()
    'just your basic code to get a dialog box open to
    'select a image and get the path
    '
    'the picture must be a BITMAP Image File
    '
    dlg........ = "Image Files (*.bmp)|*.bmp"
        
    'set a custom title to the dialog
    dlg.DialogTitle = "Select the image to load."
    'show the dialog
    dlg.ShowOpen
    'the path to get the image from
    imagePath = dlg.FileName
    'view the selected picture into the picturebox
    'control
    pic.Picture = LoadPicture(imagePath)
        
End Sub
Private Sub cmdSetWallPaper_Click()
    'set the parameters to change the wallpaper to
    'the image you selected
    SystemParametersInfo SPI_SETDESKWALLPAPER, 0, imagePath, SPIF_UPDATEINIFILE
End Sub
گروه دور همی پارسی کدرز
https://t.me/joinchat/GxVRww3ykLynHFsdCvb7eg
 
پاسخ
#2
امین جان این اشتباهه ؟ http://parsicoders.com/showthread.php?tid=2668
راه در جهان یکیست و آن راه راستیست

                      (زرتشت)
 
پاسخ
#3
نه یه خرده با هم فرق دارن
گروه دور همی پارسی کدرز
https://t.me/joinchat/GxVRww3ykLynHFsdCvb7eg
 
پاسخ
  


موضوعات مشابه ...
موضوع نویسنده پاسخ بازدید آخرین ارسال
  سورس کدهای ویژوال بیسیک Amin_Mansouri 8 16,562 05-15-2017، 04:35 PM
آخرین ارسال: minarad69
  سورس کد شماره گیری از مودم (ویژوال بیسیک 6 ) Amin_Mansouri 1 6,618 05-07-2017، 06:54 PM
آخرین ارسال: alikorg
  چگونه فایل exe با ویژوال بیسیک بسازیم ؟ Amin_Mansouri 4 13,490 08-13-2015، 10:08 PM
آخرین ارسال: Amin_Mansouri
  مشکل با ارور ویژوال بیسیک aghamali 4 7,028 07-03-2015، 11:14 AM
آخرین ارسال: aaaaaaaaa
  سورس کد کار با وب کم (ویژوال بسیک 6) Amin_Mansouri 1 8,167 04-20-2015، 10:10 PM
آخرین ارسال: hackert41389
  مشکل با paste بیسیک 6 aghamali 1 3,559 01-18-2015، 08:53 PM
آخرین ارسال: aghamali
  2 مشکل بیسیک 6 در ویندوز سون aghamali 3 7,062 11-07-2014، 04:25 PM
آخرین ارسال: aghamali
  سورس کد ذخیره میخوام روشنا 5 9,057 06-25-2014، 08:46 AM
آخرین ارسال: Amin_Mansouri
  دریافت سورس سایت بصورت یونیکد aleas 3 5,148 06-07-2014، 09:19 PM
آخرین ارسال: aleas
  سورس جمع آوری وبلاگ های بروز میهن بلاگ saeedh 7 9,002 05-26-2014، 04:09 PM
آخرین ارسال: Amin_Mansouri

پرش به انجمن:


Browsing: 2 مهمان