Use css transition https://www.w3schools.com/cssref/css3_pr_transition.asp
No need to use the animation extender.
See attached fixed sample.
You cannot call a method on a third party widget when the container is created because the browser loads the javascript libraries asynchronously. In Wisej 2.x there is a Loaded event on the Widget. In any case, it’s enough to fire an event in init() and then check in the javascript function if the widget is initialized and if not, resubmit the call when the event fires.
Hi Luca
I modified the project eSigantureSample and attaching it here.
If I call the SetSignature() method from the button_click event, it works fine.
But if I call the method from the main after the form is loaded, you can see the error I mentioned. I just did to mimic the scenario in my environment where the controls are populated after the form is loaded.
Thanks
Praveena
Another PC or another browser on the same PC will have a different client id. Using the new Application.Clients you can also see all the clients using the app and for each client you can see how many sessions and the list of browsers used by that client (could be useful for a monitoring app).
Hi Luca,
thanks for your feedback. I thought about using cookies or localstorage but as far as I know this would require additional security efforts since I currently only save the user-id in the Application Session for subsequent database access after successful authentication.
Maybe I can use a global static key-value-store on the server/database with Application.ClientId and e.g. the roles of the logged on user ? Do you think this is a reliable way to use ? Using this approch a second WiseJ application in a new tab should have the same ClientId and could read the value from the server, right ? Using the URL on other PCs would not be able to view the report because the ClientId is not set and the check for it would fail…
You don’t have the “label-wrapper” appearance. That’s the one used for the labels attached to widgets. Copy the entire “label-wrapper” from any of our themes.
They are subprocesses created by Edge.
After closing VS they should all be terminated.
When you open a designer it will create the parallel renderers number (if you have it at 6 then it creates 6 subprocesses). When you close a designer the renderers are NOT disposed immediately, they are pooled and disposed a minute later unless reused by a new designer.
If you close all designers and keep visual studio open you should see the renderers get terminated after a minute or so. If they don’t there is a leak that we cannot reproduce.
Hi Tobias,
Wisej sessions cannot be shared among browser tabs. It’s a single page application and different tabs using the same session would make a mess. We have a sharing system for the infinite session feature but in that case the tabs are kept in sync by Wisej. In any case you cannot show form1 on tab1 and form2 on tab2 using the same session.
You can share information between tabs using 1) cookies or 2) browser’s local storage, or 3) a custom session repository using the new Application.ClientId.
About point 3, it just occurred to me that since we have this new client id identifying the client (browser) instead of the session (see also Application.Clients) we could actually add a Application.ClientStorage object similar to the Application.Session but isolated by client and not by session. Could be a good enhancement.
To use Application.Browser.LocalStorage see https://docs.wisej.com/docs/controls/general/application#browser-storage. You can access cookies, local and session storage without a page reload. This would allow you to start a “reporting” session “linked” to the user session. You can also use sub-applications to have a different entry point.
HTH
Could transfering a session token be used to access the Session variables of the call WiseJ application:
App1:
Application.Session[“myID”] = “4711”;
Application.Navigate($”/Report?sid={Application.SessionId}?Req=0815″, “_blank”);
App2:
void IWisejHandler.ProcessRequest(HttpContext context)
{
Wisej.Web.Application.RestoreSession(context);
// do something with Application.Session[“myID”]
}
I tried this but ProcessRequest seems not to get called ?
Hi Tobias,
The included sample was targeted for opening an aspx page in a new tab.
If you are opening a Wisej tab, it’s entirely up to you to integrate the authentication method you want. You can for example authenticate the user from that new page, or pass a session token that can be used to validate the authenticity of the user.
Also, the DevExpress ReportViewer should be able to be integrated in the standard AspNetPanel control.
HTH,
Alaa
Hi Alaa,
thank you very much for your sample.
(How) can this be extended to show a WiseJ page in the new tab for displaying the DevExpress Report Preview instead of posting back some “context.Responses” ?
Hi Luca
Below is the code that i have so far. The “SetSignature” method is called after the form and controls are loaded and when the control data is getting populated from the saved properties. So the base64 string will be passed as a parameter to this method.
I can see the log message “in apply signature” in the console. And then it gives the attached error.
public SignatureControl()
{
InitializeComponent();
AllowDrag = false;
Movable = false;
this.AppearanceKey = “fixed-window”;
widget1.BorderStyle = Wisej.Web.BorderStyle.Solid;
widget1.InitScript = $@”this.init = function()
{{
var me = this;
console.log(“”inside init””);
$(this.container).ejSignature
({{
strokeWidth: 3,
isResponsive: true,
width: this.getWidth() + “”px””,
height: this.getHeight() + “”px””,
change: function(e) {{
me.fireWidgetEvent(“”change””, {{lastImage: e.lastImage}});
}}
}});
}}
this.loadSignature = function(data)
{{
var me = this;
console.log(“”in apply siganture””);
var obj = $(this.container).ejSignature(“”instance””); // Create object for signature control
console.log(“”after obj””);
canvas = obj._canvas[0];
context = canvas.getContext(“”2d””);
var img = new Image;
img.src = data; //specify image source
context.clearRect(0, 0, canvas.width, canvas.height); // Clear specified pixel
img.onload = function() {{
context.drawImage(img, 0, 0);
}}
console.log(“”after obj””);
}}”;
}
public void SetSignature(string imageData)
{
this.widget1.Call(“loadSignature”, imageData);
}
private void widget1_WidgetEvent(object sender, WidgetEventArgs e)
{
switch (e.Type)
{
case “change”:
OnSignatureChanged(e.Data.lastImage);
break;
}
}
public string Data { get; set; }
private void OnSignatureChanged(string imageData)
{
Data = imageData?.Split(‘,’)[1];
}
Thanks
Praveena
Hi Paul
Thank you for the update. But if the form and the control is already loaded, then calling the method in InitScript gives error “$ is not defined”. Any suggestions on how can this be fixed.
thanks
praveena
This is a lazy loading panel sample:
https://wisej.com/support/question/lazy-loading-panel
You need to change it from Wisej 1.5 to Wisej 2.x.
There is no max value available for the internal scrollbars, it’s available for the ScrollBar control.
As the example shows, you can check the ScrollEventType in the Scroll event: if (e.Type == ScrollEventType.Last)…
https://docs.wisej.com/api/wisej.web/enumerations/wisej.web.scrolleventtype
Hi Ruben,
You should check out the DataRepeater control. It features templating & Virtual Mode (https://docs.wisej.com/docs/controls/lists/datarepeater). VirtualMode allows you to specify your own data management system. Basically, you need to implement ItemUpdate, ItemValueNeeded, etc. It helps a lot when working with large datasets as you only render a few visible records on the client at a time.
You can check the scroll position of a Panel with this.panel1.VerticalScroll.Value.
HTH,
Levie
Hi Vincent,
This is a confirmed bug, I’ll let you know when it’s fixed.
Thank you for reporting it!
Best,
Alaa
Hi Praveena
You could follow the directions in this link: https://help.syncfusion.com/js/signature/how-to#pre-load-signature-image
You can add another method in the InitScript (i.e. applySignature) that takes the URL of the image as an argument.
Then just use this.widget1.Call(“applySignature”, “some/url/.png”)
HTH
Regards
Hi Tobias,
You can authenticate within the Wisej application by implementing IWisejHandler on a Page.
It allows the user to register a postback url and process / serve documents within it using the ProcessRequest handler, you can find more about it here: IWisejHandler – Wisej API
I have attached a small sample that demonstrates how you can implement it.
Let me know if you need anything.
HTH,
Alaa
Hi Pavel,
you can get unique IDs by adding this to your default.json:
"options": {"automation.mode": true},
Best regards,
Frank
