Hello!
Have you checked the code for me! Please!
ModuleController objModules = new ModuleController();
foreach (KeyValuePair<int, ModuleInfo> kvp in objModules.GetTabModules(64)) //64 is from tabid
{
ModuleInfo objModule = kvp.Value;
// if the module shows on all pages does not need to be copied since it will
// be already added to this page
if (!objModule.AllTabs)
{
objModule.TabID = 100;//to tabid
objModules.AddModule(objModule);
}
}
Error:
A critical error has occurred.
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_Modules_ModuleDefinitions". The conflict occurred in database "MYDNN", table "dbo.ModuleDefinitions", column 'ModuleDefID'. The statement has been terminated.
Help me! please!
Thanks!
A critical error has occurred.
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_ndk_Modules_ndk_ModuleDefinitions". The conflict occurred in database "ALOSHOPS", table "dbo.ndk_ModuleDefinitions", column 'ModuleDefID'. The statement has been terminated. |
A critical error has occurred.
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_ndk_Modules_ndk_ModuleDefinitions". The conflict occurred in database "ALOSHOPS", table "dbo.ndk_ModuleDefinitions", column 'ModuleDefID'. The statement has been terminated. |