Daily Archives

Articles indexed Sunday March 21 2010

Page 27/85 | < Previous Page | 23 24 25 26 27 28 29 30 31 32 33 34  | Next Page >

  • [grails] attaching multiple files to a domain class

    - by Emyr
    I've seen various Grails plugins which allow easier handling of file uploads, however these tend only to support a single file per form-submit. I'd like a multi-attach form where as soon as you pick one file, an extra field and button is added using JS (various sites do it like this). Do you know of any good plugins which provide elegant uploading of multiple files without excessive coding? A progress bar either per-file of for the whole process would also be very nice. I don't know to what extent I can allow GORM to handle a java.io.File field (or in this case a Collection<File>).

    Read the article

  • iPhone - access location information from a photo.

    - by bpapa
    Is it possible, in an iPhone app, to extract location information (geocode, I suppose it's called) from a photo taken with the iPhone camera? If there is no API call to do it, is there any known way to parse the bytes of data to extract the information? Something I can roll on my own?

    Read the article

  • Selenium RC > how to upload file using attachFile()

    - by Saara
    hello, I am using Selenium RC with Junit framework. I am trying to upload a file using attachFile() method. attachFile: (Information collected from selenium API http://release.seleniumhq.org/selenium-remote-control/1.0-beta-2/doc/java/com/thoughtworks/selenium/Selenium.html#attachFile(java.lang.String,%20java.lang.String)) void attachFile(java.lang.String fieldLocator, java.lang.String fileLocator) Sets a file input (upload) field to the file listed in fileLocator Parameters: fieldLocator - an element locator fileLocator - a URL pointing to the specified file. Before the file can be set in the input field (fieldLocator), Selenium RC may need to transfer the file to the local machine before attaching the file in a web page form. This is common in selenium grid configurations where the RC server driving the browser is not the same machine that started the test. Supported Browsers: Firefox ("*chrome") only. Can anyone please tell me how to define "fileLocator". I am not getting which URL to be specify over here. Please give me an example if possible.

    Read the article

  • ms sql server identity counterpart problem

    - by Guru
    hi there, I'm using MS Sql Server and I want to use identity constraint in it I know how to use it in following manner create table mytable ( c1 int primary key identity(1,1); ) the above code works fine but what if i want the identity column to have values as EMP001, EMP002,... instead of 1,2.... Thanks in advance, Guru

    Read the article

  • How many copies of files are needed by video server?

    - by Trilok
    A quick question. How many copies of the same movie are kept in a video server (a video streaming server)? Suppose a particular video is at max requested by 1000 users at the same instant of time, how many copies would be sufficient so that parallel streams can be provided to each user? Ideally 1 copy would solve the purpose, but what is the optimum number keeping the bandwidth and simultaneous access in mind?

    Read the article

  • Hiding a value in an Android application

    - by Ewan
    Hi, I need to hide a value in a mobile (Android OS) application. As far as I can see, encrypting the value is of no use as the key to the encryption mechanism must be available to the program and is thus available to an attacker reverse-engineering the code. So, it seems that the only "solution" is to hide the secret value in the application as well as possible, obviously not ideal. Any comments? Am I missing something? If not, what's the best way to hide the value? Thanks for your ideas! Ewan

    Read the article

  • Windows Phone - OnNavigatingFrom - problem

    - by Martin Anderson
    I believe this is just a problem for me, due to my lack of programming ability. I am currently exploring transitions between page navigation with Windows Phone apps. I was originally using storyboards, and completed event handlers to have my pages animate on and off screen. These leads to the a problem when you want to navigate to many pages from one page, using the same transition. So I have started looking at OnNavigatedTo, and OnNavigatingFrom events and while it is working nicely for OnNavigatedTo, the later just wont work. It seems the Microsoft.Phone.Navigation assembly does not contain OnNavigatingFrom, and referencing System.Windows.Navigation, compiles ok, but I cant get pages to animate off upon navigation. I have a button on my Page2, which I want to go back to my MainPage (after I over-rided the back key with a message box for testing). I have transitions made on the page, and I have this as the event handler code... private void btnP2_BackToP1Clicked(object sender, System.Windows.RoutedEventArgs e) { NavigationService.Navigate(new Uri("/MainPage.xaml", UriKind.Relative)); } With this code for the OnNavigatedTo and OnNavigatingFrom events... protected override void OnNavigatedTo(PhoneNavigationEventArgs e) { PageTransition_In.Begin(); } // // protected override void OnNavigatingFrom(NavigatingCancelEventArgs e) { PageTransition_Out.Begin(); base.OnNavigatingFrom(e); } I have the feeling that OnNavigatingFrom may not(yet) be supported for Windows Phone Apps. OnNavigatedFrom is part of Microsoft.Phone.Navigation, but it only performs actions once the page is no longer active, which is too late to perform any animation effects.

    Read the article

  • attaching multiple files to a domain class

    - by Emyr
    I've seen various Grails plugins which allow easier handling of file uploads, however these tend only to support a single file per form-submit. I'd like a multi-attach form where as soon as you pick one file, an extra field and button is added using JS (various sites do it like this). Do you know of any good plugins which provide elegant uploading of multiple files without excessive coding? A progress bar either per-file of for the whole process would also be very nice. I don't know to what extent I can allow GORM to handle a java.io.File field (or in this case a Collection<File>).

    Read the article

  • SQL Server identity counterpart problem

    - by Guru
    Hi there, I'm using SQL Server and I want to use identity constraint in it I know how to use it in following manner create table mytable ( c1 int primary key identity(1,1); ) the above code works fine but what if i want the identity column to have values as EMP001, EMP002,... instead of 1,2.... Thanks in advance, Guru

    Read the article

  • php dom problem

    - by Guru
    hello I'm new to PHP programming and I migrated from ASP .net to PHP.. I have a div just like below <div id="mydiv"></div> what I wanted to do is just to change the text and html content(like some name or any data in it) in it. What I imagine is just like mydiv=innertext="some value"; Thanks, GURU

    Read the article

  • using an existing object in ajax-called php files?

    - by noname
    i have in my index.php created an object and set some property values. then i use jquery ajax to call some php files and i want to use the object created. i tried this one but it didn´t work: ---- in index.php ---- // Create a new object session_start(); $object = new stdClass(); $object->value = 'something'; $object->other_value = 'something else'; // Save the object in the user's session $_SESSION['object'] = $object; ---- Then in the next page that loads from AJAX ---- // Start the session saved from last time session_start(); // Get the object out $object = $_SESSION['object']; // Prints "something" print $object->value; how do i accomplish this. cause i dont want to recreate the object in every ajaxcalled php script. thanks in advance!

    Read the article

  • c# const in jQuery?

    - by Cristian Boariu
    Hi guys, I have this piece of code in javascript: var catId = $.getURLParam("category"); In my asp.net and c# code for "category" query string i use a public const: public const string CATEGORY = "category"; so if i want to change the query string parameter to be "categoryTest" i only change this const and all the code is updated. Now the question is: how can i do something similar for the javascript i have in the same application (so i want to use the same constant)? I mean i want something like this: var catId = $.getURLParam(CQueryStringParameters.CATEGORY); but because there are none asp.net tags, my const is not interpreted... Any workaround?

    Read the article

  • UINavigationController placement problem

    - by Chonch
    Hey, I'm having this problem and I can't seem to figure out why! I want to use a UINavigationController, but I don't want to use it through out the entire application. So, in the UIViewController I was to add it to, I define: UINavigationController *navigationController; and the @property, @synthesize and dealloc. In the viewDidLoad method, I add: navigationController = [[UINavigationController alloc] init]; navigationController.navigationBar.barStyle = UIBarStyleBlack; and when the relevant UIViewController is loaded, I add: [navigationController pushViewController:viewController animated:NO]; and make the old view disappear and the UINavigationController's view to appear. Everything works fine except that the navigation bar appears about 20pixels too low (dragging the entire view down and out of the screen). If I set the UINavigationController's view frame parameter manually to start at 0,0, it jumps there, but only after about a second, so that you can see the navigation bar starting at a certain location and only then jumping to another (and it is ugly!). I have done the exact same thing in the past and had no problem with it. Does anyone know what may cause this? Thanks,

    Read the article

  • RichFaces rich:panel header not appearing

    - by Mark Lewis
    Hello I specified this <rich:panel> <f:facet name="header"> Panel #1. Changing Style Synchronously </f:facet> Each component in the RichFaces has a pre-defined set of classes you can manipulate with. If defined, those classes overwrite the ones come from the skin. </rich:panel> from the RichFaces demo, in my JSF page and no header appears, although I've nothing in my css which would interfere. What might be the reason for this? Thanks

    Read the article

  • Help to choose NoSQL database for project

    - by potapuff
    There is a table: doc_id(integer)-value(integer) Approximate 100k doc_id and 27?? rows. Majority query on this table - searching documents similar to current document: select 10 documents with maximum of (count common to current document value)/(count ov values in document). Nowadays we use PostgreSQL. Table weight (with index) ~1,5 GB. Average query time ~0.5s. Should I transfer all this to NoSQL base, if so, what?

    Read the article

  • Why Java SimpleDateFormat().parse() is giving weird formate?

    - by MAK
    My input is String formated as the following: 3/4/2010 10:40:01 AM 3/4/2010 10:38:31 AM My code is: DateFormat dateFormat = new SimpleDateFormat("dd/mm/yyyy hh:mm:ss aa"); try { Date today = dateFormat.parse(time); System.out.println("Date Time : " + today); } catch (ParseException e) { e.printStackTrace(); } the output is: Sun Jan 03 10:38:31 AST 2010 Sun Jan 03 10:40:01 AST 2010 I'm not sure from where the day (Sun) came from? or (AST)? and why the date is wrong? I just wanted to keep the same format of the original String date and make it into a Date object. I'm using Netbeans 6.8 Mac version.

    Read the article

< Previous Page | 23 24 25 26 27 28 29 30 31 32 33 34  | Next Page >