DxCalendar assistance

0
0

Can someone point me in the right direction to integrate the dxCalendar?

I spent 6 hours with CoPilot yesterday and it still doesn’t work.

I need basic instructions on how to tell wisej that I’m using a DevExtreme control.

CoPilot’s suggestion was to use a Widget control instead and gave me an InitScript and code for a Widget event.

I can get the calendar to display but it pays no atention when I select a date. I need to have it  pass the date selected to the event that called it and then close the form.

I can post code if you need to see it, but I’m hoping it’s something simple?

  • You must to post comments
0
0

Here’s a very simple sample that works for me, I was able to click on the calendar dates and see the AlertBox from the WidgetEvent.
Julie

Attachment
  • You must to post comments
0
0

From the example:

public dxCalendar()
{
InitializeComponent();

this.dxCalendar1.Instance.onValueChanged += new WidgetEventHandler(dxCalendar1_WidgetEvent);
}

private void dxCalendar1_WidgetEvent(object sender, WidgetEventArgs e)
{
AlertBox.Show(
$”<b>{e.Type}</b><br/>{JSON.Stringify(e.Data)}”,
MessageBoxIcon.Information);

Application.Play(MessageBoxIcon.Information);
}

Clicking a date does not trigger WidgetEvent.

  • You must to post comments
0
0

Thanks Julie! I’ll take a look at the examples you provided. I’m experienced in DexExpress but DevExtreme is new to me.

  • You must to post comments
0
0

You’ll need the DevExtreme nuget package installed. In Visual Studio, go to “Manage Nuget Packages” and search for Wisej-3-DevExtreme. Once the nuget package is installed, open the designer. In the toolbox, search for “dxCalendar”. You can then drag and drop the dxCalendar from the toolbox into the designer.

For getting it to pay attention when you select a date, attach to the onValueChanged event like so:
dxCalendar1.Instance.onValueChanged += new WidgetEventHandler(dxCalendar1_WidgetEvent);

dxCalendar1_WidgetEvent would look something like this:
private void dxCalendar1_WidgetEvent(object sender, WidgetEventArgs e)
{
AlertBox.Show(
$"{e.Type}
{JSON.Stringify(e.Data)}");

}

Here’s an example from the demobrowser:
https://wisej-demobrowser.azurewebsites.net/DevExtreme/#dxCalendar

Example code: https://github.com/iceteagroup/wisej-demobrowser/blob/main/Wisej.DemoBrowser.Premium/Wisej.Web.Ext.DevExtreme.Demo/Component/dxCalendar.cs

Hope this helps,
Julie

  • You must to post comments
Showing 4 results
Your Answer

Please first to submit.