473,789 Members | 2,342 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Datagrid control with Adodc?

Hi All!, I have a problem refreshing data on the Datagrid control. I execute
sql statement directly using the ADODC control and try to make it updated
onto the Datagrid control, however, the Datagrid control is not updated with
new data... here is the flagment of codes:

sql = "update MyTable set Col1='test' where Col1='nodata'"
adoMain.Records et.ActiveConnec tion.Execute sql
adoMain.Refresh
Set dgdMain.DataSou rce = adoMain
dgdMain.Refresh

pls tell me what I did wrong... thanks
Jul 17 '05 #1
1 3738
Ariane
2 New Member
try adding the line

dgdMain.DataCha nged = True

after all that you put there.
Jun 28 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
4615
by: Peyter | last post by:
I am trying to populate the standard vb ListBox control with an adodc control but it is not succeeding. I know that the adodc control is set up properly because if I connect it to a DataGrid control it populates. I set DataSource and DataField properties of the ListBox but when run, nothing is displayed (whereas, as I said, the DataGrid populates fine). Is this somekind of VB bug or am I missing something?
14
10733
by: marinho80 | last post by:
Hoping someone has experienced this before and can offer a solution. I have an app. that was designed in vb6. The app works with data from a SQL server, retrieves the data using the adodc (MSADODC.OCX) control and displaying data using the datagrid control.(MSDATGRD.OCX) Have had no problems to date with windows xp,successfully installed on more than 30 pc's all running windows xp, with the exception of 3 windows xp client machines where i...
4
1965
by: nkechifesie | last post by:
I have an adodc control that is build with several tables using the select command. I need to search for a record on the adodc, is it possibles? If yes, how?
1
1475
by: berry | last post by:
Hi all, I am now using vb6 to store and get the data according to the process, machine line and machine. Let say, Line A02, process texture, machines are m1, m2 and m3. The user might store the data many times for each machine(down time, in hour). So now, I want to seperate each machine data with each machine total hour. What should I do? I am using datagrid and adodc to get the data from the MySQLserver. Can I use many adodc for 1...
5
1340
by: berry | last post by:
Hi all, Can anyone help me?? I want to add all the values in the datagrid in a field to a text box. How do I do? The below is my code. But it only can display the first value. It cannot add all the values. Please have a look on it. Thank you very much... Dim total As Single total = 0 Do While Not Adodc.Recordset.EOF total = total + Adodc.Recordset.Fields("Hour") text1.Text = total ...
1
1032
by: alpnajain | last post by:
i am using datagrid control with the help of adodc.how i can arrange datagrid columns assending or decending order.
5
9407
by: vai | last post by:
i'm working in visual basic. i want to dispaly the records in a datagrid control who's data source is adodc.i want to display the records for a particular date. i.e. if the date which i accept from the user exists,then for that particular date all the records must be displayed. my problem is when i run my form all the records are displayed. the records ,which are in my access database table. so i set the following properties, ...
6
7115
by: jaz215 | last post by:
hi! in my program i'm using the find and bookmark function of the adodc control. as the people want me to use a normal data control, when i tried to run it using the same commands i've got an error. is there any other way to do this function through a data control? i'll post on what i've got but i it seems no to work. can anyone help me pls.. Dim counter As Integer counter = 0 adoEmployee.Recordset.MoveFirst Do While...
17
2556
lee123
by: lee123 | last post by:
I know this is a free site and the moderators or anybody don't have to answer if they don't want to.. but if there is someone who knows how to answer this question please help with this one. i have changed my project so many times to try to get the results i want but can't seem to get this one thing to work the datagrid and datalist to work right. i have looked on the web to see if i could do it another way. and read so many books but there...
0
9502
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10400
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10132
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9974
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9010
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7523
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6754
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5412
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
5544
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.