display textbox values based on combobox selection?(windows applications)

Posted by Sudheep.grandhe under C# on 12/9/2011 | Points: 10 | Views : 2640 | Status : [Member] | Replies : 1
Hi,


i am having the tables like tbl_report1,tbl_report2 .i combine these two tables and retrieve the data and structure into tbl_customer.

tbl_report1 columns:
invoiceno(fk),orderno,paritculars,quantity,perprice,amount,invoicedate,ondate,compname,invoiceid

tbl_report2 columns:
compname,compaddress,invoiceno(pk),orderno,invoicedate,ondate,amountstatus,netamount,netvat,tamount

select t2.compname,t2.compaddress,t2.invoiceno,t2.orderno,t2.ondate,t2.invoicedate,t2.amountstatus,t2.netamount,t2.netvat,t2.tamount,t1.particulars,t1.quantity,t1.perprice,t1.amount INTO tbl_report12 from tbl_report1 t1 RIGHT OUTER JOIN tbl_report2 t2 on t1.invoiceno=t2.invoiceno

if i execute the above query it shows the particulars,quantity,perprice,amount columns are null.
if i execute the tbl_report1 in this invoiceno column values shows null.but,in tbl_report2 the column invoiceno shows values.i dont no where i did the mistake.can you please help me.please do the needful.

tbl_company columns-custid(pk),custname,custaddress,custstate,custcity,custstdcode,custphoneno,custmobilno.i created the relationship between tbl_report1(fk),tbl_report2(pk).i am not able to getting how can i make relation betwee tbl_customer.can you help me.
i want to combine above both tables and getting data and structure into tbl_customer.how can i wrote the query for the above tables.please do the needful.

Best,
Sudheep.



Responses

Posted by: Naraayanan on: 12/29/2011 [Member] Starter | Points: 25

Up
0
Down
hi,
try this way:

First Fill the data in the ComboBox.
second paste this code in combobox SelectedIndexChanged Event
    textBox1.Text = comboBox1.Text;

(your textbox name) = your comboboxname)


Regards,
Lakshmi Naraayanan.S
http://dotnettechrocks.blogspot.in/
http://abaprocker.blogspot.com/

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response