• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 324
  • Last Modified:

Editing results from a ADODataset and another question!

Part of a program im making has a diary where the data is drawn from an access table and searched by date using the ADODataset commandtext thing. This works fine and displays the results. but now i want to be able to edit these results and delete them (basically editing and deleting bookings) but im using the DBnavigator.btnclick(nbedit) thing so when i click on the cell it allows me to edit like a normal DBGrid. However because the data is a result of a search, it wont work and displays the error "Insufficient base table information for updating or refeshing." does any one have any ideas????

Also in another form, im calling the print function to print out the form which works fine but i want to set the print orientation to landscape at runtime to make life easier for the user. someone mentioned POLandscape but i dont know how to write this into my code.

Many thanks
0
babbels4princess
Asked:
babbels4princess
1 Solution
 
ImbeginnerCommented:
at first some thing about TADODATASET in DELPHI help:

Use the TADODataSet component's CommandText property to retrieve the dataset, specifying either a table name or an SQL  statement (SELECT only). TADODataSet is not capable of issuing Data Manipulation Language (DML) SQL statements that do not  return result sets (like DELETE, INSERT, and UPDATE). For this use a component like TADOCommand or TADOQuery.

yes you cant manipulate the dataset that return by TADOdataset.
if you want to manipulate data with dbnavigatoe use of TAdotable.
pay attention that you cant manipulate the result of select statement with dbnavigator.


regards
m.reza
0
 
CleanupPingCommented:
babbels4princess:
This old question needs to be finalized -- accept an answer, split points, or get a refund.  For information on your options, please click here-> http:/help/closing.jsp#1 
EXPERTS:
Post your closing recommendations!  No comment means you don't care.
0
 
snehanshuCommented:
Hi!
No comment has been added lately and this question is therefore classified abandoned.

If asker wishes to close the question, then refer to
http://www.experts-exchange.com/help/closing.jsp

Otherwise, I will leave a recommendation in the Cleanup topic area that this question is:

Answered by: Imbeginner

Please leave any comments here within the next seven days. It is assumed that any participant not responding to this request is no longer interested in its final disposition.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!

...Snehanshu
EE Cleanup Volunteer
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now