Search Results

Search found 115 results on 5 pages for 'jessica shea'.

Page 3/5 | < Previous Page | 1 2 3 4 5  | Next Page >

  • Python API for VirtualBox

    - by jessica
    I have made a command-line interface for virtualbox such that the virtualbox can be controlled from a remote machine. now I am trying to implement the commmand-line interface using python virtualbox api. For that I have downloaded the pyvb package (python api documentation shows functions that can be used for implementing this under pyvb package). but when I give pyvb.vb.VB.startVM(instance of VB class,pyvb.vm.vbVM) SERVER SIDE CODE IS from pyvb.constants import * from pyvb.vm import * from pyvb.vb import * import xpcom import pyvb import os import socket import threading class ClientThread ( threading.Thread ): # Override Thread's init method to accept the parameters needed: def init ( self, channel, details ): self.channel = channel self.details = details threading.Thread.__init__ ( self ) def run ( self ): print 'Received connection:', self.details [ 0 ] while 1: s= self.channel.recv ( 1024 ) if(s!='end'): if(s=='start'): v=VB() pyvb.vb.VB.startVM(v,pyvb.vm.vbVM) else: self.channel.close() break print 'Closed connection:', self.details [ 0 ] server = socket.socket ( socket.AF_INET, socket.SOCK_STREAM ) server.bind ( ( '127.0.0.1', 2897 ) ) server.listen ( 5 ) while True: channel, details = server.accept() ClientThread ( channel, details ).start() it shows an error Exception in thread Thread-1: Traceback (most recent call last): File "/usr/lib/python2.5/threading.py", line 486, in __bootstrap_inner self.run() File "news.py", line 27, in run pyvb.vb.VB.startVM(v,pyvb.vm.vbVM.getUUID(m)) File "/usr/lib/python2.5/site-packages/pyvb-0.0.2-py2.5.egg/pyvb/vb.py", line 65, in startVM cmd='%s %s'%(VB_COMMAND_STARTVM, vm.getUUID()) AttributeError: 'str' object has no attribute 'getUUID'

    Read the article

  • Convert video format to Flash Video automatically

    - by Jessica Boxer
    I need to allow web site users to upload videos to my web site in various common formats. From these I need to convert them to Flash video, and also limit their lengths and size. I need to do this automatically as part of the web site processing. Is there some simple tool that will allow me to do this? If not, can you point me in a direction that might help me out. Thanks.

    Read the article

  • iPhone SDK: How do you download video files to the Document Directory and then play them?

    - by Jessica
    I've been fooling around with code for ages on this one, I would be very grateful if someone could provide a code sample that downloaded this file from a server http://www.archive.org/download/june_high/june_high_512kb.mp4, (By the way it's not actually this file, it's just a perfect example for anyone trying to help me) and then play it from the documents directory. I know it seems lazy of me to ask this but I have tried so many different variations of NSURLConnection that it's driving me crazy. Also, if I did manage to get the video file downloaded would I be correct in assuming this code would then successfully play it: NSArray *paths = NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask, YES); NSString *documentsDirectory = [paths objectAtIndex:0]; NSString *path = [documentsDirectory stringByAppendingPathComponent:@"june_high_512kb.mp4"]; NSURL *movieURL = [NSURL fileURLWithPath:path]; self.theMovie = [[MPMoviePlayerController alloc] initWithContentURL:movieURL]; [_theMovie play]; If the above code would work in playing a video file from the document directory, then I guess the only thing I would need to know is, how to download a video file from a server. Which is what seems to be my major problem. Any help is greatly appreciated.

    Read the article

  • BlackBerry - RadioButtonField, hide border on select

    - by Jessica
    I have a screen with two RadioButtonField objects. By default, the first RadioButtonField shows a rectangle around it to show its selected, and the rectangle moves if you change the selection to the other RadioButtonField or other buttons and textboxes on the page. What I would like to know is...is there a way to hide this border that shows the selection/border?

    Read the article

  • iPhone SDK:How do you play video inside a view? Rather than fullscreen.

    - by Jessica
    Hi, I am trying to play video inside a UIView, so my first step was to add a class for that view and start playing a movie in it using this code: - (IBAction)movie:(id)sender{ NSBundle *bundle = [NSBundle mainBundle]; NSString *moviePath = [bundle pathForResource:@"Movie" ofType:@"m4v"]; NSURL *movieURL = [[NSURL fileURLWithPath:moviePath] retain]; MPMoviePlayerController *theMovie = [[MPMoviePlayerController alloc] initWithContentURL:movieURL]; theMovie.scalingMode = MPMovieScalingModeAspectFill; [theMovie play]; } But this just crashes the app when using this method inside it's own class, but is fine elsewhere. Does anyone know how to play video inside a view? and avoid it being full screen?

    Read the article

  • create an independent hidden process

    - by Jessica
    I'm creating an application with its main window hidden by using the following code: STARTUPINFO siStartupInfo; PROCESS_INFORMATION piProcessInfo; memset(&siStartupInfo, 0, sizeof(siStartupInfo)); memset(&piProcessInfo, 0, sizeof(piProcessInfo)); siStartupInfo.cb = sizeof(siStartupInfo); siStartupInfo.dwFlags = STARTF_USESHOWWINDOW | STARTF_FORCEOFFFEEDBACK | STARTF_USESTDHANDLES; siStartupInfo.wShowWindow = SW_HIDE; if(CreateProcess(MyApplication, "", 0, 0, FALSE, 0, 0, 0, &siStartupInfo, &piProcessInfo) == FALSE) { // blah return 0; } Everything works correctly except my main application (the one calling this code) window loses focus when I open the new program. I tried lowering the priority of the new process but the focus problem is still there. Is there anyway to avoid this? furthermore, is there any way to create another process without using CreateProcess (or any of the API's that call CreateProcess like ShellExecute)? My guess is that my app is losing focus because it was given to the new process, even when it's hidden. To those of you curious out there that will certainly ask the usual "why do you want to do this", my answer is because I have a watchdog process that cannot be a service and it gets started whenever I open my main application. Satisfied? Thanks for the help. Code will be appreciated. Jess.

    Read the article

  • Minimizing SQL queries using join with one-to-many relationship

    - by Brian
    So let me preface this by saying that I'm not an SQL wizard by any means. What I want to do is simple as a concept, but has presented me with a small challenge when trying to minimize the amount of database queries I'm performing. Let's say I have a table of departments. Within each department is a list of employees. What is the most efficient way of listing all the departments and which employees are in each department. So for example if I have a department table with: id name 1 sales 2 marketing And a people table with: id department_id name 1 1 Tom 2 1 Bill 3 2 Jessica 4 1 Rachel 5 2 John What is the best way list all departments and all employees for each department like so: Sales Tom Bill Rachel Marketing Jessica John Pretend both tables are actually massive. (I want to avoid getting a list of departments, and then looping through the result and doing an individual query for each department). Think similarly of selecting the statuses/comments in a Facebook-like system, when statuses and comments are stored in separate tables.

    Read the article

  • MVC Entity Model not showing my table

    - by Jessica
    I have a database with multiple tables, and some basic relationships. Here is an example of the problem I am having: My Database: **Org** ID Name etc **Detail1** ID D1name **Org_Detail1** Org_ID Detail1_ID **Detail2** ID D2Name **Org_Detail2** Org_ID Detial1_ID BooleanField My problem is, the Org_detail1 table is not showing up in the entity model, but the Org_Details2 table does. I thought it may have been because the Org_Detail1 table only contains two ID fields that are both primary keys, while the Org_Details2 table contains 2 primary key ID fields as well as a boolean field. If I add a dummy field to Org_detail1 and update it, it still won't show up and wont allow me to add a new entity relating to the Org_Detail1 table. The table won't even show up in the list, but it is listed under the tables. Is there any solution to get this table to appear in my model?

    Read the article

  • Creating multiple markers in Google Maps using XML

    - by Jessica Stanley
    I'm almost sure this question has been asked before, but for the love of me I just can't find the answer anywhere. Basically what I want to do is create multiple markers on a custom Google Map I'm building. I already have an XML file with the coordinates (lat/lng) and title of each item. I'd like to take the data from the XML file and use it to create markers on the map. I've found how to do this using KML files and MySQL/PHP, but I need to know how to do it in Javascript. One more thing: I have a .xml file of my own, so it won't be like I'll be getting the data from a webpage because I believe (from research I've done today) that the code for that may be different. If anyone knows if this has been posted somewhere else before, could you please direct me there? I've literally been searching all day, this is my last resort. Thanks a ton!!!

    Read the article

  • iPhone SDK: My server doesn't support range header requests, does that mean it's impossible for me t

    - by Jessica
    I am currently developing an iPhone app, in which involves downloads of up to 300 mb. I have been told by my hosting service that my server does not support range header requests. However, when I download a file from my server using a download client, like safari download manager, resume options are available and work. Does this mean that they have a work around for servers that don't support range header requests and that I could possibly implement into my iPhone app? Or are they using a technique too complex to implement into the iPhone. If you know of a technique code samples will be greatly appreciated.

    Read the article

  • How can I return the number of rows affected in sqlplus to a shell script?

    - by jessica
    Here is my shell script: # Deletes data from the 'sample' table starting August 30, 2011. # This is done in stages with a 7 second break every # 2 seconds or so to free up the database for other users. # The message "Done." will be printed when there are # no database entries left to delete. user="*****" pass="*****" while(true); do starttime=`date +%s` while [[ $((`date +%s` - $starttime)) -lt 2 ]]; do sqlplus $user/$pass@//blabla <<EOF whenever sqlerror exit 1 delete from sample where sampletime >= to_date('08-30-2011','mm-dd-yyyy') and rownum <= 2; commit; EOF rows = ??? if [ $rows -eq 0 ] ; then echo "Done." exit 0; fi done sleep 7 done If there is no way to get the number of rows, maybe I can use an error code returned by sqlplus to figure out when to end the script? Any thoughts? Thank you!

    Read the article

  • Import C + Makefile into a linux IDE?

    - by Jessica
    I have a project for Linux that i've been developing for some time. Basically it's a bunch of C and H files together with a directory structure and a Makefile. Every time I need to debug something it's so painful, I need to manually search for var. definitions, structs, etc. Is there any good IDE out there for Linux that will allow me to import those files into a "project" and that will provide code completion or at least an easy way to get my bearings in the source code? thanks!

    Read the article

  • Using sscanf to parse two strings out

    - by Jessica
    I have a semi xml formatted file that contains line with the following format: <param name="Distance" value="1000Km" /> The first char in the string is usually a TAB or spaces. I've been using the following to try to parse the two strings out (from name and value): if(sscanf(lineread, "\t<param name=\"%s\" value=\"%s\" />", name, value) == 1) { //do something } name and value are char* Now, the result is always the same: name gets parse (I need to remove the quotes) and name is always empty. What am I doing wrong? Thanks, code is appreciated. Jess.

    Read the article

  • iPhone SDK: Downloading large files from a server into the app bundle.

    - by Jessica
    Hi, I am building an app that plays multiple video files, But I would like to know How do you download a video file (100mb - 300mb) from a server into the application's bundle so it can later be locally referred to in code? The reason I want this type of a set up in my app is that I don't want the app binary to be made unnecessarily large due to including videos some users may not want. Also does this violate any of apple's terms? Also would it be simple to implement a progress view with this kind of set up and if so how? Any help is appreciated.

    Read the article

  • Convert a GTK python script to C

    - by Jessica
    The following script will take a screenshot on a Gnome desktop. import gtk.gdk w = gtk.gdk.get_default_root_window() sz = w.get_size() pb = gtk.gdk.Pixbuf(gtk.gdk.COLORSPACE_RGB,False, 8, sz[0], sz[1]) pb = pb.get_from_drawable(w, w.get_colormap(), 0, 0, 0, 0, sz[0], sz[1]) if (pb != None): pb.save("screenshot.png", "png") print "Screenshot saved to screenshot.png." else: print "Unable to get the screenshot." Now, I've been trying to convert this to C and use it in one of the apps I am writing but so far i've been unsuccessful. Is there any what to do this in C (on Linux)? Thanks! Jess.

    Read the article

  • PHP list of specific files in a directory

    - by Jessica
    The following code will list all the file in a directy <?php if ($handle = opendir('.')) { while (false !== ($file = readdir($handle))) { if ($file != "." && $file != "..") { $thelist .= '<LI><a href="'.$file.'">'.$file.'</a>'; } } closedir($handle); } ?> <P>List of files:</p> <UL> <P><?=$thelist?></p> </UL> While this is very simple code it does it job. I'm now looking for a way to list ONLY file that have .xml (or .XML) at the end, how do I do that? Code is appreciate, thanks! jess

    Read the article

  • Hide selection border on RadioButtonField on blackberry?

    - by Jessica
    I have a screen with two RadioButtonField objects. By default, the first RadioButtonField shows a rectangle around it to show its selected, and the rectangle moves if you change the selection to the other RadioButtonField or other buttons and textboxes on the page. What I would like to know is...is there a way to hide this border that shows the selection/border?

    Read the article

  • Combining the value of GetLastError and a custom error message

    - by Jessica
    I have a function that returns a different DWORD value for each case there is an error. So I have the following defines: #define ERR_NO_DB_CONNECTION 0x90000 #define ERR_DB_NOT_OPEN 0x90001 #define ERR_DB_LOCKED 0x90002 #define ERR_DB_CONN_LOST 0x90003 Now, I return those values when an error occurs. I need to also return the value of GetLastError in the same return. No, I can't read it later. I tried combining it different ways, eg: return ERR_DB_NOT_OPEN + GetLastError(); and then extract the error by subtracting the value of ERR_DB_NOT_OPEN but since I need to use this in functions where there can be several return values it can get quite complex to do that. Is there any way to achieve this? I mean, combine the value + GetLastError and extract them later? Code is appreciated. Thanks Jess.

    Read the article

  • Finding the digit root of a number

    - by Jessica M.
    Study question is to find the digit root of a already provided number. The teacher provides us with the number 2638. In order to find the digit root you have to add each digit separately 2 + 6 + 3 + 8 = 19. Then you take the result 19 and add those two digits together 1 + 9 = 10. Do the same thing again 1 + 0 = 1. The digit root is 1. My first step was to use the variable total to add up the number 2638 to find the total of 19. Then I tried to use the second while loop to separate the two digits by using the % I have to try and solve the problem by using basic integer arithmetic (+, -, *, /). 1.Is it necessary and or possible to solve the problem using nested while loops? 2.Is my math correct? 3. As I wrote it here it does not run in Eclipse. Am I using the while loops correctly? import acm.program.*; public class Ch4Q7 extends ConsoleProgram { public void run(){ println("This program attempts to find the digit root of your number: "); int n = readInt("Please enter your number: "); int total = 0; int root = total; while (n > 0 ){ total = total + (n %10); n = (n / 10); } while ( total > 0 ){ root = total; total = ((total % 10) + total / 10); } println("your root should be " + root); } }

    Read the article

  • Virtual Tour Viewer?

    - by Jessica
    My client wanted me to put a virtual tour video on their website. They bought it from "ForRent.com". They forwarded it to me, and its nothing but the panoramic images. When I asked about some type of viewer/player, they simply stated I would need js or flash installed on my computer (i do). Of course, thats not going to magically put these photos into a virtual tour. This is my first time working with a virtual tour, so does anyone know of any viewers I could just put the images into so that the user could click and drag?

    Read the article

  • How do I make my horizontally scrolling page work in IE?

    - by Jessica
    I am using a horizontal scroll for a page on my website ~ works great in FF but not in IE, how can i get it to work in IE? Here is the JS that I have in the head of my html: <script src="js/jquery-1.2.6.min.js" type="text/javascript" charset="utf-8"></script> <script type="text/javascript" charset="utf-8"> $(function(){ $("#page-wrap").wrapInner("<table><tr>"); $(".post").wrap("<td>"); });</script> There is also of course the other script file, but its huge so I'm not going to post it here. Is there a hack or something I can use to get it to scroll correctly in IE? Thx in advance!

    Read the article

  • iPhone SDK: Downloading large files from a server into the app's documents.

    - by Jessica
    Hi, I am building an app that plays multiple video files, But I would like to know How do you download a video file (100mb - 300mb) from a server into the application's documents so it can later be locally referred to in code? The reason I want this type of a set up in my app is that I don't want the app binary to be made unnecessarily large due to including videos some users may not want. Also does this violate any of apple's terms? Also would it be simple to implement a progress view with this kind of set up and if so how? Any help is appreciated.

    Read the article

  • how to combine changes tracked from several documents

    - by Jessica
    I tried to search the solution in internet, but found nothing, is there anyone who can help me? For my application, there is one document (Microsoft word), and this document is reviewed by several people in the "Track changes" mode, so the input to my application is the original document and the reviewed documents with changes (like insert/delete/comments). By this link , I know how to extract all the changes from the reviewed documents. what i want is to combine all the changes from all the reviewed documents into ONE document, and make all the changes "accepted", so the output of my application is one modified Microsoft document with all the changes (delete/insert/comment) accepted. My problem is that I don't know how to combine the changes from several documents into one single document. Anyone has an idea how to do this? Thank you very much in advance.

    Read the article

  • <div class="headerFst"> What is this?

    - by Jessica
    I have been attempting to remove a repeating header on all of my webpages for customization purposes, but have been unsuccessful finding what is causing this header repeat. I came across this code in the header, and after researching it, I can not find what its purpose is. Could this be my culprit for the repeating patterns? If not, please point me to the right direction. Here is the hmtl: <!--container--> <div id="container"> <div id="header"> <!--headerFst--> <div class="headerFst"> and here it is in look.css: div.headerFst { float:left; width:980px; padding-top:5px; } Thank you for viewing, and helping if possible.

    Read the article

< Previous Page | 1 2 3 4 5  | Next Page >