excel - Function without return doesn't work -
i have macro calls function:
function escreve_mapa(row integer, lastcolumn integer, equipamentos interger, abrangencia string, medias) dim cell range dim colunas range dim integer sheets("mapa de sinais (tabela)").select cells(row, "a").value = abrangencia cells(row, "b").value = equipamentos set cell = range("c" & row) set colunas = range(cell, cell.offset(0, lastcolumn - 3)) = 0 each cell in colunas if medias(i, 1) > 0 cell.value = round(medias(i, 0) / medias(i, 1), 2) end if = + 1 next cell end function
but when gets function returns error user-defined type not defined
any idea why?
you've got typo in functions (although doesn't return sub) arguments.
equipamentos interger
should equipamentos integer
Comments
Post a Comment