Showing posts with label browser. Show all posts
Showing posts with label browser. Show all posts

Wednesday, March 28, 2012

Programmatically Select a listview item

Can't seem to figure out how to do this. The listview class browser doesn't list much in the way of an API call to do this. Anyone know if this is possible?Did you figure this out?

ListView.SelectedListViewItemCollection listViewItemCollection = this.ListView1.SelectedItems;

foreach ( ListViewItem item in listViewItemCollection)
{
//Your code goes here
}


ListView1.Items(0).Selected = True
ListView1.Select()

The first line indicates what item is to be selected, and the second line is what actually selects it. The most common mistake is leaving out the second line.

Saturday, March 24, 2012

Question about atlas and web interface update

Is the following scenario possible with atlas:

A web based application is run on a server, so clients use web browser to access it. The application uses inforamation from a database to populate the UI with the information. The information is stored in a database and can be changed either from the application or some other source (lets say another server). Is is possible to update the UI on a user's computer when the database is updated from the other server (the user doesn't need to refresh the screen manualy)?

Thanks in advance,
Marko Vuksanovic.

hello.

well, it's possible, though probably not as you wanted. what you must do is poll the server from the client from x to x seconds and if there's new info, then refresh the client. the most common approach is:

1- wrap the contents that need to be refreshed with an updatepanel

2- call the web service from x to x seconds; if there's new info, then refresh the panel.