All Answers

0 votes

Luca,

I’ve added the default for the x-axis type as you suggested plus tidied up some other issues I found. I had to update to the latest chartjs (2.5.0) in order to resolve an issue with the time scale when empty.  I also added the additional pointstyle that this release now supports. I also updated the demo to show the new pointstyle and the axis labels.

HTH

Nic

  • Nic Adams answered Feb 28, 2017 - 10:13 am
  • last active Feb 28, 2017 - 10:16 am
0 votes

The new demo works perfect for me!

 

As far as I had understood the following lines must be implemented to run the old code with a valid chart result:

oOptionscaleX.Type=ScaleType.Category;
oOptionscaleY.Type=ScaleType.Linear;

 

Other options like RadialLinear giving me an error, so I guess this is in development.

  • Kay answered Feb 28, 2017 - 9:40 am
0 votes

Hi Luca,

Thanks a lot. The sample code work as expected.

However, when I reload the browser (press F5, for example) the StatusBar will return to it original location (when it is placed in the designer screen in Visual Studio). And therefore the TaskBar will be “overlay” on top of the StatusBar.

Secondly, I have to put the sample code in a IF block to prevent it from being run in the designer screen of Visual Studio. Otherwise, many pop-up windows will be shown saying javascript error.

if (!this.DesignerMode)
{
      this.statusBar1.Eval( . . . . . 
}

Thanks and regards,

Felix CHAN

0 votes

Hi Andrew,

can you please post the exact exception that you are hitting ?
We recently fixed a bug that caused disposed datagrids to update the datasource when the parent was stet to null in Disposed.
Assuming that the DataStore error is related to a grid or a list view, can you please retry with our latest build (1.3.37) ?

Thanks in advance !

Best regards
Frank

0 votes

Thank you Nic. Looks like the problem is that now that the ChartJS extension supports scale types the default is Linear for both X and Y while before it was Category for X. It may be better to default the X scale to Category and Y to Linear. What do you think? See attached override.

 

  • Luca answered Feb 27, 2017 - 4:24 pm
0 votes

Got it. Wisej serializes .NET object to JSON strings and JSON strings back to Wisej.Core.DynamicObject instances. Null values are serializes too since they are valid values, otherwise you’d never be able to set a property to null  in the client.

You can remove a property from a wisej dynamic object by calling config.Remove(“property name”).

For the designer serialization, in case you are overriding an inherited property (like it’s probably the case with the ScaleType :)), you have to shadow the property or the ShouldSerialize* and Reset* methods won’t work. See my other reply to the ChartJS issue with attachment.

/Luca

 

  • Luca answered Feb 27, 2017 - 4:21 pm
0 votes

Hi Luca,

Thanks for clarifying. I think I was confused between the serialisation options for the editor and how WiseJ serialises options for the java object. I can see now why what I was doing didn’t work but I still can’t figure out how I stop WiseJ putting properties with null values into the config for chartjs when it calls

script = script.Replace(“$config”, config.ToString());

I have a property that should not be output if it is null and at present it is always output but with a value of null (i.e {“time”: null}).

Thanks

Nic

0 votes

Hi Kay,

I think I caused that 🙂

I updated the extension to include the ability to set scales plus some other new options. I wasn’t expecting it to be pushed into the release straight away and I had not even thought of updating the demo. Since my changes the scale on charts always defaults to linear which is not the same as the previous behaviour. I’m still improving the extension but meantime attached is an updated demo with the scales correctly set for the line and bar charts.

HTH

Nic

0 votes

In Details view? Double click on an item or the ListView itself. I tried double clicks on an item and I get the ItemClick event with Clicks=2. It doesn’t seems to work in Details view when double clicking on a row.

  • Luca answered Feb 27, 2017 - 3:17 pm
0 votes

Hi Nic,

The serialization in Wisej is entirely based on System.ComponentModel. You can control what happens to a property at design time using:

https://msdn.microsoft.com/en-us/library/system.componentmodel.designerserializationvisibilityattribute(v=vs.110).aspx

 

[Browsable] hide/show the  property in the properties panel

[DesignerSerializationVisibility] exclude/include, or whether to serialize the property value or its content.

[DefaultValue] this is alternative to the private bool ShouldSerialize[PropertyName] and private void Reset[PropertyName] methods.

[Editor], [TypeConverter] to determine the editor and the conversion/serialization to/from a string or a CodeDom definition.

HTH

Best,

Luca

 

  • Luca answered Feb 27, 2017 - 3:13 pm
0 votes

Thanks Luca,

That works perfectly.

Nic

0 votes

Hi Shawn,

is it a network drive? Error 4350 seems to mean that the drive or folder are off line. MyDocument is a system folder and the installer (we use Caphyon Advanced Installer) maps to whatever  the OS says it’s MyDocuments.

You can also try to install keeping all VS options off. Then add the templates by hand but you need to find the location where VS puts the templates. You can download  the templates here: http://setup.wisej.com/Templates.zip

Best,

Luca

  • Luca answered Feb 26, 2017 - 10:31 pm
1 vote
In reply to: How to Save Cookies

Hi Tung,

I tried the sample that Thomas posted on Windows 10 with Chrome, IE 11 and IE Edge and the cookie is always retrieved correctly. You may have protected mode enabled in IE, or some other security setting that prevents the cookies from being saved.

Best,

Luca

  • Luca answered Feb 26, 2017 - 9:33 pm
0 votes
In reply to: How to Save Cookies

Hello Thomas,

I run your example at my side. The cookies is not preserved.

I use Windows10. VS2013 + IIS Express, debug with Internet Explorer.

However, with Chrome the cookies is preserved as expected.

  • Tung Ngo answered Feb 26, 2017 - 6:38 pm
0 votes

Hi Ekin,

this depends on what you’re after. I put together a little sample that shows a timer instance generating timer events on the server. These update the client every 100 milliseconds and you can also see an alert box popping up for the user.

If you want to react to some other events on the server, make sure that your app receives it and then pass it on to the user. You could for example create an external app server component that sends out events whenever master records have changed.

Please also see our Background Tasks sample on the Examples page (https://wisej.com/examples/).

HTH

Best wishes
Thomas

0 votes
In reply to: How to Save Cookies

Hi Tung,

I just checked and for me it is working fine. See attached sample – the cookie value is preserved when the app is stopped and restarted.

Best wishes
Thomas

0 votes

Hi Shawn,

I haven’t seen this error message before. Here is the link to our downloads:

Builds

Best wishes
Thomas

0 votes

Here is the error.

 

I don’t have a mydocuments folder.  There is a documents folder….

0 votes

Hi Chris,

Yes, found the problem with your app. You call Application.Update(me) after you create the label and add it. It works when you click the button because it’s a normal in-bound request and Wisej has the context in place.

But when the request comes from an independent thread (in  our app it’s the incoming ircClient1_LocalUser_JoinedChannel event), there is no context and it’s impossible to retrieve a session. That’s why we have the Application.Update, RunInContext, StartTask methods. If you simply changed the text or color of an existing control and then called Application.Update(me) it would have worked, but you are creating and adding a new control *before* running in context and Wisej cannot register the control with the session.

The best and safest way to handle this is to wrap the entire out-of-bound code (or event raisers in your class) in context:

 

Application.Update(Me,
Sub()

‘ Here you can do anything in context.

 

End Sub)

 

I have attached the modified file. Look also for the ‘Not needed comments.

HTH

Best,

Luca

 

  • Luca answered Feb 25, 2017 - 7:01 pm
  • last active Feb 25, 2017 - 7:16 pm
0 votes
In reply to: Bug on Listbox!

Just tried the same with a ListView in case that what you are using and it also still works.

  • Luca answered Feb 25, 2017 - 6:30 pm
Showing 9501 - 9520 of 11k results