Jump to content
Ian Branch

Loss of Datasouce??

Recommended Posts

Hi Team,

D10.4.2.

Revisiting some large projects to update them, I have discovered that DB components have lost either their DataSource and/or their MasterSource.

Anybody got any idea why/how this may have happened??

Now I have to go through each DB component, including ttables and tquerys to check their Data/Master Sources.. 😞

 

Regards & TIA,

Ian

Share this post


Link to post

If you have an older version of the code, then look through the DFMs with BeyondCompare or something similar and search for these component type names, then compare their properties.

Edited by David Schwartz

Share this post


Link to post

Hi David,

I have been able to do just that, but I am more concerned/interested in how/why it happened so I can take any necessary steps to prevent a repeat.

 

Ian

Share this post


Link to post

I think of only one possibility. The DataSource has been physically deleted or relocated. Which is basically the same.

Share this post


Link to post

This can also happen when the missing DataSource is not located at the same form/frame as the DB components and the IDE fails to open the datamodule (or wherever this datasource resides) for whatever reasons. I had similar experiences with actions located in a datamodule. If by any chance that datamodule shares its name with one of the IDE internal ones (including those in 3rd party modules) that can be the cause of breaking the linkage.

Share this post


Link to post
Guest

Yes, @Uwe Raabe is correct IMHO, happened to me several times but with the Image property mostly. It adds up, i do have imageLists in DMs.

My DataSource connections are local to the DB and those that are not (resides on a form) are re-assigned at runtime, so i did not have the problem re DataSource.

The source control system is a necessity when this happens.

Share this post


Link to post

Sometimes it helps to rename the datamodule to avoid a name clash with the internal one. Naming a datamodule dmImages may be OK for a standalone application, but for an IDE plugin that seems not to be wise. I made this experience myself.

  • Like 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×