0
I am developing an Asp.Net application using MVC 5. I have created one select
on the Vendors screen and I would like to know how I can get the information from my bank and show them in this custom.
My application has two screens: Companies and Suppliers. In the suppliers screen, I have a select
where I would like to get the names of companies registered on the screen of "Companies".
In the database I have two tables: Suppliers and Companies.
Code of select
:
<div class="form-row">
<div class="col-7">
<label for="txtNome">Empresa:</label>
<select name="Empresa" id="txtEmpresa" class="custom-select">
<option selected>Escolha uma empresa...</option>
<option value="@Model.Empresa">One</option>
<option value="@Model.Empresa">Two</option>
<option value="@Model.Empresa">Three</option>
</select>
</div>
<div class="col">
<label> </label>
<div class="mb-3">
<a href="~/Empresas/AddEdit" class="btn btn-outline-info"><i class="fas fa-plus"></i>Nova Empresa</a>
</div>
</div>
</div>
Why don’t you use Razor? Another detail, add your font
controller
.– Tiedt Tech
Was able to verify the answer?
– tvdias