07-17-2017, 03:41 PM
In any codes:
example:
Sub _Daily_Mail()
Dim Rango7 As Range
Dim Archivo As String
Dim Imagen As Chart
Dim Result As Boolean
Set Rango7 = Sheets("Summary").Range("P2:AI92") ' Summary
Sheets("Summary").Select
With Rango7
.CopyPicture Appearance:=xlScreen, Format:=xlPicture
Set Imagen = Rango7.Parent.ChartObjects.Add(33, 39, .Width, .Height).Chart
End With
Imagen.Paste
Imagen.ChartArea.Border.LineStyle = 0
Imagen.ChartArea.Width = Imagen.ChartArea.Width * 3
Imagen.ChartArea.Height = Imagen.ChartArea.Height * 3
Imagen.export "C:\Users\mely\Documents\Imagenes_POS\Informe1.png", filtername:="PNG"
Imagen.Parent.Delete
Set Imagen = Nothing
https://stackoverflow.com/questions/338 ... ank-images
How to use ChartArea.Width and ChartArea.Height to shrink the image?
example:
Sub _Daily_Mail()
Dim Rango7 As Range
Dim Archivo As String
Dim Imagen As Chart
Dim Result As Boolean
Set Rango7 = Sheets("Summary").Range("P2:AI92") ' Summary
Sheets("Summary").Select
With Rango7
.CopyPicture Appearance:=xlScreen, Format:=xlPicture
Set Imagen = Rango7.Parent.ChartObjects.Add(33, 39, .Width, .Height).Chart
End With
Imagen.Paste
Imagen.ChartArea.Border.LineStyle = 0
Imagen.ChartArea.Width = Imagen.ChartArea.Width * 3
Imagen.ChartArea.Height = Imagen.ChartArea.Height * 3
Imagen.export "C:\Users\mely\Documents\Imagenes_POS\Informe1.png", filtername:="PNG"
Imagen.Parent.Delete
Set Imagen = Nothing
https://stackoverflow.com/questions/338 ... ank-images
How to use ChartArea.Width and ChartArea.Height to shrink the image?
