We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date

Impossible to show an image in the SchedulerResourceView.HeaderTemplate

Hello,

i dont know why i 'am not able to see an image in the resourceview.

It's like that the imageName propety cannot be found.

pic1.png


I got this error message :

Erreur 5 SchedulerResource ImageName Image.Source ImageSource 'ImageName' property not found on 'Syncfusion.Maui.Scheduler.SchedulerResource', target property: 'Microsoft.Maui.Controls.Image.Source' 


Can you suggest any checks or solution please.

Thanks in advance.

I attached my view+model and viewmodel










Attachment: example_9be0c2fe.zip

3 Replies 1 reply marked as answer

SS SaiGanesh Sakthivel Syncfusion Team April 11, 2023 09:28 AM UTC

Hi Mackenson,


#Regarding Image in the resource view is not shown

We could not replicate the reported scenario from our end. We have prepared the sample as per the given information and checked the sample from our side. Please refer to the tested sample in the attachment.


We suspect that the reported scenario may occur because the ‘Build Action’ of the Image property is not set as Embedded Resource, which can result in empty view. We suggest you check the Build action of the image property set as Embedded Resource. Could you please check it in your sample and let us know if you still facing the same issue? If not, please modify the sample based on your scenario and revert us back with the following details,

.

  • Share the issue replicated platforms.

  • Share the maui framework version used in the sample.


It will be helpful for us to check on it and provide you with the solution as soon as possible.


Regards,
SaiGanesh Sakthivel


Attachment: SchedulerMAUI_82aaa1b6.zip


MA Mackenson replied to SaiGanesh Sakthivel April 12, 2023 12:50 AM UTC

Hello SaiGanesh,


i found the root cause of my problem.

it was because of the bindingcontext of my resourceview. so it was not able to find DataItem properties.


 <scheduler:SchedulerResourceView.BindingContext>

<viewmodel:BookingViewModel/>

</scheduler:SchedulerResourceView.BindingContext>


i couldn't use it at the beginning cause mine had arguments when the binding required a without arguments constructor. So just create one as required then called a new function inside instead.


Thanks for your help as always ;)




Marked as answer

SS SaiGanesh Sakthivel Syncfusion Team April 12, 2023 11:51 AM UTC

Mackenson,


We are glad to know that the provided solution is resolved the query. Please let us know if you need any further assistance. 


Loader.
Live Chat Icon For mobile
Up arrow icon