Guest User

Untitled

a guest
Dec 14th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. void SetMasterDetailPositions(int masterId, int detailId)
  2. {
  3. var masterPosition = masterBindingSource.Find("id", masterId);
  4. if (0 <= masterPosition)
  5. {
  6. masterBindingSource.Position = masterPosition;
  7. var detailPosition = detailBindingSource.Find("id", detailId);
  8. if (0 <= detailPosition)
  9. {
  10. detailBindingSource.Position = detailPosition;
  11. }
  12. }
  13. }
  14.  
  15. var detailPosition = detailBindingSource.Find("id", detailId);
  16.  
  17. System.ArgumentException occurred
  18. HResult=0x80070057
  19. Message=DataMember property 'id' cannot be found on the DataSource.
Add Comment
Please, Sign In to add comment