@jmeza , en el ejemplo que subio
@Fito , esta el prgbuscar como un script
Código COBOL:
ENVIRONMENT DIVISION.
DATA DIVISION.
WORKING-STORAGE SECTION.
01 palabra pic x(20).
01 linea pic x(100).
01 wlen pic s9(5) comp-5.
01 i pic 9(8).
01 h pic 9(8).
01 si pic 9(8).
PROCEDURE DIVISION.
comienzo.
move "Text" of txtPalabra to palabra.
compute wlen = function stored-char-length(palabra).
move "ListCount" of cmbDatos to h.
move zeros to "ListIndex" of cmbDatos.
move zeros to si.
perform varying i from 1 by 1 until i > h
move "ListString"(i) of cmbDatos to linea
move function upper-case(linea) to linea
inspect linea tallying si for all palabra(1:wlen)
if si not = zeros
move i to "ListIndex" of cmbDatos
exit perform
end-if
end-perform.
exit program.
Saludos...