0

sir
I design a small application in vb (Windows-xp system) which displays the records from the sql database tables. Entering a table name in the text box and clicking the Button, its records are displayed in the data grid. The code for the button is

adodc1.recordsource="select * from " & txttable.text
adodc1.refresh
set datagrid.datasource=adodc1

The code works fine . when I create a setup program for it and install on a system running windows Vista, the application runs Ok without any error but the grid is not filled with any record. any help or suggestion plz?

2
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by Bashir ahmad
0

Have you tried binding your data to your grid?

adodc1.recordsource = "select * from " & txttable.text
adodc1.refresh
set datagrid.datasource = adodc1
datagrid.DataBind()

Which version of VB are you using? You posted this in a VB 4/5/6 forum, but it looks like you may be using .NET.

0

thx for the reply
I m using vb6 with windows xp. the problem mentioned here works well on my system but not on with windows vista.The program runs on windows vista but doesnot display records.There is not even an error message shown. moreover I have never find a need of using line 4 in any of my programs, only line 3 is enough to populate datagrid with records.

with kind regards

Bashir

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.