Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

Newbie here confused by my first experience in QGIS

I have a handful of lines defining a bike route.

Originally they were saved in a .gml file and later translated into .kml so they could be viewed in GE.

I can open both .gml and .kml as layers in QGIS, but neither allows me to edit the lines

If I save either the .gml or .kml layers as a Shapefile, then load that shapefile as a QGIS layer, then I can edit the lines.

I have also tried loading the .kml file, making a new blank shapefile layer, selecting and copying the lines on the .kml layer and tried to paste onto the blank shapefile layer, which also was not possible.

I don't understand if lines are understood by QGIS on kml layer well enough to be saved as Shapefile, why they are not editable. I feel I must be missing something basic that explains this and perhaps it has other implications that I should understand.

Thanks for any help.

Dennis

share|improve this question
add comment

2 Answers

I don't understand if lines are understood by QGIS on kml layer well enough to be saved as Shapefile

I'm not aware of any problems. If the lines are displayed correctly on the map, export to Shapefile should work too.

You already found the solution: Save the GML as Shapefile and you can edit that.

From the mailing list:

The state of the "Toggle Editing" button depends on provider (driver) capabilities. It is only enabled when the driver has ChangeAttributeValues capability

With this approach many OGR formats that support adding or removing features but don't allow editing existing features are not editable.

share|improve this answer
    
What I don't understand is if OGR can convert between SHP and KML and vice versa, why can't it edit directly? –  Stev_k Apr 2 '12 at 11:19
2  
That's a good question and it has been asked before mail-archive.com/qgis-developer@lists.osgeo.org/msg05718.html without answer though. –  underdark Apr 2 '12 at 11:24
    
I agree I had solved my problem. I was trying to understand why this doesn't work because I thought it might give me insight into the best way to work through future tasks. –  Dennis Conklin Apr 2 '12 at 11:43
1  
I have learned from this to be Shrek friendly, since the ogre that lives under the hood can be as demanding as the Troll that lives under the Bridge. –  Dennis Conklin Apr 2 '12 at 16:26
    
Maybe related? gis.stackexchange.com/questions/30348/… –  ljader Oct 9 '12 at 9:31
add comment

I had a go at replicating your workflow. Your experience is validated. I had to create a memory layer and then save that as a shapefile.

Memory Layer is a plugin which you have to install by Fetching the Plugin from that menu.

I won't attempt to answer why.

ciao

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.