Hi again, Søren!

You're right about using filesaveasdlg() - it is a bit clunky, but you can
choose a folder without any files in it (the dialog is all about choosing a
file name to save a -probably- new file, so you don't have to select a
pre-existing one), and you can use the dialog to create a new folder too -
so perhaps it's not quite as bad as you thought!

Presumably your users will be aware that they are saving some files
somewhere, so asking them to choose a folder for the first and all
subsequent files using something like:

filesaveasdlg("c:\","first.jpg","*.*","Choose output directory for all
files")

shouldn't come as too much of a shock to them.

Mind you, some of the users I deal with are, I suspect, mildly shocked that
it gets light each morning, so perhaps it is too much to ask.

Back to the Black Arts of the Windows API, then!

All the best,
---------------------------------------------
David Booth
Senior GIS Officer
Merseyside Information Service

> -----Original Message-----
> From: Søren Breddam [SMTP:[EMAIL PROTECTED]]
> Sent: 09 February 2001 09:03
> To:   MapInfo-L (E-mail)
> Cc:   'David Booth'
> Subject:      Re: MI-L Specifying path
> 
> Hi David, Christopher, Jacques, list,
> 
> Thanks!
> Proposed solutions to let the user specify a save folder:
> Converting the VB code from Christopher to MB: I'm in the same situation
> as
> Jacques - I'm not sure it's possible. I haven't found anything like the VB
> "SHBrowseForFolder" in MB. As far as I know, everything in MB on this
> issue
> is on file level.
> 
> FileSaveAsDlg() and strip the path out: That one could do the trick, and
> it
> was also my initial idea. BUT I can't ask the user to select a file if
> there
> aren't any in the folder (probably a new folder) and I also think it's a
> little odd to select a file when I want a folder...
> 
> I could create a new folder to the files, but then I still would have to
> ask
> for a drive (the output could be several Gb!) or I could have a button in
> the dialog that runs explorer. I don't think these two are better than
> letting the user type in the path!
> 
> regards 
> Søren Breddam
> Stevns Kommune
> 
> >-----Oprindelig meddelelse-----
> >Fra: David Booth [mailto:[EMAIL PROTECTED]]
> >Sendt: 7. februar 2001 16:29
> >Til: 'Søren Breddam'
> >Emne: RE: MI-L Specifying path
> 
> 
> >Hi Søren,
> 
> >You should be able to fudge something using filesaveasdlg(), which
> returns
> a
> >filename (including directory path) without actually saving the file
> itself.
> >The user browses to the directory they want.
> 
> >It should be pretty straightforward to strip out just the path part of
> the
> >returned string and use this to save the pictures - pathtodirectory$()
> might
> >do it, though I'm not entirely convinced that some of these mapbasic
> string
> >functions work properly.
> 
> >Hope this helps. 
> 
> >---------------------------------------------
> >David Booth
> >Senior GIS Officer
> >Merseyside Information Service
> 
> > -----Original Message-----
> > From:       Søren Breddam [SMTP:[EMAIL PROTECTED]]
> > Sent:       07 February 2001 12:32
> > To: MapInfo-L (E-mail)
> > Subject:    MI-L Specifying path
> > 
> > Hi List,
> > I have a loop where I save a lot of windows as picture files.
> > Before that I would like to display a dialog where the user shall
> specify
> > the path, where all the files should be saved. How do I do that without
> > letting the user type in the path - I would rather let him browse to it?
> > 
> > regards 
> > Søren Breddam
> > 
> > 
> > 
> > _______________________________________________________________________
> > List hosting provided by Directions Magazine | www.directionsmag.com |
> > To unsubscribe, send e-mail to [EMAIL PROTECTED] and
> > put "unsubscribe MapInfo-L" in the message body.



_______________________________________________________________________
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, send e-mail to [EMAIL PROTECTED] and
put "unsubscribe MapInfo-L" in the message body.

Reply via email to