
Error:
The relevant error-causing widget was:
PaypalPaymentPage PaypalPaymentPage:file:///C:/Users/dharm/AndroidStudioProjects/mhn_app_doctor/lib/pages/doctor_profile_page.dart:495:33
When the exception was thrown, this was the stack:
#2 new TextFormField (package:flutter/src/material/text_form_field.dart:176:15)
text_form_field.dart:176
#3 _PaypalPaymentPageState.build (package:my_hospital_now_doctor/pages/paypal_payment.dart:157:19)

Solution:
To fix this, follow these steps:
- Remove
initialValuewhen you’re using acontroller. - If you’re using
controller, only rely on that and don’t setinitialValue. - If you want to display the value without editing it, use
initialValueand remove thecontroller.
Here’s the corrected code:








