Skip to main content
deleted 4 characters in body; edited tags; edited title
Source Link
Taras
  • 36k
  • 7
  • 77
  • 153

Adding virtualVirtual field to layer from QGIS Graphical Modeler

Is it possible to addCan a virtual field be added to a vector layer within a model (using a graphical modeller).? The goal would be to get a model output layer that haswith the virtual field already declared and working.

I've tried to create a new process that has a vector layer and an expression : the process reads the vector layer and adds a new virtual field with the input expression using the vector_layer.addExpressionField(expression,virtual_field) line. The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it *I've tried to create a new process that has a vector layer and an expression: the process reads the vector layer and adds a new virtual field with the input expression using the line:

vector_layer.addExpressionField(expression, virtual_field) 

The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it

Adding virtual field to layer from QGIS Graphical Modeler

Is it possible to add a virtual field to a vector layer within a model (using a graphical modeller). The goal would be to get a model output layer that has the virtual field already declared and working.

I've tried to create a new process that has a vector layer and an expression : the process reads the vector layer and adds a new virtual field with the input expression using the vector_layer.addExpressionField(expression,virtual_field) line. The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it

Adding Virtual field to layer from QGIS Graphical Modeler

Can a virtual field be added to a vector layer within a model (using a graphical modeller)? The goal would be to get a model output layer with the virtual field already declared and working.

*I've tried to create a new process that has a vector layer and an expression: the process reads the vector layer and adds a new virtual field with the input expression using the line:

vector_layer.addExpressionField(expression, virtual_field) 

The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it

edited title
Link

Adding virtual field to layer from QGIS Graphical ModellerModeler

added 588 characters in body
Source Link

Is it possible to add a virtual field to a vector layer within a model (using a graphical modeller). The goal would be to get a model output layer that has the virtual field already declared and working.

I've tried to create a new process that has a vector layer and an expression : the process reads the vector layer and adds a new virtual field with the input expression using the vector_layer.addExpressionField(expression,virtual_field) line. The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it

Is it possible to add a virtual field to a vector layer within a model (using a graphical modeller). The goal would be to get a model output layer that has the virtual field already declared and working.

Is it possible to add a virtual field to a vector layer within a model (using a graphical modeller). The goal would be to get a model output layer that has the virtual field already declared and working.

I've tried to create a new process that has a vector layer and an expression : the process reads the vector layer and adds a new virtual field with the input expression using the vector_layer.addExpressionField(expression,virtual_field) line. The process simply modifies the input layer without returning anything. It works when it is the last process used in the modeler but I'd like to set a style to the output layer using the "Edit rendering style for outputs" menu and when I do this the virtual field gets discarded. I was wondering if there was a more official way to do it

deleted 24 characters in body; edited title
Source Link
Taras
  • 36k
  • 7
  • 77
  • 153
Loading
Source Link
Loading