Click here to Skip to main content
15,891,654 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hai there guys. Sorry if my subject isn't clear enough because I don't know how else to put. So here's the thing, I need to debug and test a VB.NET windows application for hotel management system. I'm quite new to VB.NET, so there is a few lines of database query that I didn't get. There is a few lines such as :

VB
Com.CommandText = "Select * from QRoom Order by RoomNo"


or

VB
Com.CommandText = "Select Floor from QRoom where RoomNo=" & cbo.Text & ""


as you can see the table name there is QRoom but when I check within the Access database, there is no table name QRoom. But if I change the table name to the one that us in the database(which is my case, it is TblRoom), then there will be errors. So I didn't get why is that. Any help is appreciated. :)

p/s : the guy who wrote this code is unreachable st the moment so I cannot directly ask him. :(
Posted
Comments
André Kraak 27-Nov-12 4:37am    
Did you check to see whether QRoom is a query in the database?
Does the table TblRoom contain the field RoomNo?
nizam15 27-Nov-12 4:42am    
yes, there is a field name RoomNo within the TblRoom table.
where to check if there is a query in the database?sorry this is my first time using microsoft access.
André Kraak 27-Nov-12 4:51am    
I tried finding something that shows where the queries are. This might help Queries For MS Access 2007[^].
nizam15 27-Nov-12 5:32am    
I did find the queries. But what I didn't understand is why is it when I change the queries I posted above to an actual table name within the database, it came up with an error :
"No value given for one or more required parameters."

as if that table doesn't exist.
_Vitor Garcia_ 28-Nov-12 5:02am    
My best guest is that QRoom is a query with parameters.
Find the query and see which parameter it is waiting for and act accordingly.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900