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?

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.

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

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.