Absent Member.
Absent Member.

[SAP] Issue when adding value with matchcode into non-editable cell

Hi all, I'm facing an issue on a specifical transaction in SAP.

My script want to select a value in a non editable cell, inside a SapGuiGrid.

When i select the value via matchcode, it's not added in the cell after submit. Even worse, it erase the data i put in the other cells (other cells are editable).

I don't understand why i get this particular problem.

The objects in the list are saved in the object repository as "SapGuiLabel"

Here is my code :



SAPGuiSession("Session").SAPGuiWindow("ORC – Dépose des immobilisatio_2").SAPGuiGrid("Dépose").SetCellData 2,"Nature d'ouvrage",DataTable("Nature",dtLocalSheet)
SAPGuiSession("Session").SAPGuiWindow("ORC – Dépose des immobilisatio_2").SAPGuiGrid("Dépose").SetCellData 2,"Année d’origine MES",DataTable("Année",dtLocalSheet)
SAPGuiSession("Session").SAPGuiWindow("ORC – Dépose des immobilisatio_2").SAPGuiGrid("Dépose").SetCellData 2,"Qté prév. dépose",DataTable("Qté_Prev",dtLocalSheet)
SAPGuiSession("Session").SAPGuiWindow("ORC – Dépose des immobilisatio_2").SAPGuiGrid("Dépose").OpenPossibleEntries 2,"Libellé matière"
SAPGuiSession("Session").SAPGuiWindow("Liste des occurrences").SAPGuiLabel("POLYETHYLENE").SetFocus
SAPGuiSession("Session").SAPGuiWindow("Liste des occurrences").SAPGuiButton("Reprendre (Entrée)").Click


So, at the end, the value "POLYETHYLENE" isn't added in the Grid, and the previous values "Nature" and "Année" are erased.. I really don't know how to solve this problem, any help would be very appreciated.

Thanks in advance,


Tags (2)
0 Replies
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.