Last post May 31, 2006 12:44 PM by NC01
May 31, 2006 11:18 AM|gebelo|LINK
More specifically: The Mapping program creates a loop spits out a bunch of .png files that contain pieces of the map. What I need to do is insert a routine that crops each .png file as part of the loop.
// Spit out the map
What I need to do is save this information into a variable and run my .Net routine. As a freestanding app, it looks like this....
<%@ Page Language="vb" Debug="true" Trace="true" %>
<%@ import Namespace="system.drawing" %>
<%@ import Namespace="system.drawing.imaging" %>
<%@ import Namespace="system.io" %>
dim myBitmap as New Bitmap(server.mappath("images/theimage.jpg"))
dim memStream As New MemoryStream()
dim myBitmapCropped as New Bitmap(128,128)
dim myGraphic = Graphics.FromImage(myBitmapCropped)
myGraphic.DrawImage(myBitmap, new Rectangle(0,0,128,128),40,40,128,128,GraphicsUnit.Pixel)
Any assistance would be greatly appreciated...
May 31, 2006 12:20 PM|NC01|LINK
Example using a PostBack:
__doPostBack('CallSpecialFunction', 'any arguments necessary');
In the Page_Load event handler:
if ( IsPostBack )
object eventTargetObject = this.Request["__EVENTTARGET"];
object eventArgumentObject = this.Request["__EVENTARGUMENT"];
if ( (eventTargetObject != null) && (eventTargetObject.ToString() == "CallSpecialFunction" ) )
string eventArgument = eventArgumentObject.ToString();
For AJAX/ATLAS, here are some informational links:
May 31, 2006 12:35 PM|gebelo|LINK
to give that a shot... thanks...
May 31, 2006 12:44 PM|NC01|LINK