Ecco subito il codice:
------------------------------------------------------------
Imports System.IO.Pach
Imports System.Drawing.Imaging
Public Function ConvertBMP(ByVal BMPFullPach As String,_ ByVal imgFormat As ImageFormat) As Boolean
Dim bAns As Boolean
Dim sNewFile As String
Try
Dim objBmp As New Bitmap(BMPFullPach)
sNewFile = GetDirectoryName(BMPFullPach)
sNewFile &= GetFileNameWithoutExtension(BMPFullPach)
sNewFile &= "." & imgFormat.ToString
objBmp.Save(sNewFile, imgFormat)
bAns = True
cath
bAns = False
End Try
Return bAns
End Function
------------------------------------------------------------
Spero che questo codice possa servirvi ...
Convertitore Formati
Pubblicato prima del 07/05/2008 - Informazione assente
Conoscenze Avanzate: C,VB.NET Base:Assembler MIPS,HTML,PHP,CSS,JavaScript. Stò imparando il C# e Java
|
Aggiungi un commento