0
In C#, visual Studio. hello I am new and come for help, I would like to display in a component, can be in the textbox, Panel or label the data of table 'OCCUPATIONS'. I’ll try to explain:
I have a table called 'OCCUPATIONS' where I have the fields: ID, ROOM, DATA, HOST. When I make a reservation, the fields: ID, QUARTO, DATA, HOSPEDE receives the respective values. When I check out, the fields: ID, ROOM, DATE, GUEST are blank, indicating that there are no reservations. What I would like is to display the ROOM field on a component if there is a value. If it is empty, it does not display or turn green. Can someone give me some guidance? I can already list in a grid, and count the elements and even pick up the field with Reader, but only takes a data.
to list: "SELECT * FROM occupations ORDER BY quarto asc"; to check: cmdVerify = new Mysqlcommand("SELECT * FROM rooms WHERE room = @room", con.con);
help me
I managed to solve this case. Now the problem is another. My if (Quartoocupado == "01") I am limited to room quantity "01", "02"... I need an if (Quartoocupado == Quartocadastrado). where I look for rooms in the table 'Rooms'. any suggestions?
– Alex Rodrigues