Hi,
Here's some code to make the chosen layer editable:
******************Code begin**********************
include "mapbasic.def"
include "icons.def"
Declare Sub main
Declare Sub rediger
Sub main
OnError GoTo OOPS
Create Buttonpad "EditLayer" as
PushButton
HelpMsg "Make the chosen layer editable\nMake the chosen
layer editable"
Calling rediger
Icon 240
Title "EditLayer"
'width 2
ToolbarPosition ( 1,3)
Fixed
show
Exit Sub
OOPS:
Print Error$() Resume Next
End Sub
Sub rediger
OnError GoTo OOPS
Dim i As SmallInt
If SelectionInfo(SEL_INFO_NROWS) < 1 Then
print "Nothing chosen"
Exit Sub
End If
If FrontWindow() Then
If WindowInfo(FrontWindow(),WIN_INFO_TYPE) = WIN_MAPPER Then
For i = 1 to MapperInfo(FrontWindow(), MAPPER_INFO_LAYERS)
if
SelectionInfo(SEL_INFO_TABLENAME)=LayerInfo(FrontWindow(), i,
LAYER_INFO_NAME) then
print "The layer "+LayerInfo(FrontWindow(),
i, LAYER_INFO_NAME)+" is now editable..."
exit for
end if
next
end if
end if
Set Map Layer i Editable On
Exit Sub
OOPS:
Print Error$() Resume Next
End Sub
**************End code*****************************
You can download an app called "Lag" from my website with some more
features. It's in danish but it's including source code - so help yourself
:-)
Regards
S�ren Breddam
http://mb.breddam.dk
-----Oprindelig meddelelse-----
Fra: Andrew Hare [mailto:[EMAIL PROTECTED]
Sendt: 8. december 2004 20:16
Til: John Nott; [EMAIL PROTECTED]
Emne: RE: MI-L R�f. : RE: MI-L Layer control tool
Hi all
I use a tool called Quick layer control or QLC
Found at directions mag utilities page
Great app How it works is you high light the layer using the pointer press
the pen button on the QLC button pad
And the selected layer becomes editable
If you can't find it on the site I can email you the app
Regards
Andrew Hare
GIS Officer
Waimate District Council
Sth Island
New Zealand
-----Original Message-----
From: John Nott [mailto:[EMAIL PROTECTED]
Sent: Thursday, 9 December 2004 7:02 a.m.
To: [EMAIL PROTECTED]
Subject: RE: MI-L R�f. : RE: MI-L Layer control tool
Is there any way to automatically set the selected layer to being editable.
Maybe with an option to have this feature on or off (ala the ESRI editing
environment; seeing as it may not be suitable all the time.
I think that would be very useful when tweaking a map with many layers
rather than having the layer control open all the time especially for those
of us who use the graphics capabilities of MI as well as the GIS.
Would be a nice option for version 7.9!
Cheers,
- John
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: 08 December 2004 17:42
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: MI-L R�f. : RE: MI-L Layer control tool
the status bar is not very useful when you want to edit thematic maps.. I
keep the General tool palette floating, then it's just a clic on the layer
tool .. but it would be nice to have it permanently open, as you say. It
should also allow for customizable size (when you have a lot of layers)...
And since were are talking of wishes lists : when creating thematic maps
and using data in a separate table, it's a pain that you have to link the
same data table to your geographic table again and again, each time you
want to test a new variable. It doesn't help that the link command lies
down at the bottom of the variable list and that each time you need to
create a link you have to scroll down the whole list. It's also a pain if
you want to use manual intervals to create your thematic map instead of
automated intervals; now you have to enter each value twice (the higher
bond of a class is the lower bond of the next.. so this should be
automated) and the cursor doesn't even go automatically to the next value.
Christiane Roh - Section Statistique Lausanne
Statistique Lausanne - SCRIS
Service cantonal de recherche et d'information statistiques
Rue de la Paix 6, CH-1014 Lausanne
t�l.: +41(021) 316 29 51
fax : +41(021) 316 29 50
Peter Horsb�ll M�ller <[EMAIL PROTECTED]>
08.12.2004 18:20
Pour : "Eric Gagnon" <[EMAIL PROTECTED]>, "Mapinfo List"
<[EMAIL PROTECTED]>
cc :
Objet : RE: MI-L Layer control tool
If all you are looking for is an easy way to make a layer editable you
should use the Editable list in the statusbar, where you quickly can
select the layer you want to edit.
Make sure you have your statusbar visible (see the Options menu if you
haven't)
Peter Horsb�ll M�ller
GIS Developer
Geographical Information & IT
COWI A/S
Odensevej 95
DK-5260 Odense S.
Denmark
Tel +45 6311 4900
Direct +45 6311 4908
Mob +45 5156 1045
Fax +45 6311 4949
E-mail [EMAIL PROTECTED]
http://www.cowi.dk/gis
-----Original Message-----
From: Eric Gagnon [mailto:[EMAIL PROTECTED]
Sent: Wednesday, December 08, 2004 6:16 PM
To: Mapinfo List
Subject: MI-L Layer control tool
Hi everyone,
Is there a tool that would make my "layer contol" window stick on my
screen so I wouldn't have to open and close it each time I want edit a
layer. (stick beside my map window)
I sure hope there's a tool available instead of waiting for Mapinfo to
put it in there 8. something version.
I would also make a great christmas gift.... ;-)
Eric Gagnon, B.Sc., GIS Specialist
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com | To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14443
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14444
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14448
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14449
---------------------------------------------------------------------
List hosting provided by Directions Magazine | www.directionsmag.com |
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Message number: 14450