locked
LIST AND DETAIL SCREEN RRS feed

  • Question

  • I have a problem with List and Detail screen.

    I have one entity(parent) on the left side and child entity displayed on the right bottom side as in Beth Massi How Do I videos.

    When I add parent entity on the left, all details are displayed on the right top side and then I can start addin new child entities to the right bottom side of screen.

    The problem is that when I add parent entity and add some new child entity without saving the parent one and then hit save, LS says that record was deleted by another user. So I have to save the parent entity first before adding new child entity. I tried to change relationship between them to restricted (I want cascade delete) but it doesnt make any different.

    What is the reason?

    Thank You

    Tuesday, February 5, 2013 2:56 PM

Answers

  • Thanks for your time,

    I finally found out what was the problem. After installing WCF Data Services Update, I can not use Slovak language letters in entity and screen names.

    My table had name Položka and letter "ž" made whole problem.

    My app was nearly done but I have to start again because when I rename that table, error list is filled with about 100 errors and I have 7 more tables, about 10 queries and many screens named with diacritic. Rebuilding app did not make any difference...

    Hope this bug will be fixed but I will never use diacritic again...

    • Marked as answer by eMCeee89 Saturday, February 9, 2013 12:21 PM
    Saturday, February 9, 2013 12:21 PM

All replies

  • You definitely can add a parent record, along with some associated child records, without needing to save the parent first.

    For example, you can add an Invoice entity, then add some child InvoiceLine items (ie the newly added Invoice is their parent), then click Save. Both the parent Invoice, & the child InvoiceLines will be saved.

    So there must be something not quite right with your screen. How did you get the child collection on the screen? Did you tick a box during the wizard, or did you do it yourself after the screen was created?


    Yann - LightSwitch Central - Click here for FREE Themes, Controls, Types and Commands
     
    Please click "Mark as Answer" if a reply answers your question. Please click "Vote as Helpful" , if you find a reply helpful.
     
    By doing this you'll help others to find answers faster.

    Wednesday, February 6, 2013 7:23 AM
    Moderator
  • Hey Yann,

    I tried to create new screen and I used query and not query as a data source and also tried to create screen with ticked and also unticked box in the wizard. So I created 4 screens but still the same problem. It says that another user deleted record when saving.

    Also tried to change desktop/web type of application and also forms authentication/ no authentication.

    Nothing changed....awwwwwwww

    Wednesday, February 6, 2013 5:21 PM
  • Maybe a screenshot will help understand the problem better?
    Wednesday, February 6, 2013 8:11 PM
  • I have changed culture to English for you.

    This is what I got when I do not save parent entity. Data conflict (shown in the picture) is with child entity....


    • Edited by eMCeee89 Wednesday, February 6, 2013 8:23 PM
    Wednesday, February 6, 2013 8:17 PM
  • Any thoughts?

    I have deleted everything (only parent and child left, all calculated fields removed, all extensions disabled) from my app and problem still presists.

    It looks like a bug or something. Crap...


    • Edited by eMCeee89 Friday, February 8, 2013 8:11 PM
    Friday, February 8, 2013 8:10 PM
  • Did you change anything on say a different screens tab before trying to save? For instance if your current tab/screen had an auto-complete box that relied upon entries in a different entity say product. but now that product was deleted it may cause this. If so hit refresh or save both screens and try again. I do not think that having more detail entities with calculated fields or using extensions should interfere with the basic relationships of tables and queries on tables I would leave all of that untouched and focus on what data you have entered already. When you try and save their should be a drop down at the top of the tab that says which fields your data entry error is in. click on the read to show that and read what that says see if you can remember changing data or options lists related to that that might not be their anymore.

    Friday, February 8, 2013 8:55 PM
  • Thanks for your time,

    I finally found out what was the problem. After installing WCF Data Services Update, I can not use Slovak language letters in entity and screen names.

    My table had name Položka and letter "ž" made whole problem.

    My app was nearly done but I have to start again because when I rename that table, error list is filled with about 100 errors and I have 7 more tables, about 10 queries and many screens named with diacritic. Rebuilding app did not make any difference...

    Hope this bug will be fixed but I will never use diacritic again...

    • Marked as answer by eMCeee89 Saturday, February 9, 2013 12:21 PM
    Saturday, February 9, 2013 12:21 PM
  • You could try going through the *.lsml files in your LightSwitch project and manually fix the names that had "ž" in them before starting over.

    Justin Anderson, LightSwitch Development Team

    Saturday, February 9, 2013 12:31 PM
    Moderator
  • Yes, but there is more of like "ž" letters in my project.

    I have still enough time so this will be another practice for me :)


    • Edited by eMCeee89 Saturday, February 9, 2013 12:35 PM
    Saturday, February 9, 2013 12:34 PM