Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Inserting a Column in a DataGrid

Posted on 2004-04-01
3
Medium Priority
?
180 Views
Last Modified: 2010-04-05
I want to insert a numeric column in a Data Grid, amung the table's defined fields.

The column's user input values will be used for calculations.

My attempts have achived the insertion of a column, by adding a NEW FIELD to the ADOQuery control, giving it a TYPE of 'integer' and selecting 'Calculated' for FIELD TYPE.

But the application wont allow for the manual input of values into its cells, which is what I want.

How do I do this?
0
Comment
Question by:ziche
3 Comments
 
LVL 11

Expert Comment

by:shaneholmes
ID: 10734658
Calculated fields are just that, calculated. They do not exist physically.

You will have to physically add a new column to your table

1.) Using the maintenance app of your desired database
2.) by runtime code
3.) SQL

What database are you using?

Shane

0
 

Author Comment

by:ziche
ID: 10738544
Im using an Access db connected to my application using ADO controls.

How exactly do I go about doing the 3 points you have suggested?
0
 
LVL 3

Accepted Solution

by:
ThoseBug earned 50 total points
ID: 10756445
Just in your ADO query....
select
 Field1,
 field 2,
 Int_Field_Created
from your_Table

and add all fields (double click into ADOQuery component) then set Int_FieldCreated readonly to false.....now aasign the adoquery to dataset and a DBGIRD to dataset ...that's all....


TB
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Integration Management Part 2
Despite its rising prevalence in the business world, "the cloud" is still misunderstood. Some companies still believe common misconceptions about lack of security in cloud solutions and many misuses of cloud storage options still occur every day. …

886 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