Search Results

Search found 8021 results on 321 pages for 'resource monitoring'.

Page 116/321 | < Previous Page | 112 113 114 115 116 117 118 119 120 121 122 123  | Next Page >

  • silverlight adding single prism command delegate to a list of items in xaml

    - by bobwah
    I'm building a menu using Prism (using a trtelerik tree view with hierarchy data templates but hopefully the details don't matter) and I'm trying to set up a Click.Command on each menu items bindings that will all call the same delegate command which is defined in the view model. The menu is built up out of items which I don't really want to put any references to the command in. How do I bind the command to each of these items in xaml? I've looked around and it looks like in WPF I could use a relative source binding and find ancestors but there doesn't seem to be a way of doing this in silverlight. Can I setup the delegate as a static resource somehow? I don't think I can create a static resource to the view model as this uses Unity to resolve paramters to it's constructor.

    Read the article

  • Render ViewComponent from another component codebehind

    - by George Polevoy
    I'm trying to render a component from withing another component. public override void Render() // ... var block = new Block(); block.Init(EngineContext, Context); block.Render(); // ... } The problem is that Block component can't find it's template. ResourceProcessingException Message: Unable to process resource 'components\CustomReportComponentComponent\default.vm': Resource could not be located I guess, other problems can arise because the component is not properly initialized. Is it possible to initialize a component from within another component's Render method, so it renders just as if called from a .vm?

    Read the article

  • How to highlight ListView item on touch?

    - by AndroidNoob
    I have a simple ListView and I want each of it items to be highlighted on user's touch. I thought this should happen by default but it isn't. Can you advice? ListView xml: <ListView android:id="@+id/list_view" android:layout_width="fill_parent" android:layout_height="fill_parent" android:padding="10dp" android:divider="#206600" android:dividerHeight="2dp" android:smoothScrollbar="true" android:background="#ffffff" > </ListView> And code of my Adapter: private class MyAdapter extends ArrayAdapter<Task> { private LayoutInflater mInflater; public MyAdapter(Context context, int resource, List<Task> list) { super(context, resource, list); mInflater = LayoutInflater.from(context); } @Override public View getView(int position, View convertView, ViewGroup parent) { View v = convertView; if (v == null) { v = mInflater.inflate(R.layout.list_item, null); } Task task = taskList.get(position); /* Setup views from your layout using data in Object here */ return v; }

    Read the article

  • How do I write a Photoshop Extension (8BX) plugin?

    - by Oliver Ahul
    The Adobe Photoshop CS3/4 SDk has a lot of examples for Filter, Import, Export etc plugins but I havent found anything that illustrates how to write a 8BX plugin. Reason I need to write one is to add a new drop down menu to the Photoshop root toolbar (where it displays File, Edit, Image .. Window. Help drop down menus). I have seen product like OneSoftware install an 8BX plugin into Adobe Photoshop CS3\Plug-Ins\Extensions directory that causes PS to add adrop down menu for OneSoft. That suggest this is a solvable problem :-) I tried by changing an existing plugin in the SDlK samples but no go. Specifically i modified the resource file: resource 'PiPL' (ResourceID, plugInName " PiPL", purgeable) { { Kind { **Extension** }, Name { plugInName "..." }, ... Despite using the Extension Kind , PS never loads the plugin. It doesnt generate any compile time or load error either. Anyone has ideas on how to go about doing this ? Thanks

    Read the article

  • Routing Error in Chapter 7.1.2 of the Ruby on Rails Tutorial

    - by user2985910
    I've been working through the tutorial for the past few days, and finally hit a snag in chapter 7. It is in this step where the line in routes.rb: get "users/new" is replaced with resource :users After I do this, I get a routing error when visiting http://localhost:3000/users/1 - No route matches [GET] "/users/1" instead of the other "Unknown Action" error shown here. Per the instructions, my routes.db file looks like this: SampleApp::Application.routes.draw do resource :users root "static_pages#home" match '/signup', to: 'users#new', via: 'get' match '/help', to: 'static_pages#help', via: 'get' match '/about', to: 'static_pages#about', via: 'get' match '/contact', to: 'static_pages#contact', via: 'get' end Output from 'rake routes' shows: Prefix Verb URI Pattern Controller#Action users POST /users(.:format) users#create new_users GET /users/new(.:format) users#new edit_users GET /users/edit(.:format) users#edit GET /users(.:format) users#show PATCH /users(.:format) users#update PUT /users(.:format) users#update DELETE /users(.:format) users#destroy root GET / static_pages#home signup GET /signup(.:format) users#new help GET /help(.:format) static_pages#help about GET /about(.:format) static_pages#about contact GET /contact(.:format) static_pages#contact Does anyone have any insight to get past this? Many thanks.

    Read the article

  • Windows Mobile application icon

    - by Andy White
    Is it possible to specify the application icon for a windows mobile app from a resource file or other configuration besides the .csproj? The reason I would like to do this is because I have an application that can be configured to run in several different ways. We would like to build out three unique .cabs based on these configurations, and we would like to use a different icon for each version. One option we've considered is just running multiple builds and swapping out the icon file each time, but we were hoping there would be a way to do this using a "resource" DLL or something along those lines, that could be compiled or linked in to the main .exe.

    Read the article

  • Are there any Objective-C / Cocoa naming conventions for properties that are acronyms?

    - by t6d
    I have an object that models an online resource. Therefore, my object has to store the URL of the resource it belongs to. How would I name the getter and setter? MyObject *myObject = [[MyObject alloc] init]; // Set values [myObject setURL:url]; myObject.URL = url; // Get values [myObject URL]; myObject.URL; or would the following be better: MyObject *myObject = [[MyObject alloc] init]; // Set values [myObject setUrl:url]; myObject.url = url; // Get values [myObject url]; myObject.url; The former example would of course require to define the property in the following way: @property (retain, getter = URL, setter = setURL:) NSURL *url;

    Read the article

  • REST and links: middle ground?

    - by pbean
    I've been wondering about how far to go with links in REST. Consider books which have authors, but there is obviously a many-to-many relationship between books an authors (a book can be written by multiple authors, and authors can write multiple books). So let's say we have a rest call http://server/book/21, which will return a book XML, containing information about an author. Now since the book is a resource, and the author is a resource, the XML should not straight up include all the author information. It should contain a link to the author information. But which of the below two examples is more widely accepted? (Excuse my crappy formatted XML, I am not that experienced with hand writing XML) <book> <title>Some Book</title> <authors> <author link="http://server/author/82">Some Guy</author> <author link="http://server/author/51">Some Other Guy</author> </authors> </book> Then, an author link would return more information: <author> <name>Some Guy</name> <dateOfBirth>some time</dateOfBirth> </author> Or: <book> <title>Some Book</title> <authors>http://server/book/21/authors</authors> </book> Where http://server/book/21/authors returns: <authors> <author link="http://server/author/82">Some Guy</author> <author link="http://server/author/51">Some Other Guy</author> </authors> And then each of those returns the former <author> example again. The reason I'm asking is basically because at my job they went with the second approach, and it seems to me that clients have to take many more steps to reach where they want to go. Also, for basic information which "you're always going to need" (author's name), you do have to take one additional step. On the other hand, that way the book resource only returns information about the book (nothing else), and to get anything else, you have to access other resources.

    Read the article

  • group by with 3 diffrent

    - by NN
    I have 2 table and I wanna a query with 3 column result in on of them 2 column with view count and title name and in the other 1 column with type_ and i wanna to grouping type_ with max(view count) and show the them title but i didn't have any idea about grouping expression. i think we can solve in by using sub query but i don't know which column use in group by. 2 table join with this expression class pk=resource key i exam this query: SELECT t.title,j.type_ FROM tags asset t,journal article j where type_ in (select type_ from journal article,tags asset where class pk=resource key group by type_) but the answer was wrong

    Read the article

  • Should I separate RESTful API controllers from "regular" controllers?

    - by keithjgrant
    This seems like an elementary question, but after a lot of searching around I can't seem to find a straightforward explanation: If I'm building a web application that is going to be accessed largely through a web browser, but that will also support some API requests in a RESTful way, should there be a large degree of separation between the two? On one hand, it seems a large amount of the functionality is the same, with identical data presented in different views (HTML vs. XML/JSON). But on the other hand, there are certain things I need to present to the browser that doesn't quite fit a RESTful approach: how to get an empty form to create a new instance of a resource and how to get a pre-populated form to edit an existing resource. Should these two different methods of accessing the system by funneled through different controllers? Different methods in the same controller? The exact same methods with a switch for view type?

    Read the article

  • One table for uploads for multiple resources in CakePHP

    - by Mef
    Hi, I have CakePHP app in which I'd like to attach gallery to multiple resources. Let's say I've got artists, each one has own gallery. I've got articles, every article has some images attached to it and so on. Now I set up tables like this: Artists hasMany Artistimages, fields in artistimages table are: id, artist_id, filename, filetype, filesize etc. Articles hasMany Articleimages, fields in articleimages table are: id, article_id, filename, filetype, filesize etc. ...but this is not how it should be, I think. Is there possibility to have one table called for example uploads which will contain all images with foreign key pointing to resource its reffering to? How to tell CakePHP which image is coming from which resource?

    Read the article

  • WPF StaticResource bound to subproperty

    - by mizipzor
    I have a class thats created as a resource: <Window.Resources> <Model:MyModel x:Key="model" /> </Window.Resources> The MyModel class has a cli property named Foo. I want the selected value in a combobox to be bound to this property. I thought I could do this but Im getting errors: <ComboBox SelectedItem="{Binding Source={StaticResource model.Foo}}" /> Heres the error: Cannot find resource named '{model.Foo}'. Where did I go wrong? What extra parameters do I need to specify to properly bind to a subproperty?

    Read the article

  • Dynamic Custom Fields for Data Model

    - by Jerry Deng
    I am in the process of creating a dynamic database where user will be able to create resource type where he/she can add custom fields (multiple texts, strings, and files) Each resource type will have the ability to display, import, export its data; I've been thinking about it and here are my approaches. I would love to hear what do you guys think. Ideas: just hashing all the custom data in a data field (pro: writing is easier, con: reading back out may be harder); children fields (the model will have multiple fields of strings, fields of text, and fields for file path); fixed number of custom fields in the same table with a key mapping data hash stored in the same row; Non-SQL approach, but then the problem would be generating/changing models on the fly to work with different custom fields;

    Read the article

  • save object associate to another object automatically

    - by Luca Romagnoli
    Hi i have these classes: class Core < ActiveRecord::Base belongs_to :resource, :polymorphic => true belongs_to :image, :class_name => 'Multimedia', :foreign_key => 'image_id' end class Place < ActiveRecord::Base has_one :core, :as => :resource end If i try do launch this: a = Place.find(5) a.name ="a" a.core.image_id = 24 a.save name is saved. image_id no i want save automatically all changes in records in relationship with place class at a.save command. is possible? thanks

    Read the article

  • ImageView.setImageURI does NOT work when trying to assign a R.drawable.X Uri

    - by Qlimax
    is related to: http://stackoverflow.com/questions/2307374/need-suggetsion-about-a-mixed-uri-int-id-images-ambient now my problem is that: ImageView imgView=(ImageView)findViewById(R.id.imgView); Uri imgUri=Uri.parse("android.resource://my.package.name/"+R.drawable.image); imageView.setImageURI(imgUri); does NOT work . why? i know that imgView.setImageDrawable(Drawable.createFromStream( getContentResolver().openInputStream(imgUri), null)); work. but that does NOT solve my problem. because I want to set the image with an uri independenty if this come from a resource or come from the camera ACTION_PICK intent... any suggestions are welcome. Thank you. Regards

    Read the article

  • integrate / build 'weather radar' widget

    - by zack
    I'm looking to integrate a 'weather radar' widget into a site I'm building. The only available resource I can find is: http://www.meteoonline.co.uk/gadgets/Europe/Netherlands/135 which basically delivers a flash mov in a iframe ! urrrgh! - and 'permission denied' of course with any javascript interaction on the iframe.. Can anyone suggest an alternative resource / or approach ? I'm happy to work with the raw data if I can get it .. any ideas welcome ! site is like [ html5 + jquery on django ]

    Read the article

  • WPF: Creating instances of resources?

    - by oakskc
    I'm brand spanking new to WPF and am trying to play around with projects to better understand what I'm reading. My understanding of a resource is that it is the instance, you can't use it like a factory and create instances of it. For example, a XAML-defined rectangle. You can reference it, but you can't have numerous instances of it all over the surface. In WPF, what would be the way to do that? If I define a Rectangle as a resource with specific properties and wanted to have multiple instances of that within a dynamically-generated grid, how should I be going about it? Or is there a different way I should be trying to do this? Purely academic exercise with no real-world application.

    Read the article

  • How to use LDAP for authentication in Tomcat with Custom Authorization

    - by djc4
    Hello, I'm using JNDIRealm with Tomcat for authentication, which at the moment works fine. However, we do not store any roles in the LDAP, so all authenticated users are not returning any roles. This sends user's to an HTTP 401 failed authorization page. I'd like to assign an "Admin" role to any and all user's who authenticate successfully. Here is my fragment from my web.xml file. SecurityConstraint Resource Resource *.jsp GET POST Admin FORM login.jsp loginError.jsp Admin Should I be using a JAASRealm with custom LoginModule? After the realm calls the authenticate() method and returns success, should I override another method to explicitly set the RolePrincipal to "Admin" so that authorization succeeds? Please help! Thanks, Andy

    Read the article

  • Adding java source (.java files) to test jar in Maven

    - by user320550
    Hi all, I'm making use of my pom.xml and am was able to generate the jar for src/main/java (say app.jar) as well as for src/test/java (say app-test.jar). I was also able to include my java sources as part of the app.jar (i.e. have both my .class as well as my .java files in the jar). However for my app-test.jar, i'm not able to include my .java files in it. This is my pom.xml: <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>com.mycompany.app</groupId> <artifactId>my-app</artifactId> <version>1.0-SNAPSHOT</version> <packaging>jar</packaging> <name>my-app</name> <url>http://maven.apache.org</url> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> </properties> <dependencies> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>3.8.1</version> <scope>test</scope> </dependency> </dependencies> <build> <resources> <resource> <directory>src/main/java</directory> </resource> </resources> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <version>2.3.1</version> <executions> <execution> <phase>package</phase> <goals> <goal>test-jar</goal> </goals> <configuration> <includes> <include>src/test/java</include> </includes> </configuration> </execution> </executions> </plugin> </plugins> </build> </project> Any help would be appreciated. Thanks. Update on post on Whaley's suggestion: Tried the maven-antrun-plugin, but rt now after running mvn package all i'm getting inside my tests.jar is the META-INF folder. .java and .class are not getting included: This is the part of the pom.xml <build> <resources> <resource> <directory>src/main/java</directory> </resource> </resources> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> <executions> <execution> <phase>package</phase> <goals> <goal>test-jar</goal> </goals> <configuration> <includes> <include>src/test/java</include> </includes> </configuration> </execution> </executions> </plugin> <plugin> <artifactId>maven-antrun-plugin</artifactId> <executions> <execution> <id>${project.artifactId}-include-sources</id> <phase>process-resources</phase> <goals> <goal>run</goal> </goals> <configuration> <tasks> <copy todir="${project.build.testOutputDirectory}"> <fileset dir="${project.build.testSourceDirectory}"/> </copy> </tasks> </configuration> </execution> </executions> </plugin> </plugins> </build> Thanks.

    Read the article

  • Ruby On Rails Routes

    - by Kezzer
    I can't figure out how to get the following routes. Here's an extract from my routes.rb file: map.resources :treatments map.root :controller => "home" map.connect ':controller/:action/:id' map.connect ':controller/:action/:id.:format' map.connect ':action', :controller => 'home' # replaces the need to manually map pure actions to a default controller map.resources :bookings map.resource :dashboard map.resource :home Now I do realise that the ordering matters, but I can't seem to get them to work correctly. What I want is so http://localhost:3000/bookings/new actually takes you to an action http://localhost:3000/bookings/signmeup if you're either not signed in, or haven't got a login. The problem is that if I change my routes around, when I attempt to create a new booking after I have logged in, then it doesn't POST the form submission and just takes me back to the view page. This is definitely because of the routes as if I rearrange map.resources :bookings to be before all of them, then it works. Any ideas?

    Read the article

  • Rails: Generic form actions, cancel link losing `:back` on validation failure

    - by Patrick Connor
    I am trying to create a generic set of Submit, Cancel, and Destroy actions for forms. At this point, it appears that everything is working, except that I lose :back functionality then a form reloads due to validation errors. Is there a way to catch the fact that validation has failed, and in that case, keep the request.env['HTTP_REFERER'] or :back value the same without having to edit every controller? = simple_form_for @announcement do |f| = f.error_notification = f.input :message = f.input :starts_at = f.input :ends_at #submit = f.button :submit = "or " = link_to("cancel", url_for(:back)) .right - if !f.object.new_record? - resource = (f.object.class.name).downcase = link_to "destroy", url_for(:action => 'destroy'), :confirm => "Are you sure that you want to delete this #{resource}?", :method => :delete .clear .non_input #post_back_msg #indicator.inline = image_tag "indicator.gif" .inline = "Please wait..." .non_input

    Read the article

< Previous Page | 112 113 114 115 116 117 118 119 120 121 122 123  | Next Page >