SQLite CRUD Update not working with sFDataForm

In my .NET Maui app, I have two pages, one page one, I use a number of sFTExtInputLayout control.


   <inputLayout:SfTextInputLayout
       Grid.Row="0"
       Grid.Column="0"
       Margin="5,5,5,5"
       ContainerType="Outlined"
       Hint="Enncounter#">
       <Entry x:Name="encidEntry" />
   </inputLayout:SfTextInputLayout>


   <inputLayout:SfTextInputLayout
       Grid.Row="0"
       Grid.Column="1"
       Margin="5,5,5,5"
       ContainerType="Outlined"
       Hint="Patient ID">
       <Entry x:Name="pidEntry" />
   </inputLayout:SfTextInputLayout>


   <inputLayout:SfTextInputLayout
       Grid.Row="0"
       Grid.Column="2"
       Grid.ColumnSpan="2"
       Margin="5,5,5,5"
       ContainerType="Outlined"
       Hint="Visit Category">
       <Entry x:Name="visit_categoryEntry" />
   </inputLayout:SfTextInputLayout>

I'm updating my SQLite table using a CRUD update method.

For my other page, I'm using a sFDataForm, however when I call a similar Update method, I never get the changes to the table to be successful.


Is there something different about using the DataForm?  The Dataform is convenient in this app, but I'm gonna switch to the sFTextInputLayout control if necessary



3 Replies

VM Vidyalakshmi Mani Syncfusion Team July 15, 2024 01:24 PM UTC

Hi Frederick,


Thank you for reaching out to us. We have reviewed your query and tested the SfDataForm control with CRUD operations on a SQLite database. In our tests, everything worked correctly. We have attached the sample we tested for your reference. Please check our sample and let us know if the issue persists. If not, kindly modify our sample to replicate your scenario or share your specific sample where the issue occurs. This will help us better understand the problem and provide an appropriate solution.


Regards,

Vidyalakshmi M.



Attachment: DataFormMAUI_df95634f.zip


FS Frederick Switzer July 15, 2024 02:28 PM UTC

VM,

Thank you for the quick response and sample. 

I was able to make a change and now everything is updating correctly.


Here is the change I made:


  int success=patientRepository.UpdatePatient(this.patientDataForm.DataObject as Patient);

instead of:

int success = patientRepository.UpdatePatient(patient);

Great response from Syncfusion!!



JS Jayashree Suresh Anand Syncfusion Team July 16, 2024 09:39 AM UTC

Hi Frederick,

You're welcome! We're glad our solution worked for you. If you have any concerns, please let us know. Feel free to open a new forum if you encounter any new issues. We're delighted to help you!

Regards,

Jayashree 


Loader.
Up arrow icon