Solved

Link a field in excel worksheet to a textbox on a delphi form via ADO

Posted on 2003-10-28
1
777 Views
Last Modified: 2010-04-16
Hi all,
I have managed to create connection to the excel  worksheet and i can show it in datagrid. Now I have 2 problems:

1) how to link a particular field (name) in excel worksheet to a textbox on the delphi form.

2) any link that can show me how to add and update records in excel worksheet via ADO Connection?

Thax.
Rice Cake
0
Comment
Question by:antioch_75
1 Comment
 
LVL 1

Accepted Solution

by:
JackNaif earned 250 total points
ID: 9637774
1) Instead of a normal edit box try using a dbedit. (I assume that when you say a datagrid you mean a dbgrid. dbedit is similar, but it's got one mor DB related property to choose the field it's going to contain.

2) At http://www.phidels.com/php/zip/oleexcel.zip you have a wonderfull example of how to interact with Excel but a) it's in French b) it uses Ole rather than Ado.

Anyway, if you already know how to use a normal Dataset to update and add records, and you've managed to open the excel via ADO, then updating and adding records through ADO should be a piece of cake because the TADODataSet has all the same methods and properties and events than the TDataSet. You shouldn't need too much of an example to do it.

Hope it helps:

Jack
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Delphi XE10, DigitalPersona Fingerprint reader and MySQL 6 224
delphi prevent click fast 2 192
HTML text in the body of an email (delphi code) 12 98
LAN or WAN ? 11 83
A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
In this video I am going to show you how to back up and restore Office 365 mailboxes using CodeTwo Backup for Office 365. Learn more about the tool used in this video here: http://www.codetwo.com/backup-for-office-365/ (http://www.codetwo.com/ba…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now