{"action":"created","comment":{"url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/comments/58517039","id":58517039,"diff_hunk":"@@ -19,22 +19,80 @@ Public Class dlgSplitText\n     Private Sub dlgSplitText_Load(sender As Object, e As EventArgs) Handles MyBase.Load\r\n         autoTranslate(Me)\r\n \r\n-        If bFirstLoad Then\n-            InitialiseDialog()\n-            SetDefaults()\n-            bFirstLoad = False\n+        If bFirstLoad Then\r\n+            InitialiseDialog()\r\n+            SetDefaults()\r\n+            bFirstLoad = False\r\n         End If\r\n     End Sub\r\n \r\n+    Private Sub TestOKEnabled()\r\n+        If ucrReceiverSplitTextColumn.IsEmpty() = False Then\r\n+            ucrBase.OKEnabled(True)\r\n+        Else\r\n+            ucrBase.OKEnabled(False)\r\n+        End If\r\n+\r\n+    End Sub\r\n+\r\n     Private Sub InitialiseDialog()\r\n+        ucrReceiverSplitTextColumn.Selector = ucrSelectorSplitTextColumn\r\n+        ucrReceiverSplitTextColumn.SetMeAsReceiver()\r\n+        ucrBase.clsRsyntax.SetFunction(\"stringr::str_split_fixed\")\r\n+        ucrReceiverSplitTextColumn.SetDataType(\"factor\")\r\n+        ucrBase.clsRsyntax.AddParameter(\"pattern\", Chr(34) & \" \" & Chr(34))\r\n+        ucrInputColumnsIntoText.SetName(\"SplitText\")\r","path":"instat/dlgSplitText.vb","position":30,"original_position":30,"commit_id":"2ac493c00c4bad6d0fa4abea57a14a8f7f2e676d","original_commit_id":"2ac493c00c4bad6d0fa4abea57a14a8f7f2e676d","user":{"login":"dannyparsons","id":11214914,"avatar_url":"https://avatars.githubusercontent.com/u/11214914?v=3","gravatar_id":"","url":"https://api.github.com/users/dannyparsons","html_url":"https://github.com/dannyparsons","followers_url":"https://api.github.com/users/dannyparsons/followers","following_url":"https://api.github.com/users/dannyparsons/following{/other_user}","gists_url":"https://api.github.com/users/dannyparsons/gists{/gist_id}","starred_url":"https://api.github.com/users/dannyparsons/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dannyparsons/subscriptions","organizations_url":"https://api.github.com/users/dannyparsons/orgs","repos_url":"https://api.github.com/users/dannyparsons/repos","events_url":"https://api.github.com/users/dannyparsons/events{/privacy}","received_events_url":"https://api.github.com/users/dannyparsons/received_events","type":"User","site_admin":false},"body":"That's not really right question. If you're not sure what goes where you should be asking \"how do we decide what goes in Initialise and what goes in SetDefaults?\" so that you can do this yourself without needing me each time.\r\nThe basic idea is that Initialise is only run once, on the first load, so it contains everything that only needs to happen once and will never change, even when the dialog is running, the user can't change these things. So since they can't change, they never need to be run more than once.\r\nSetDefaults is run on first load AND when you reset the dialog. It contains everything that we want in the dialog as a default BUT it might be changed by the user when the dialog is running, so if we reset the dialog we need to reset to our default values. \r\nThat is why the SetName goes in SetDefaults(), because the user can change this input text and we want to be able to reset it when we click Reset.\r\nI hope that helps, now have a think about the lines that you asked me about and see if you can decide the correct place for them to be.","created_at":"2016-04-05T10:40:45Z","updated_at":"2016-04-05T10:40:45Z","html_url":"https://github.com/africanmathsinitiative/Instat/pull/1153#discussion_r58517039","pull_request_url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153","_links":{"self":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/comments/58517039"},"html":{"href":"https://github.com/africanmathsinitiative/Instat/pull/1153#discussion_r58517039"},"pull_request":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153"}}},"pull_request":{"url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153","id":64918002,"html_url":"https://github.com/africanmathsinitiative/Instat/pull/1153","diff_url":"https://github.com/africanmathsinitiative/Instat/pull/1153.diff","patch_url":"https://github.com/africanmathsinitiative/Instat/pull/1153.patch","issue_url":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/1153","number":1153,"state":"open","locked":false,"title":"dlgSplitText","user":{"login":"Lunalo","id":13945088,"avatar_url":"https://avatars.githubusercontent.com/u/13945088?v=3","gravatar_id":"","url":"https://api.github.com/users/Lunalo","html_url":"https://github.com/Lunalo","followers_url":"https://api.github.com/users/Lunalo/followers","following_url":"https://api.github.com/users/Lunalo/following{/other_user}","gists_url":"https://api.github.com/users/Lunalo/gists{/gist_id}","starred_url":"https://api.github.com/users/Lunalo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lunalo/subscriptions","organizations_url":"https://api.github.com/users/Lunalo/orgs","repos_url":"https://api.github.com/users/Lunalo/repos","events_url":"https://api.github.com/users/Lunalo/events{/privacy}","received_events_url":"https://api.github.com/users/Lunalo/received_events","type":"User","site_admin":false},"body":"Implementing dlgSplitText","created_at":"2016-04-01T09:31:21Z","updated_at":"2016-04-05T10:40:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5509e307b32dc144f227917de4b10bf4384567d6","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153/commits","review_comments_url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153/comments","review_comment_url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/comments{/number}","comments_url":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/1153/comments","statuses_url":"https://api.github.com/repos/africanmathsinitiative/Instat/statuses/2ac493c00c4bad6d0fa4abea57a14a8f7f2e676d","head":{"label":"Lunalo:ManageMenu","ref":"ManageMenu","sha":"2ac493c00c4bad6d0fa4abea57a14a8f7f2e676d","user":{"login":"Lunalo","id":13945088,"avatar_url":"https://avatars.githubusercontent.com/u/13945088?v=3","gravatar_id":"","url":"https://api.github.com/users/Lunalo","html_url":"https://github.com/Lunalo","followers_url":"https://api.github.com/users/Lunalo/followers","following_url":"https://api.github.com/users/Lunalo/following{/other_user}","gists_url":"https://api.github.com/users/Lunalo/gists{/gist_id}","starred_url":"https://api.github.com/users/Lunalo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lunalo/subscriptions","organizations_url":"https://api.github.com/users/Lunalo/orgs","repos_url":"https://api.github.com/users/Lunalo/repos","events_url":"https://api.github.com/users/Lunalo/events{/privacy}","received_events_url":"https://api.github.com/users/Lunalo/received_events","type":"User","site_admin":false},"repo":{"id":55217216,"name":"Instat","full_name":"Lunalo/Instat","owner":{"login":"Lunalo","id":13945088,"avatar_url":"https://avatars.githubusercontent.com/u/13945088?v=3","gravatar_id":"","url":"https://api.github.com/users/Lunalo","html_url":"https://github.com/Lunalo","followers_url":"https://api.github.com/users/Lunalo/followers","following_url":"https://api.github.com/users/Lunalo/following{/other_user}","gists_url":"https://api.github.com/users/Lunalo/gists{/gist_id}","starred_url":"https://api.github.com/users/Lunalo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Lunalo/subscriptions","organizations_url":"https://api.github.com/users/Lunalo/orgs","repos_url":"https://api.github.com/users/Lunalo/repos","events_url":"https://api.github.com/users/Lunalo/events{/privacy}","received_events_url":"https://api.github.com/users/Lunalo/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Lunalo/Instat","description":"Development of the new version of Instat","fork":true,"url":"https://api.github.com/repos/Lunalo/Instat","forks_url":"https://api.github.com/repos/Lunalo/Instat/forks","keys_url":"https://api.github.com/repos/Lunalo/Instat/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Lunalo/Instat/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Lunalo/Instat/teams","hooks_url":"https://api.github.com/repos/Lunalo/Instat/hooks","issue_events_url":"https://api.github.com/repos/Lunalo/Instat/issues/events{/number}","events_url":"https://api.github.com/repos/Lunalo/Instat/events","assignees_url":"https://api.github.com/repos/Lunalo/Instat/assignees{/user}","branches_url":"https://api.github.com/repos/Lunalo/Instat/branches{/branch}","tags_url":"https://api.github.com/repos/Lunalo/Instat/tags","blobs_url":"https://api.github.com/repos/Lunalo/Instat/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Lunalo/Instat/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Lunalo/Instat/git/refs{/sha}","trees_url":"https://api.github.com/repos/Lunalo/Instat/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Lunalo/Instat/statuses/{sha}","languages_url":"https://api.github.com/repos/Lunalo/Instat/languages","stargazers_url":"https://api.github.com/repos/Lunalo/Instat/stargazers","contributors_url":"https://api.github.com/repos/Lunalo/Instat/contributors","subscribers_url":"https://api.github.com/repos/Lunalo/Instat/subscribers","subscription_url":"https://api.github.com/repos/Lunalo/Instat/subscription","commits_url":"https://api.github.com/repos/Lunalo/Instat/commits{/sha}","git_commits_url":"https://api.github.com/repos/Lunalo/Instat/git/commits{/sha}","comments_url":"https://api.github.com/repos/Lunalo/Instat/comments{/number}","issue_comment_url":"https://api.github.com/repos/Lunalo/Instat/issues/comments{/number}","contents_url":"https://api.github.com/repos/Lunalo/Instat/contents/{+path}","compare_url":"https://api.github.com/repos/Lunalo/Instat/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Lunalo/Instat/merges","archive_url":"https://api.github.com/repos/Lunalo/Instat/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Lunalo/Instat/downloads","issues_url":"https://api.github.com/repos/Lunalo/Instat/issues{/number}","pulls_url":"https://api.github.com/repos/Lunalo/Instat/pulls{/number}","milestones_url":"https://api.github.com/repos/Lunalo/Instat/milestones{/number}","notifications_url":"https://api.github.com/repos/Lunalo/Instat/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Lunalo/Instat/labels{/name}","releases_url":"https://api.github.com/repos/Lunalo/Instat/releases{/id}","deployments_url":"https://api.github.com/repos/Lunalo/Instat/deployments","created_at":"2016-04-01T08:45:06Z","updated_at":"2016-04-01T08:45:10Z","pushed_at":"2016-04-05T09:24:49Z","git_url":"git://github.com/Lunalo/Instat.git","ssh_url":"git@github.com:Lunalo/Instat.git","clone_url":"https://github.com/Lunalo/Instat.git","svn_url":"https://github.com/Lunalo/Instat","homepage":null,"size":6866,"stargazers_count":0,"watchers_count":0,"language":"Visual Basic","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"africanmathsinitiative:master","ref":"master","sha":"243f6a4476a638cfcbfce0590524667e845c25ae","user":{"login":"africanmathsinitiative","id":13917566,"avatar_url":"https://avatars.githubusercontent.com/u/13917566?v=3","gravatar_id":"","url":"https://api.github.com/users/africanmathsinitiative","html_url":"https://github.com/africanmathsinitiative","followers_url":"https://api.github.com/users/africanmathsinitiative/followers","following_url":"https://api.github.com/users/africanmathsinitiative/following{/other_user}","gists_url":"https://api.github.com/users/africanmathsinitiative/gists{/gist_id}","starred_url":"https://api.github.com/users/africanmathsinitiative/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/africanmathsinitiative/subscriptions","organizations_url":"https://api.github.com/users/africanmathsinitiative/orgs","repos_url":"https://api.github.com/users/africanmathsinitiative/repos","events_url":"https://api.github.com/users/africanmathsinitiative/events{/privacy}","received_events_url":"https://api.github.com/users/africanmathsinitiative/received_events","type":"Organization","site_admin":false},"repo":{"id":44009238,"name":"Instat","full_name":"africanmathsinitiative/Instat","owner":{"login":"africanmathsinitiative","id":13917566,"avatar_url":"https://avatars.githubusercontent.com/u/13917566?v=3","gravatar_id":"","url":"https://api.github.com/users/africanmathsinitiative","html_url":"https://github.com/africanmathsinitiative","followers_url":"https://api.github.com/users/africanmathsinitiative/followers","following_url":"https://api.github.com/users/africanmathsinitiative/following{/other_user}","gists_url":"https://api.github.com/users/africanmathsinitiative/gists{/gist_id}","starred_url":"https://api.github.com/users/africanmathsinitiative/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/africanmathsinitiative/subscriptions","organizations_url":"https://api.github.com/users/africanmathsinitiative/orgs","repos_url":"https://api.github.com/users/africanmathsinitiative/repos","events_url":"https://api.github.com/users/africanmathsinitiative/events{/privacy}","received_events_url":"https://api.github.com/users/africanmathsinitiative/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/africanmathsinitiative/Instat","description":"Development of the new version of Instat","fork":false,"url":"https://api.github.com/repos/africanmathsinitiative/Instat","forks_url":"https://api.github.com/repos/africanmathsinitiative/Instat/forks","keys_url":"https://api.github.com/repos/africanmathsinitiative/Instat/keys{/key_id}","collaborators_url":"https://api.github.com/repos/africanmathsinitiative/Instat/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/africanmathsinitiative/Instat/teams","hooks_url":"https://api.github.com/repos/africanmathsinitiative/Instat/hooks","issue_events_url":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/events{/number}","events_url":"https://api.github.com/repos/africanmathsinitiative/Instat/events","assignees_url":"https://api.github.com/repos/africanmathsinitiative/Instat/assignees{/user}","branches_url":"https://api.github.com/repos/africanmathsinitiative/Instat/branches{/branch}","tags_url":"https://api.github.com/repos/africanmathsinitiative/Instat/tags","blobs_url":"https://api.github.com/repos/africanmathsinitiative/Instat/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/africanmathsinitiative/Instat/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/africanmathsinitiative/Instat/git/refs{/sha}","trees_url":"https://api.github.com/repos/africanmathsinitiative/Instat/git/trees{/sha}","statuses_url":"https://api.github.com/repos/africanmathsinitiative/Instat/statuses/{sha}","languages_url":"https://api.github.com/repos/africanmathsinitiative/Instat/languages","stargazers_url":"https://api.github.com/repos/africanmathsinitiative/Instat/stargazers","contributors_url":"https://api.github.com/repos/africanmathsinitiative/Instat/contributors","subscribers_url":"https://api.github.com/repos/africanmathsinitiative/Instat/subscribers","subscription_url":"https://api.github.com/repos/africanmathsinitiative/Instat/subscription","commits_url":"https://api.github.com/repos/africanmathsinitiative/Instat/commits{/sha}","git_commits_url":"https://api.github.com/repos/africanmathsinitiative/Instat/git/commits{/sha}","comments_url":"https://api.github.com/repos/africanmathsinitiative/Instat/comments{/number}","issue_comment_url":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/comments{/number}","contents_url":"https://api.github.com/repos/africanmathsinitiative/Instat/contents/{+path}","compare_url":"https://api.github.com/repos/africanmathsinitiative/Instat/compare/{base}...{head}","merges_url":"https://api.github.com/repos/africanmathsinitiative/Instat/merges","archive_url":"https://api.github.com/repos/africanmathsinitiative/Instat/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/africanmathsinitiative/Instat/downloads","issues_url":"https://api.github.com/repos/africanmathsinitiative/Instat/issues{/number}","pulls_url":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls{/number}","milestones_url":"https://api.github.com/repos/africanmathsinitiative/Instat/milestones{/number}","notifications_url":"https://api.github.com/repos/africanmathsinitiative/Instat/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/africanmathsinitiative/Instat/labels{/name}","releases_url":"https://api.github.com/repos/africanmathsinitiative/Instat/releases{/id}","deployments_url":"https://api.github.com/repos/africanmathsinitiative/Instat/deployments","created_at":"2015-10-10T12:10:32Z","updated_at":"2016-01-11T15:31:19Z","pushed_at":"2016-04-05T09:24:49Z","git_url":"git://github.com/africanmathsinitiative/Instat.git","ssh_url":"git@github.com:africanmathsinitiative/Instat.git","clone_url":"https://github.com/africanmathsinitiative/Instat.git","svn_url":"https://github.com/africanmathsinitiative/Instat","homepage":null,"size":8563,"stargazers_count":0,"watchers_count":0,"language":"Visual Basic","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":13,"mirror_url":null,"open_issues_count":37,"forks":13,"open_issues":37,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153"},"html":{"href":"https://github.com/africanmathsinitiative/Instat/pull/1153"},"issue":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/1153"},"comments":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/issues/1153/comments"},"review_comments":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153/comments"},"review_comment":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/pulls/1153/commits"},"statuses":{"href":"https://api.github.com/repos/africanmathsinitiative/Instat/statuses/2ac493c00c4bad6d0fa4abea57a14a8f7f2e676d"}}}}