HELP with TTable?

HELP with TTable?

Post by Robin C. Goldber » Thu, 27 Nov 1997 04:00:00

I'm trying to post data but I get dataset not in Edit mode.

I'm using a datamodule with a table defined on on -  dsUnitInfo,

I have one dbedit field on a form with and ID in it.  In code I set the
table to edit,
by doing this : module.table.Edit;  This works fine as long as I'm on that
first form.

When I leave the form, I post the data.  When I return the table is not
getting set back into Edit Mode on the show method.  So when I close it I
get "can't post cause not in Edit mode'.  I've tried to check to make sure
I was in edit mode but I can't seem to figure out the right syntax.  This
is what I've tried.

if module.table.modified (doesn't work)

if module.dataset.state <> edit (didn't work)

How can I tell if the table is in edit mode?

Any help or guidance would be appreciated.  Also any ideas on what I should
read to understand this better would help too.

Thanks -


1. Hey, TEAMB...Need some real help with TTable and CreateTable in SQL Back end

I am using Delphi 3.0 and need to create an InterBase 5 table.

I am using a TTable component and have populated the FieldDefs
property. When I call the CreateTable method things work fine. When I
include a IndexDefs statement (IndexDefs.Add('','Field1',[ixUnique])
and call the CreateTable method I get an error "INvalid Index/Tag
name". Where is this coming from and how do I fix it? I have to create
2 indexes (one primary and one secondary) and can't seem to get around
this. I cannot use TQueries here...need on a TTable. When I run the
same thing against Paradox it works just fine.

Any help on fixing this is greatly appreciated!


Programmer / Analyst
New England Research Institutes

"I believe that five out of
     four people have trouble with fractions."


          \\ ~ ~ //


2. Using parameters in SELECT

3. Need help on TTable inside a CGI

4. Developer thoughts

5. Help with TTable.Constraints ...

6. Queries on network management

7. HELP!! TQuery vs TTable

8. Text Conversion: Access Specific

9. Help: TTable record number?

10. HELP: TQuery.Locate vs TTable.Locate ?

11. Help using the TTable.Locate command

12. TTable.Recordcount!

13. Delphi 1.x - TTable.Modified bug - HELP !!