<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Editing a related table -help- esri sample in ArcGIS API for Flex Questions</title>
    <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565094#M12736</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, I was wondering if anyone has used the sample from esri that allows you to edit a related table? I have the application setup and running using one of my own feature services but I need to add more fields from the related table to edit. This sample only allows you to make edits to the agree_with_incident field by clicking on an image. I'm not sure where I need to add in my others fields that I'd like to edit.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas would greatly be appreciated!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 Nov 2011 12:24:33 GMT</pubDate>
    <dc:creator>LizDaRos</dc:creator>
    <dc:date>2011-11-07T12:24:33Z</dc:date>
    <item>
      <title>Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565094#M12736</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi, I was wondering if anyone has used the sample from esri that allows you to edit a related table? I have the application setup and running using one of my own feature services but I need to add more fields from the related table to edit. This sample only allows you to make edits to the agree_with_incident field by clicking on an image. I'm not sure where I need to add in my others fields that I'd like to edit.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Any ideas would greatly be appreciated!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Nov 2011 12:24:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565094#M12736</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2011-11-07T12:24:33Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565095#M12737</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I've found some code that uses the same code as the attribute inspector sample to edit related tables. Here is the link-&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://http://forums.arcgis.com/threads/9988-How-can-I-access-a-relationship-query-through-Attribute-Inspector?highlight=edit+related+table"&gt;access-a-relationship-query-through-Attribute-Inspector&lt;/A&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm also using points instead of polygons so I've switched some on the code in the attribute inspector sample to select the points.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I think I am close to getting this working, I can see the related table information in the attribute inspector popup but it only shows for about half a second then disappears and another blank popup displays.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Attached is my code... can anyone see what the problem is?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Nov 2011 11:58:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565095#M12737</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2011-11-09T11:58:18Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565096#M12738</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; Your issue is that both the roomsLayer and the roomsTableLayer featurelayers are firing the tableSelect_selectionCompleteHandler function.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Nov 2011 12:51:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565096#M12738</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2011-11-09T12:51:29Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565097#M12739</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;That was it, thank you very much Robert!&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Now I just need to add a function that adds a new record to the related table. It looks like the code from the Editing a Related Table sample can do this. If that's the right direction then I'm trying to use this function in my application but not having much luck. Any suggestions?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; private function addImage_clickHandler(event:MouseEvent):void&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; const roomsTableLayer:Object = {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; object: selectedGraphic.attributes.objectid,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; datetime: new Date().getTime(),&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; agree_with_incident: 1&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; };&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; const roomsTableLayer:Graphic = new Graphic(null, null, roomsTableLayerAttributes);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; const roomsTableLayer:FeatureLayer = new FeatureLayer("&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/FeatureServer/1" rel="nofollow" target="_blank"&gt;http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/FeatureServer/1&lt;/A&gt;&lt;SPAN&gt;");&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; roomsTableLayer.addEventListener(FeatureLayerEvent.EDITS_COMPLETE, roomsTableLayer_editsCompleteHandler);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; roomsTableLayer.applyEdits([ voteRecord ], null, null);&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; private function roomsTableLayer_editsCompleteHandler(event:FeatureLayerEvent):void&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; {&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; count++;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; peopleCount.text = count + " people think this is important";&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; }&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Nov 2011 13:47:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565097#M12739</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2011-11-09T13:47:47Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565098#M12740</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; You have several coding issue here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;private function addImage_clickHandler(event:MouseEvent):void
{
&amp;nbsp;&amp;nbsp;&amp;nbsp; const &lt;SPAN style="color:Red;"&gt;&lt;STRONG&gt;roomsTableLayer&lt;/STRONG&gt;&lt;/SPAN&gt;:Object = {
&amp;nbsp;&amp;nbsp;&amp;nbsp; object: selectedGraphic.attributes.objectid,
&amp;nbsp;&amp;nbsp;&amp;nbsp; datetime: new Date().getTime(),
&amp;nbsp;&amp;nbsp;&amp;nbsp; agree_with_incident: 1
&amp;nbsp;&amp;nbsp;&amp;nbsp; };

&amp;nbsp;&amp;nbsp; &lt;SPAN style="color:Red;"&gt;//And here you are using the same constant name again, this is no good.&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; const &lt;STRONG style="color: Red;"&gt;roomsTableLayer&lt;/STRONG&gt;:Graphic = new Graphic(null, null, roomsTableLayerAttributes);

&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color:Red;"&gt;//And here you are using the same constant name again, this is really no good.&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; const &lt;STRONG style="color: Red;"&gt;roomsTableLayer&lt;/STRONG&gt;:FeatureLayer = new FeatureLayer("http://sampleserver3.arcgisonline.com/ArcGIS/rest/services/SanFrancisco/311Incidents/FeatureServer/1");
&amp;nbsp;&amp;nbsp;&amp;nbsp; roomsTableLayer.addEventListener(FeatureLayerEvent.EDITS_COMPLETE, roomsTableLayer_editsCompleteHandler);
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color:Red;"&gt;//Now you are trying to apply voteRecord which does not exist in your code to the table&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; roomsTableLayer.applyEdits([ voteRecord ], null, null);
}

private function roomsTableLayer_editsCompleteHandler(event:FeatureLayerEvent):void
{
&amp;nbsp;&amp;nbsp;&amp;nbsp; count++;
&amp;nbsp;&amp;nbsp;&amp;nbsp; peopleCount.text = count + " people think this is important";
}&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 00:21:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565098#M12740</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2021-12-12T00:21:11Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565099#M12741</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks for looking at it. I guess I was just wondering if the function from that sample would even do what I want? I kind of realized the code I showed wasn't correct and would need some changes.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Nov 2011 14:30:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565099#M12741</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2011-11-09T14:30:20Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565100#M12742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp; It looks like it should work.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 09 Nov 2011 15:14:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565100#M12742</guid>
      <dc:creator>RobertScheitlin__GISP</dc:creator>
      <dc:date>2011-11-09T15:14:12Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565101#M12743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Thanks for looking at it. I guess I was just wondering if the function from that sample would even do what I want? I kind of realized the code I showed wasn't correct and would need some changes.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Greetings Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I am having difficulty with the final step of adding an additional relate entry.&amp;nbsp; Did you you have success with this?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Can you share your code?&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Craig&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Mar 2012 13:01:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565101#M12743</guid>
      <dc:creator>R__CraigHolmes</dc:creator>
      <dc:date>2012-03-14T13:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565102#M12744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Craig,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;No I wasn't able to add an additional relate entry with this flex sample, sorry. Instead I used the Javascript API sample- &lt;/SPAN&gt;&lt;A href="https://www.arcgis.com/home/item.html?id=12e175f3534b4e8e949ef193319b9686"&gt;Citizen Service Request&lt;/A&gt;&lt;SPAN&gt;.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I was able to change this sample to just allow the user to create a new record in the related table.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Liz&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 Mar 2012 13:26:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565102#M12744</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2012-03-14T13:26:03Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565103#M12745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I am having a similar issue. Do you think you can share your code to add records to the related table? Thank you!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Dec 2013 12:48:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565103#M12745</guid>
      <dc:creator>ionarawilson1</dc:creator>
      <dc:date>2013-12-06T12:48:20Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565104#M12746</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ionara_wilson,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Are you looking to see how I reconfigured the JavaScript template - Citizen Service Request to allow the user to create a new record in the related table? If so, I can try and give you some more information.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But like I said earlier, unfortunately I wasn't able to do this with the flex template. I really wish there was a flex viewer widget that allowed to you edit related data.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 13:26:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565104#M12746</guid>
      <dc:creator>LizDaRos</dc:creator>
      <dc:date>2013-12-20T13:26:45Z</dc:date>
    </item>
    <item>
      <title>Re: Editing a related table -help- esri sample</title>
      <link>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565105#M12747</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi Liz,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I actually combined some samples and got it working for me but it was definitely tricky! Thank you!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 20 Dec 2013 14:27:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-api-for-flex-questions/editing-a-related-table-help-esri-sample/m-p/565105#M12747</guid>
      <dc:creator>ionarawilson1</dc:creator>
      <dc:date>2013-12-20T14:27:00Z</dc:date>
    </item>
  </channel>
</rss>

