UITableViewController stops with (lldb) error after deleting Core Data record - core-data

Using storyboards, I have a few views connected. The first view displays all races. Once a race is clicked it is passed to the 2nd view controller, which displays all runners. The user can add/edit/delete runners on the 2nd view.
Everything works as expected if you add or edit records. Even deleting records works as long as you're on the 2nd view. If you have deleted any records, as soon as you press the button to navigate back to the original controller (standard UINavigation back button) the app stops and the only error is (lldb).
Any help is appreciated. Please let me know if additional details would be helpful.

Related

How to clear the page while pop in Flutter

I'm setting one Page that shows the Employees List in Card. While pressing on a specific Card, it navigate to another page that shows specific employee details. I added a back button in app bar to pop.
The Problem is when clicked first time, it shows the correct details. But when back button is pressed and another profile is clicked, the screen shows the same previous employee details.
What to know how to clear the Screen while pop in Flutter?
Well with no code or error logs ,its difficult to deduce the source of the error.However you could check into state management of you app, data source (is it fetching the right data from database, api etc), could you have hard coded the data.

AlertService directive in JHipster

I am using JHipster 3.3.0 and generated code using JDL.
Out of the box, each entity has its own popup dialog page for editing and saving data, i.e. {entity}-dialog.html. And after clicking the Save button, the dialog will close then the entity list page (i.e. {entity}s.html) will display the alert message 'A new <entity name> is created/updated with identifier {primary key}' to indicate outcome of save by using <jhi-alert-error></jhi-alert-error>.
Now I am implementing a one-to-many relationship for 2 entities, say User and Account(i.e. a User can have many Accounts)
such that the editing and saving of both entities happen in the same User page(i.e. User-dialog.html).
All Accounts of the User are displayed in an Account table, each row of the table will have a Save button to save data
of the Account after editing the data in the row.
This is all working fine. However, I noticed after clicking the Save button of Account row, I can see the background User list page
displaying the alert message mentioned above rather then in the current page.
I can't figure out how to display the alert message in the current page as opposed in the entity list page, which is the
default behavior.
I am missing some logic here. Any idea?
Basically, the <jhi-alert-error></jhi-alert-error> in my <entity>-dialog.html page is ignored and won't display message for outcome of successful save except for error message from Form validation.
Thanks in advance,
Sam
Ooops,silly me. Just found the answer.
The alert message 'A new is created/updated with identifier {primary key}' was displayed because the tag <jhi-alert></jhi-alert> was used, it was never
<jhi-alert-error></jhi-alert-error>.

Error When clicking on white space on a page in XPages

One of my clients has a replica copy of a database on two different Domino Servers. On one of the servers if the user clicks on any white space on a view or form they get the following error:
While the database on the test server does not throw this error. My server likewise does not throw this error either. as far as I can determine they are both running the same release of Domino.
I have search my code but can't find any reason for this error.
Any pointers where to look.
Check for eventHandlers on your page, looking for one associated to a component that does not have an ID. I think what happens is that if you have an eventHandler on a button, comboBox etc that does not have an ID, it gets associated to whatever contains the button, comboBox etc. So it triggers when you click in that area.
If you find one, add an ID and it will resolve the click problem.
I'm not 100% sure what the refreshId issue is, maybe the eventHandler in question is set refreshMode="partial" but not refreshId set, so it's trying to refresh the component containing the eventHandler, which is the one that doesn't have an ID. I could understand how that would cause a problem.

#SetViewInfo - Issue when clearing filter

I have a problem that have me stumped.
I have been searching for a solution, but haven't found a working one yet. The solutions I seen introduces other issues.
Here is the scenario:
I have a frameset with two frames: 'Navigator' and 'Main'.
In the 'Navigator' frame I display a form called 'Navigator'. It contains an outline, to display a menu.
In the 'Main' frame I display the view selected by the user in the navigator.
So this is a very traditional Notes client application.
I now want to add a checkbox at the top of the view (in the action bar), allowing the user to filter the view by his/her own name. I use #SetViewInfo for this, and it all works perfect.
The issue is when the user switch views. The #SetViewInfo filter stays active when switching to a different view, so after some searching I found some solutions:
In http://www-01.ibm.com/support/docview.wss?uid=swg21204481 IBM suggests to put the following code in the QuerySave event:
#SetViewInfo([SetViewFilter]; temp ; 0 ;1)
When I am switching view or closing the view, I get the error message "Cannot execute the specified command".
In http://www-10.lotus.com/ldd/bpmpblog.nsf/dx/using-setviewinfo-in-a-notes-client-application-to-create-a-user-specific-view Andre Guirard suggests to put the following code in the QuerySave event:
#SetTargetFrame("frameName");
#UpdateFormulaContext;
#Command([OpenView]; #Subset(#ViewTitle; -1));
#SetViewInfo([SetViewFilter]; ""; "columnName"; 1)
I modify this to match my frame name and the programatic name of the first column in my view:
#SetTargetFrame("Main");
#UpdateFormulaContext;
#Command([OpenView]; #Subset(#ViewTitle; -1));
#SetViewInfo([SetViewFilter]; ""; "Adjuster"; 1)
This works perfectly when switching between view. But when I close the application while I am in this particular filtered view, the application is re-opened automatically. This happens no matter if the filter is enabled or not when closing the view.
However, when the view repopens, the frameset is not reloaded, it is just the view with the built-in view navigator to the left.
I finally got this to work by (in the built-in view navigator) selecting another view that the one where I filter data. This fixed the issue for a while, but then it starts again, and the filtered view is active in the navigator.
Obviously it is the OpenView command that is causing this, but if I remove just that line, I get the "Cannot execute the specified command" error again.
Any suggestions/pointers? I am using Notes 8.5.3 running on Windows 7 Professional.
This question can also be found in the IBM developerWorks forum for Notes 8.5:
http://www-10.lotus.com/ldd/nd85forum.nsf/DateAllThreadedWeb/08c73910571306c485257b2b0061ef91
First thing, I would suggest to make sure your view frame is always called "NotesView". You will have much less compatibility issues if you do this.
Secondly, I presume when you say you put it in the QuerySave event you really mean the QueryClose event? Views do not have a QuerySave event.
Thirdly, I find the #UpdateFormulaContext line is not needed. This is what I have in my view QueryClose...
#SetTargetFrame("NotesView");
#Command([OpenView]; #Subset(#ViewTitle; -1));
#SetViewInfo([SetViewFilter]; ""; "<programmaticColumnName>"; 1)
And I can close the app while in the view without any problems.

Have to push button twice to get partial refresh to work

Background: Xpage with multiple data sources. Each row of tabbed table contains an edit panel bound to a different data source than the main page. Each page contains a table to enter new documents. These documents are children of the main document. There is a view control that shows the user created documents immediately. The button in the table saves the document in addition to adding some control fields. It does a partial refresh of the editPanel.
Recently I added validation to the fields in the entry table. I use a function, and prevent updating from anything but the button. I am using Tommy Valand's method from this blog post: http://dontpanic82.blogspot.com/2010/03/xpages-making-validation-behave.html. If I don't use Tommy's method, then the validators fire when switching tabs, and are useless.
All of this works sort of, but I am experiencing the following issues.
1) I have to push the button twice to get the partial refresh to fire. Not only that, but the validation messages to not fire until the button is pushed twice. The first part was still an issue prior to adding the validation.
2) The table values do not clear after the refresh does happen. This used to work prior to adding the validation. The only way to get the values to clear now, is to do a full refresh (F5).
I really just need partial refresh to behave like it should. Any help is greatly appreciated.
I am answering my own question because I think that I might have found out why the partial refresh was acting so flaky. Here is what I did that solved my issues: Each tab had an editPanel. If I make the edit panel do a partial refresh to itself then the buttons on that panel seems to behave as you would expect them to.
When I create a new core control panel, the default in No submission. I do not know whether this issue manifests itself only when using multiple data sources and/or tabbed tables. Hopefully this fix will be of use to someone down the road. It is worth a try if you are having issues with partial refresh working correctly.

Resources