iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
Hello,
We use the WebDesktopManager to manage details about our clients. Our WebDesktopWindows are named according the the unique ClientID of the client.
For example, details of client John Doe, with a clientid of 199 would be opened in window:wndClient-199
I need to create a function to cycle through all open Windows and return the clientid's of the open clients in an array. So, with the above example, I need to have a way to have an integer array returned with a size of 1, with an integer value of 199.
Thank you in advance
You could retrieve all the windows object of the WebDesktopManager using the Windows property. In order to achieve the scenario, you will need to parse the Name property of the Window object and split the Name on "-" separator. Here is snippet for the client side:
function AlertClientID() { var deskktopMng = ISGetObject("WebDesktopManager1"); var idList = new Array(); var windowList = deskktopMng.Windows; var arrIndex = 0; for(var i = 0; i < windowList.length; i++) { var nameComp = windowList[i].Name.split("-"); if (windowList[i].ClientVisible == true) { idList[arrIndex] = nameComp[1]; arrIndex++; } } alert(idList.join("\r\n")); }
Here is the snippet for the server side:
ArrayList idList = new ArrayList();foreach (WebDesktopWindow wnd in WebDesktopManager1.Windows){ string[] nameComp = wnd.Name.Split(new string[] { "-" }, StringSplitOptions.RemoveEmptyEntries); if(wnd.ClientVisible == true) idList.Add(nameComp[1]);}//Process arraylist
The snippet will only hold the ID of the window which displayed to the user.
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname