Rotate Picture(clockwise and counter clockwise)in excel vba UserForm

More From this channel:- ................................................................................................................... Source Code:- Private Sub CommandButton1_Click() If TextBox1.Text = «» Then MsgBox «Image Not select.», vbCritical, «» Exit Sub End If Call rotate90Right End Sub Private Sub CommandButton4_Click() If TextBox1.Text = «» Then MsgBox «Image Not select.», vbCritical, «» Exit Sub End If Call rotate270 End Sub Private Sub CommandButton5_Click() Dim strPic As String With Application.FileDialog(1) ' msoFileDialogOpen .Filters.Clear .Filters.Add «Image Files (*.jpg,*.bmp, *.gif,*.jfif)», «*.jpg,*.bmp,*.gif,*.jfif» If .Show Then Me.Image1.Picture = Nothing strPic = .SelectedItems(1) Me.Image1.Picture = LoadPicture(strPic) TextBox1.Text = strPic Else Beep End If End With End Sub Module....................................................... Dim imgDes_imgSource, del As String Dim ImgFile As WIA.ImageFile Dim ImgP As WIA.ImageProcess Dim Selectedfile As String Sub rotate90Right() Set ImgFile = New WIA.ImageFile Set ImgP = New WIA.ImageProcess imgDes_imgSource = UserForm1.TextBox1.Text Selectedfile = imgDes_imgSource 'Add Filter ImgP.Filters.Add ImgP.FilterInfos(«RotateFlip»).FilterID ImgP.Filters(1).Properties(«RotationAngle») = 90 ImgFile.LoadFile Selectedfile Set ImgFile = ImgP.Apply(ImgFile)...

0/0


0/0

0/0

0/0

0/0