diff --git a/PROMS/VEPROMS User Interface/frmVersionsProperties.cs b/PROMS/VEPROMS User Interface/frmVersionsProperties.cs index 9c54446b..196b5239 100644 --- a/PROMS/VEPROMS User Interface/frmVersionsProperties.cs +++ b/PROMS/VEPROMS User Interface/frmVersionsProperties.cs @@ -1484,7 +1484,16 @@ namespace VEPROMS foreach (DocVersionAssociation dva in _DocVersionConfig.MyDocVersion.DocVersionAssociations) { - RODbInfo rdi = RODbInfo.Get(dva.ROFst_RODbID); + // B2023-020: Link to RO data from new working draft crashes/various ro.fst issues. This code was using an + // non-loaded rodbid from the docversion association (query was changed to not return related rofst data + // to improve memory/performance). Instead, the SelectedROFst can be used to get the rodbid. + int rodbid = SelectedROFst==null?-1:SelectedROFst.RODbID; + if (rodbid < 1) + { + MessageBox.Show("Could not get associated ro.fst ", "No existing RO.FST"); + return; + } + RODbInfo rdi = RODbInfo.Get(rodbid); // B2023-020: use the rodbid from the SelectedROFst string rofstPath = rdi.FolderPath + @"\ro.fst"; if (!File.Exists(rofstPath)) diff --git a/PROMS/VEPROMS.CSLA.Library/Generated/DocVersionAssociation.cs b/PROMS/VEPROMS.CSLA.Library/Generated/DocVersionAssociation.cs index 2257d29b..ec86d357 100644 --- a/PROMS/VEPROMS.CSLA.Library/Generated/DocVersionAssociation.cs +++ b/PROMS/VEPROMS.CSLA.Library/Generated/DocVersionAssociation.cs @@ -434,12 +434,14 @@ namespace VEPROMS.CSLA.Library _DTS = dr.GetDateTime("DTS"); _UserID = dr.GetString("UserID"); dr.GetBytes("LastChanged", 0, _LastChanged, 0, 8); - _ROFst_RODbID = dr.GetInt32("ROFst_RODbID"); + // B2023-020: setting RO Database on new working draft crashes. Query 'getAssociationsByVersionID' had been modified + // for memory improvements to not return the ROFst values, so don't Get the values. Comment out for now. + //_ROFst_RODbID = dr.GetInt32("ROFst_RODbID"); //_ROFst_ROLookup = (byte[])dr.GetValue("ROFst_ROLookup"); _ROFst_ROLookup = null; // B2022-026 RO Memory reduction - use ROlookup of null to know if we loaded the RO.FST file - _ROFst_Config = dr.GetString("ROFst_Config"); - _ROFst_DTS = dr.GetDateTime("ROFst_DTS"); - _ROFst_UserID = dr.GetString("ROFst_UserID"); + //_ROFst_Config = dr.GetString("ROFst_Config"); + //_ROFst_DTS = dr.GetDateTime("ROFst_DTS"); + //_ROFst_UserID = dr.GetString("ROFst_UserID"); } catch (Exception ex) // FKItem Fetch {