Will
Private dollar As String = "$"
Private script_str As String = $"
// Populate the select with the names
for (let i = 1; i <= nonames; i++) {
const option = document.createElement('option');
//In following 2 statements backticks (`) are used for template
//literals (also known as template strings) in JavaScript.
//Template literals allow you to embed expressions within a string
//using `${dollar}{}` syntax
option.value = eval(`name${dollar}{i}`);
option.textContent = eval(`name${dollar}{i}`);
selectName.appendChild(option);
}
"$
work for you?
It produces:
// Populate the select with the names
for (let i = 1; i <= nonames; i++) {
const option = document.createElement('option');
//In following 2 statements backticks (`) are used for template
//literals (also known as template strings) in JavaScript.
//Template literals allow you to embed expressions within a string
//using `${}` syntax
option.value = eval(`name${i}`);
option.textContent = eval(`name${i}`);
selectName.appendChild(option);
}