aluminum2
Aerospace
- Apr 27, 2010
- 218
I am trying to resize an image I am inserting with a journal. The image part works. I added code to resize it and when I run it I get an error saying it is converting string to integer . I am not sure If I am using the SetImageWidth and SetImageheight correctly.
Code:
Dim imageFile As String = "location"
Dim sheetTag As Tag = NXOpen.Tag.Null
Dim imageCoordinates(2) As Double
Dim imageheight As Double
Dim imageWidth As Double
imageCoordinates(0) = NAMEX
imageCoordinates(1) = NAMEY
imageCoordinates(2) = 0
imageheight = .1000
imageWidth = .2000
Dim imageTag As Tag = NXOpen.Tag.Null
ufs.Drf.CreateImageFromFile(imageFile, sheetTag, imageCoordinates, imageTag)
ufs.Drf.SetImageHeight(imageFile, imageheight)
ufs.Drf.SetImageWidth(imageFile, imageWidth)