Hello Ashley,

Here's a potential workaround to the memory leak that doesn't involve using
the Windows API. Develop your MB program so that it only generates a sub-set
of your 70,000 total (say x) and then stores it's progress to a file/table
and closes MapInfo (freeing the memory). Then, use Windows scheduling to
kick off an instance of mapinfow.exe with your MBX every y minutes/hours.
You will need to figure out practical values for x and y but you may already
know the average number of images your machine is generating from your 2000
current output. Leave the process over the weekend and then return to the
office on Monday with fingers crossed. Even if you have failures, at least
your output is being saved and you can resume.

Alternatively, use a different version of Pro. This may not necessarily mean
upgrading to the latest version. When generating batch images, I usually go
back in versions to one that has the features I need (e.g. grid support,
etc.). Most of my development is still done in MB v4.5 and tested with Pro
v4.5 and higher.

One final suggestion with batch maps destined for the web. Given that maps
for web use are never very large, sometime labelling is compromised. I found
(and adapted) a JavaScript based pop-up called OVERLIB (easy to find with
Google) and generated map hot spots for my static images. This was
implemented by generating a image map file parallel to each image and using
simple server scripting to insert it into each page. The downside is that I
could only get it working with Internet Explorer but you/others may have
better luck. You can see the results on our web sites "Map Gallery" which
has just over 200 small scale maps. Simply hover your mouse pointer over the
black dots (which are places) for information - even if the place is not
labelled.

http://www.europa-tech.com/gallery.htm

Regards,
Warren Vick
Europa Technologies Ltd.
http://www.europa-tech.com

-----Original Message-----
From: Simmonds, Ashley (OPT) [mailto:[EMAIL PROTECTED] 
Sent: 11 February 2004 01:16
To: [EMAIL PROTECTED]
Subject: RE: MI-L memory leak - save window as...


alright, i'll give the crispy API solution a shot... and no miss hilton, i
can't use alt-prt scrn, in the last day since writing the initial query i've
produced over 70,000 map images, my fingers would be worn down to bloody
stumps by now.  :)

as an aside, my process at the moment because it's automated and doesn't
need a great deal of speed, just reliability, is closing down and restarting
mapinfo after every couple hundred picture dumps.  my closest guess to the
number of times MI has been auto-restarted during this single process is in
the region of 500 times without a single error.  tee hee.

if you're interested in seeing an example of what's being generated, go
here:
http://vmedia.webclients.internode.on.net/455/index.html

it's nothing special, and certainly not for 56k users as it's designed for
our intranet, but it gives you an idea what i'm doing.  i've so far
generated about 2,000 of these pages.  heh.

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Tuesday, 10 February 2004 8:38 PM
To: [EMAIL PROTECTED]
Subject: RE: MI-L memory leak - save window as...


Caroline

Keyboard controls are OK for interactive editing but not for an automated
process - Save Window As (now its working properly in 7.5) also gives you
control over the size, resolution and format directly, plus the ability to
put in a comment such as a copyright notice. The API call I posted is a neat
solution to a problem that shouldn't exist - actually, for my purposes its
better but then I'm not keeping the images as Ash needs to.

Paul Crisp

Syntegra
Innovation Place Delta Bank Road Newcastle NE11 9DJ
Tel 0191 461 4522 Fax 0191 460 1987


-----Original Message-----
From: Caroline Hilton [mailto:[EMAIL PROTECTED]
Sent: 10 February 2004 09:59
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: MI-L memory leak - save window as...


Shoot me if I'm being a little na�ve here, but can't you just use ALT-Prnt
scrn to capture the map windows? This is what I use all the time. I paste
them into a photo editor (Microsoft Photo Editor's the one I'm using at the
moment), then save as whatever image type you need to dump into other
documents.

Is this a different result to Save Window As...?

The resolution's fine.

Caroline

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: 10 February 2004 09:44
To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: MI-L memory leak - save window as...


Ash/Bill

I've put up this link a few times now but I may not have seemed directly
relevant - 

>Grab the contents of the MapInfo window using the HWND into a Picture
>object
- theres example code on the Micrososft
>site at
>http://support.microsoft.com/default.aspx?scid=KB;en-us;q161299.

This is an API call that gives you a picture object with the complete map in
it - instantaneously. No leak.

The situation Ash describes ie memory leak on Save WIndow was the reason I
ended up going down this route, although my requirement was just for a
snapshot of the screen including highlighting during processing in a VB app.

If you hoick the contents of the map window into a picture object in VBA I
presume you can then use an Access method or another API call to produce
your image file - 

HTH

Paul Crisp

Syntegra
Innovation Place Delta Bank Road Newcastle NE11 9DJ
Tel 0191 461 4522 Fax 0191 460 1987


-----Original Message-----
From: B. Thoen [mailto:[EMAIL PROTECTED]
Sent: 10 February 2004 04:30
To: Simmonds, Ashley (OPT)
Cc: 'Mapinfo List (E-mail)'
Subject: Re: MI-L memory leak - save window as...


iOn Tue, 10 Feb 2004, Simmonds, Ashley (OPT) wrote:

> just wondering if this is a documented bug or not.  i'm doing some
> auto-generated web pages which require bucketloads of map images saved

> as PNG, so using integrated mapping through MS Access i issue a
> command such
> as:
> 
> ##############
> Save window 666 as "c:\MapImage.PNG" Type "PNG" ##############
> 

Yea, that's a well-known bug. Summoning a demon by using the sign of the

beast for a window id isn't going to help you. Salvation is only for those
who upgrade religiously. It was fixed in 7.5.

- Bill Thoen

"Failure is not an option; it comes bundled with the software."




---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com | To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 10349



********************************************************************

This email may contain information which is privileged or confidential. If
you are not the intended recipient of this email, please notify the sender
immediately and delete it without reading, copying, storing, forwarding or
disclosing its contents to any other person Thank you

Check us out at http://www.syntegra.com

********************************************************************




---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com | To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 10354



********************************************************************

This email may contain information which is privileged or confidential. If
you are not the intended recipient of this email, please notify the sender
immediately and delete it without reading, copying, storing, forwarding or
disclosing its contents to any other person Thank you

Check us out at http://www.syntegra.com

********************************************************************


---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com | To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 10371




---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 10375

Reply via email to