view

Do I need a view for every action?

I have been developing in ASP.NET MVC for a short while. Up to this point, the controller actions have been fairly simple. Each action returns its corresponding view. However, I recently created an action that I don't necessarily need a page for (the purpose of the action is to work with the database). My question is - what is the prop...

Get the position of an element in Android's List View

Hey, my friend and i develop a Android programm. Now we got to the question if it's possible to get the actual position of an ListElement. Example: You drag the list up and down, and now you want to konw which element is on the center of the screen? can anyone help us? ...

Rendering a View in MVC then immediately redirecting

Hi- What I am trying to do is render a View in an MVC site informing the user to not refresh their browser while server side processing is taking place. This could be a long running task, and if they hit refresh it will send the request again, thus sending them to the error screen when the process was actually successful. I was going t...

Encapsulating Postgres query in view makes it extremely slow

I have a query that runs in about 5 seconds on Postgres 8.4. It selects data from a view joined to some other tables, but also uses the lag() window function, ie. SELECT *, lag(column1) OVER (PARTITION BY key1 ORDER BY ...), lag(...) FROM view1 v JOIN othertables USING (...) WHERE ... For convenience I created a new view that simply h...

Grid View inside Grid view

Dear All, I have a master grid and a child grid which is one of the column of the master Grid and whose data is getting bound to datasource on rowDataBound of master grid view. Now the thing that I want is to get the value of one of the columns of the master grid on the row command of the child grid. Is it possible in any way? Please s...

Default Display doesn't update

Hi! I'm stuck with a simple program. I want to grab images from an external server every x seconds and display it on my android. My problem is that the display doesn't update. When I put everything in one class it works perfectly. The code beneath compiles and runs without any error but there must be something I missed because the scree...

asp.net mvc c# - how to use check box in view and get it's value in model?

Hello everybody, can I use it like this in View? <%= Html.CheckBoxFor(user => user.Role, "Administrator")%> and then just read a value of property in model if checkbox is checked: string role = user.Role; (role = "Administrator") Help me please! Take care, Ragims ...

MVVM - how show view?

My MVVM application started with App.xaml.cs Here I create a main window. It has frame. Here I put LoginView. It has button "Login". I have command, which checks and do login. This code I have in LoginViewModel. If all ok - I should show the next View. How I can do it? App.xaml.cs private void OnStartup(object sender, Start...

How to get data back from partial view

Hi, I have a partial view (using MVC2 .net) inside a view which is a form. the partial view has a textbox and is strongly typed. The problem is I can't get the textbox data from the partial view when I post back, for some reason I can get all the view data inputs on the controller but the partial view, doesn't return the textbox data. ...

PHP data array variable not defined in view

I am using codeIgniter and I am trying to pass an array of data. I have written like this: $data['username']="Dumbo"; I also wrote this: $data['shouts']=$this->Musers->getShout(); // retrieve data from table Then I write: $this->load->view("welcome_message", $data); In view page, I wrote: <?php echo $username; foreach ($...

Android. GLSurfaceView doesn't become invisible

I have an activity with GLSurfaseView as content. I must do that view invisible on Back button pressed. I hold onKey method and, how it seems to me, make all as need. Code is here: public boolean onKey(View v, int keyCode, KeyEvent event) { return super.onKeyDown(keyCode, event); } @Override public boolean onKeyDown(int...

IPhone SDK: Camera access ??

Hello Everybody, I want to know how to access the iphones camera and work with it in realtime: for example just draw on the camera view. Another related Question: Can I display 4 camera-views at once like in "Photo Booth" on the Mac. ...

Android tabs - avoid recreating activities on tab clicks

I've put a little app together that has three tabs to show three different web pages. It does work however I am bit worried I haven't got enough control over how this whole thing works. When I click a tab, I get a web page loaded (see code sample below), now when I click another tab another page loads in another view. When I go back to t...

Android refresh StateListDrawable problem

Hi all, I have a strange problem with StateListDrawable or maybe (probably) I'm missing something. I created a test application for it and the same problem occurs. So, this is my StateListDrawable resourse in file test_selection.xml <?xml version="1.0" encoding="utf-8"?> <selector xmlns:android="http://schemas.android.com/apk/res/androi...

Custom View - Conditional View -- ViewStub & RadioButtons

Hi, I am creating a custom view which populates based on a condition "Yes" or "No", implemented through RadioButtons & ViewStub. Unfortunately things are not going as planned: CustomView -- artooConditional: public artooConditional(Context context, AttributeSet attrs) { super(context, attrs); setAttributes(attrs); ...

How to Create Customize layout?

Hai All, How to create Customize Layout in Android ? My plbm is i m dispalying Images in grid view, when the user reached the last image in the gird view , It must display " click here to View More Images" Message. ...

ASP.NET MVC2 View Model for multiple view forms and data

Hi, one thing that has been puzzling me since learning MVC2 is the following case scenario: I have a view which contains two latest news lists, a login form and a signup form. Every example I found on Views and View Models so far has a one-to-one example such as a simple login form etc. But how do I create a model that provides the pr...

Hiding folder structure for a view in SharePoint 2010 list definition

There's a setting on the "Edit View" page in SharePoint 2010 that allows you to show all items in a list, ignoring folder structure. The setting is under Folders > Folders or Flat > Show all items without folders. My question is: Is there any way to enable this setting via an XML list definition created in Visual Studio 2010? Is there...

Android: Illegal View State Exception on Keyguard unlock

I have an activity, on which when I press the Keyguard lock button, the onDestroy() function is called. At then when I disable the keyguard lock, that activity is shown no more as I get a RuntimeException in Illegal View State. How can I prevent from onDestroy() to be called? Please help. ...

Core Plot and Split Views...Impossible??

This is a general question regarding pulling up a CP plot in a split view controller. I have menu items pointing to individual view controllers pre-loaded with everything core plot related. My question is can anyone fill me in on a good way to present the graphs on the right pane while still showing the left pane? The way that I h...