|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Yesterday @ 10:16 AM
Points: 23,
Visits: 66
|
|
I am trying to parse a number of image files in a sub directory to determine their height and width using an SSIS script task. Based on the picture dimensions, I was going to sort large (> 600x600) pictures into one folder and small (<600x600) pictures into another. To do so, I was going to write a simple script similar to the script below. When I go to import System.Drawing, I type Imports System. ... and expect to see Drawing there through Intellisense. Unfortunately that option is not available. My guess is that I need to somehow reference this .Net framework piece; but past that I am pretty lost. Any help would be GREATLY appreciated.
Thanks!
Dim UploadedImage As Bitmap = New Bitmap("C:\DATA\IMAGES\figure2.jpg")
Dim UploadedImageWidth As Single = UploadedImage.PhysicalDimension.Width Dim UploadedImageHeight As Single = UploadedImage.PhysicalDimension.Height
|
|
|
|
|
Mr or Mrs. 500
      
Group: General Forum Members
Last Login: Yesterday @ 7:20 AM
Points: 545,
Visits: 1,643
|
|
You gotta add system.drawing into your CLR assemblies first using SSMS under database-> programmability->Assemblies. Then add that reference into your SQL Server Project that you are working on.
There would be dependencies that should be added first while you are loading your assemblies into SQL Server. That you would anyway come to know in the process of adding it.
---------------------------------------------------------------------------------
|
|
|
|