Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

140
Visualizações
Excel Custom Function #VALUE error when returning a salt hash

I have a custom excel function that calculates a salt hash and attempts to return the hash and the salt as an array. When I run the function, the values appear to be generated correctly but I get a #VALUE error when trying to display them and I'm not sure why. It appears that the issue is coming from the salt portion of the hash. Excel doesn't seem to like a value starting with "$" so if I add a space before the salt value then it works correctly. Why am I receiving a #VALUE error and how can I resolve it?

Excel AddIn Code

/**
 * Returns hash for input text.
 * @customfunction SALT_HASH
 * @param {string} text
 * @param {string} [salt]
 * @returns string[][]
 */
export async function saltHash(text: string, salt?: string): Promise<string[][]> {
  try {
    const saltHash = await api.saltHash(text, salt);
    const response = [[saltHash.hash, saltHash.salt]];
    Logger.info(response);
    return response;
  } catch (error) {
    Logger.error(new SaltHashErrorLog("Salt hash function call failed", text, salt, error).log());
    return [[`Salt hash function call failed: ${buildErrorMessage(error)}`]];
  }
}

Example API Response

{
    "hash": "1IDvJZuvNSLS3EQl7kD9jLm2qN7Sp5K",
    "salt": "$2b$10$BAsip4RJH8MMz0G7Dw5EvO"
}
about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda