I get this table in angular material
<mat-table [dataSource]="dataSource">
<ng-container matColumnDef="{{this.columnsToDisplay[3]}}">
<th mat-header-cell *matHeaderCellDef mat-sort-header>{{this.columnsToDisplay[3]}}</th>
<td mat-cell *matCellDef="let element; let i=index">
<mat-form-field class="form-input">
<input type="number" matInput [(ngModel)]="quincenaUrl==1?element.dia2:element.dia17"
(keyup.enter)="editarCelda($event)" />
</mat-form-field>
</td>
</ng-container>
....
<tr mat-header-row *matHeaderRowDef="columnsToDisplay; sticky:true"></tr>
<tr mat-row *matRowDef="let element; columns: columnsToDisplay;" class="element-row"></tr>
<tr class="mat-row" *matNoDataRow>
<td class="mat-cell" colspan="4">No se han encontrado coincidencias</td>
</tr>
</mat-table>
When I edit a value and Press Enter in my class I get the event
editarCelda(event: any) {
console.log("Nuevo Valor", event.target.value);
}
And I know how to get the value but I don't know how to get the row and column edited, that is, the position of the edited cell
Any idea, please?
Thanks