Welcome Guest Search | Active Topics | Sign In | Register

How can I do that ? Options
Real Drouin
Posted: Friday, October 23, 2009 7:46:54 AM
Rank: Member
Groups: Member

Joined: 10/22/2009
Posts: 13
I have a window for customers.

On the left side, I have the treeview of the customers. Only the customer name is showing.

On the right side, there is many fields for the customer details (Customer number, name, address, city, state, email, phone, etc...)

What the user want is "simple" (according to them). When they "mouseover" a customer on the left handside, I mean in the treeviewm, they want the program to refresh the right handside with the customer information.

Is there's a "onmouseover" I can add to my program that will call one of my class ?

If not, do you have a work around ?

Thanks
Real
eo_support
Posted: Friday, October 23, 2009 8:54:59 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,217
Hi,

It is very easy but there are different ways and scenarios. You will need to understand each scenario in order to choose one that fits you best, and also need to be able to adapt it to fit your particular business logics.

We will only tell you what the TreeView can do. You can then see which one works for you:

Case 1
The TreeView can fire JavaScript code when mouse hovers over an item. This is done by setting the TreeView's ClientSideOnItemMouseOver property to a JavaScript function;
a. If you know how to refresh your customers windows from JavaScript directly, this is the way to go;
b. JavaScript code can trigger server side code (C# code). So if you must update the window from your server side code, in theory it can be an option as well. However triggering such code from mouse over is generally not recommended because mouse over occurs very frequently and every time you trigger server side code your page reloads. Thus in reality nobody wants to do that because then every time you move your mouse your page reloads;

Case 2
The Treeview can fire JavaScript code when mouse is clicked. Both 1.a and 1.b still applies --- you can update the window directly with JavaScript; or trigger server side event if you prefer. Mouse click does not have the same problem as mouse over in term of server event;

Case 3
The TreeView can fire server side event handler (C# code) on mouse click. You will need to set RaisesServerEvent and also provide a server side event handler for this to work;

Case 4
The TreeView can navigate any window (either the main window or an iframe inside the main window) to another Url. You will need to set the TreeNode's NavigateUrl and optionally the TreeView's TargetFrame or TreeNode's TargetWindow property for this to work properly. Loading any Url triggers that page's Page_Load event handler (if the page is an .aspx page). However you will need to deal with cache in this case because if the browser decides to cache the page, then the target page will not be reloaded from the server thus its Page_Load will not be called;

Note there are still a lot of other features that may be useful to you, but the above four are probably the most relevant.

You can take a look of all these options and see if it makes sense for you. We believe #1.a is the best solution and #4 can be a compromise but both depend on a lot of other factors. We will not go into your particular business scenario and provide specific advice on how to implement each scenario because we want to avoid situations where we spent a lot of extra effort to implement the solution (which is not within the scope of our support) for you and you still claim that the product does not do what you need and request a refund. So we want to make clear to you about what the product can do first. If you wish us to go further than that, we will need you to sign a waiver that acknowledges that we are to provide you extra service thus you agrees to either pay additional for the extra service (for instance, if you need us to provide additional hand on step by step training service); or agrees that you understand you will not be eligible for refund once such extra service is rendered.

Thanks!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.