<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Ahmad Rifai</title>
    <description>The latest articles on DEV Community by Ahmad Rifai (@ahmad_rifai_54a20be09025e).</description>
    <link>https://dev.to/ahmad_rifai_54a20be09025e</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1593316%2F164c2713-6bb2-4fba-b4e0-b9c0d41ecc26.png</url>
      <title>DEV Community: Ahmad Rifai</title>
      <link>https://dev.to/ahmad_rifai_54a20be09025e</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/ahmad_rifai_54a20be09025e"/>
    <language>en</language>
    <item>
      <title>Explain X Like I'm Five</title>
      <dc:creator>Ahmad Rifai</dc:creator>
      <pubDate>Sun, 16 Jun 2024 03:18:00 +0000</pubDate>
      <link>https://dev.to/ahmad_rifai_54a20be09025e/explain-x-like-im-five-n8j</link>
      <guid>https://dev.to/ahmad_rifai_54a20be09025e/explain-x-like-im-five-n8j</guid>
      <description></description>
      <category>explainlikeimfive</category>
    </item>
    <item>
      <title>Exception caught by widgets library, Incorrect use of ParentDataWidget.</title>
      <dc:creator>Ahmad Rifai</dc:creator>
      <pubDate>Fri, 07 Jun 2024 23:55:37 +0000</pubDate>
      <link>https://dev.to/ahmad_rifai_54a20be09025e/exception-caught-by-widgets-library-incorrect-use-of-parentdatawidget-1219</link>
      <guid>https://dev.to/ahmad_rifai_54a20be09025e/exception-caught-by-widgets-library-incorrect-use-of-parentdatawidget-1219</guid>
      <description>&lt;p&gt;Hi Every one, I'm from Indonesia&lt;br&gt;
i'm a newbie in programming...&lt;/p&gt;

&lt;p&gt;I have working with a table while data get from API (in Flutter dart), i made a Scrollable table with Fix First Row (which is the column header) table was successfull and function but it's always show this message in debug console:&lt;/p&gt;

&lt;p&gt;Exception caught by widgets library ═══════════════════════════════════&lt;br&gt;
Incorrect use of ParentDataWidget.&lt;/p&gt;

&lt;p&gt;is ther anybody help me to solve this, even it's function correctly, those message may be decrease performance application or become an error some day.&lt;/p&gt;

&lt;p&gt;My Code is like this:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// ignore_for_file: camel_case_types, prefer_interpolation_to_compose_strings

import 'package:bps_cilacap/restAPI/repository_penduduk_kecamatan.dart';
import 'package:flutter/material.dart';
import 'package:bps_cilacap/format_angka.dart';

class JumlahPendudukKecamatanA extends StatefulWidget {
  const JumlahPendudukKecamatanA({Key? key}) : super(key: key);

  @override
  State&amp;lt;JumlahPendudukKecamatanA&amp;gt; createState() =&amp;gt;
      _JumlahPendudukKecamatanAState();
}

RepositoryJumlahPendudukKecamatan jumlahPendudukKecamatan =
    RepositoryJumlahPendudukKecamatan();

class _JumlahPendudukKecamatanAState extends State&amp;lt;JumlahPendudukKecamatanA&amp;gt; {
  @override
  Widget build(BuildContext context) {
    final screenHeight = MediaQuery.of(context).size.height -
        MediaQuery.of(context).padding.top -
        MediaQuery.of(context).padding.bottom;
    // ignore: unused_local_variable
    final screenWidth = MediaQuery.of(context).size.width -
        MediaQuery.of(context).padding.left -
        MediaQuery.of(context).padding.right;
    return Scaffold(
        body: FutureBuilder(
      future: jumlahPendudukKecamatan.getData(),
      builder: (context, snapshot) {
        if (snapshot.hasData) {
          List isipendudukkecamatan = snapshot.data as List;
          return PageView.builder(
            itemCount: 1,
            itemBuilder: (context, index) {
              String kec1 = "  1. " + isipendudukkecamatan[index = 0].kecamatan;
              String kec2 = "  2. " + isipendudukkecamatan[index = 1].kecamatan;
              …
    ……
              String kec24 =24. " + isipendudukkecamatan[index = 23].kecamatan;
              String kab = " " + isipendudukkecamatan[index = 24].kecamatan;

              int lk1 = int.parse(isipendudukkecamatan[index = 0].lk1);
              int lk2 = int.parse(isipendudukkecamatan[index = 1].lk1);
              ……
    …..              
              int lk24 = int.parse(isipendudukkecamatan[index = 23].lk1);
              int lkTotal = int.parse(isipendudukkecamatan[index = 24].lk1);

              int pr1 = int.parse(isipendudukkecamatan[index = 0].pr1);
              int pr2 = int.parse(isipendudukkecamatan[index = 1].pr1);
              int pr3 = int.parse(isipendudukkecamatan[index = 2].pr1);
              ………
    ………
int pr24 = int.parse(isipendudukkecamatan[index = 23].pr1);
              int prTotal = int.parse(isipendudukkecamatan[index = 24].pr1);


          return Scaffold(
                body: Column(
                children: &amp;lt;Widget&amp;gt;[

//This is the part of Fixed Row Header
Row(
                    children: [
                      Flexible(
                        fit: FlexFit.tight,
                        flex: 4,
                        child: Container(
                          height: screenHeight * 0.06,
                          padding: const EdgeInsets.symmetric(
                              horizontal: 2, vertical: 10),
                          color: Colors.green,
                          child: const Center(
                            child: Text(
                              "Kecamatan",
                              textAlign: TextAlign.center,
                              style: TextStyle(
                                  color: Colors.white,
                                  fontWeight: FontWeight.bold),
                            ),
                          ),
                        ),
                      ),
                      Flexible(
                        fit: FlexFit.tight,
                        flex: 2,
                        child: Container(
                          height: screenHeight * 0.06,
                          padding: const EdgeInsets.symmetric(
                              horizontal: 2, vertical: 10),
                          color: Colors.green,
                          child: const Center(
                            child: Text(
                              "Lk",
                              style: TextStyle(
                                  color: Colors.white,
                                  fontWeight: FontWeight.bold),
                            ),
                          ),
                        ),
                      ),
                      Flexible(
                        fit: FlexFit.tight,
                        flex: 2,
                        child: Container(
                          height: screenHeight * 0.06,
                          padding: const EdgeInsets.symmetric(
                              horizontal: 2, vertical: 10),
                          color: Colors.green,
                          child: const Center(
                            child: Text(
                              "Pr",
                              style: TextStyle(
                                  color: Colors.white,
                                  fontWeight: FontWeight.bold),
                            ),
                          ),
                        ),
                      ),
                      Flexible(
                        fit: FlexFit.tight,
                        flex: 2,
                        child: Container(
                          height: screenHeight * 0.06,
                          padding: const EdgeInsets.symmetric(
                              horizontal: 2, vertical: 10),
                          color: Colors.green,
                          child: const Center(
                            child: Text(
                              "Lk + Pr",
                              style: TextStyle(
                                  color: Colors.white,
                                  fontWeight: FontWeight.bold),
                            ),
                          ),
                        ),
                      ),
                    ],
                  ),


 // This the part of Scrollable Row

Expanded(
                    child: SingleChildScrollView(
                    child: Flexible(
                      child: SizedBox(
                        width: screenWidth,
                        height: screenHeight,
                        child: Column(
                          children: [
                            //First Row
                            Container(
                              width: screenWidth * 1.0,
                              height: screenHeight * 0.032,
                              color: Colors.transparent,
                              child: Row(
                                children: [
                                  Flexible(
                                    fit: FlexFit.tight,
                                    flex: 4,
                                    child: Container(
                                      color: Colors.transparent,
                                      padding: const EdgeInsets.only(
                                          right: 10, top: 1, bottom: 1),
                                      child: Text(
                                        kec1,
                                        textAlign: TextAlign.left,
                                        style: const TextStyle(
                                            fontWeight: FontWeight.normal),
                                      ),
                                    ),
                                  ),
                                  Flexible(
                                    fit: FlexFit.tight,
                                    flex: 2,
                                    child: Container(
                                      color: Colors.transparent,
                                      padding: const EdgeInsets.only(
                                          right: 10, top: 1, bottom: 1),
                                      child: Text(
                                        Format.convertTo(lk1, 0),
                                        textAlign: TextAlign.right,
                                        style: const TextStyle(
                                            fontWeight: FontWeight.normal),
                                      ),
                                    ),
                                  ),
                                  Flexible(
                                    fit: FlexFit.tight,
                                    flex: 2,
                                    child: Container(
                                      color: Colors.transparent,
                                      padding: const EdgeInsets.only(
                                          right: 10, top: 1, bottom: 1),
                                      child: Text(
                                        Format.convertTo(pr1, 0),
                                        textAlign: TextAlign.right,
                                        style: const TextStyle(
                                            fontWeight: FontWeight.normal),
                                      ),
                                    ),
                                  ),
                                  Flexible(
                                    fit: FlexFit.tight,
                                    flex: 2,
                                    child: Container(
                                      color: Colors.transparent,
                                      padding: const EdgeInsets.only(
                                          right: 5, top: 1, bottom: 1),
                                      child: Text(
                                        Format.convertTo((lk1 + pr2), 0),
                                        textAlign: TextAlign.right,
                                        style: const TextStyle(
                                            fontWeight: FontWeight.normal),
                                      ),
                                    ),
                                  ),
                                ],
                              ),
                            ),

                            //Second row
                            ……
                           //And more row here
                            …
                            //21 st row
                       ),
                      ),
                    ),
                  ))
                ],
              ));
            },
          );
        }
        if (snapshot.hasError) {
          return const Text('Database Error');
        } else {
          return const Center(child: CircularProgressIndicator(strokeWidth: 3));
        }
      },
    ));
  }
}

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;i Hope anyone can help.&lt;br&gt;
PS. Sorry for my english.&lt;/p&gt;

</description>
      <category>singlechildscrollview</category>
      <category>api</category>
      <category>pageview</category>
      <category>flutter</category>
    </item>
  </channel>
</rss>
