Daily Archives

Articles indexed Friday October 12 2012

Page 3/17 | < Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >

  • Issue with setting up multiple IP addresses on ubuntu server installation

    - by varunyellina
    I want to setup two ip addresses on my system for access through lan. This is my config on my other system. Desktop Installation My desktop installation runs with multiple IP's added through networkmanager both through lan and wifi. Server Installation On my server install I've edited /etc/network/interfaces to the following. auto eth0 auto eth0:1 # IP-1 iface eth0 inet static address 172.16.35.35 network 172.16.34.1 netmask 255.255.254.0 broadcast 172.166.35.255 dns-nameservers 172.16.100.221 8.8.8.8 # IP-2 iface eth0:1 inet static address 172.16.34.34 network 172.16.34.1 netmask 255.255.254.0 gateway 172.16.34.1 broadcast 172.16.35.255 After restarting through "/etc/init.d/networking restart" I recieve "Failed to bring up eth0:1" What am I doing wrong? Thankyou.

    Read the article

  • "Download failed, tap to resume"

    - by user96142
    I have shared folders on my Laptop System76 Pangolin Performance and installed Ubuntu One on my Motorola Droid RAZR. The folders show up on my Droid, however when I try to view them by tapping on them I get the following error, "Download failed, tap to resume". I have Googled for solutions and I have uninstalled and reinstalled the app on my t still have the problem. Does anyone have any suggestions?

    Read the article

  • unmet dependencies updating Intel graphics driver

    - by Nick Jacobs
    I am trying to update my graphics driver by running: sudo apt-get install xserver-xorg-video-intel But I keep getting this message: Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming. The following information may help to resolve the situation: The following packages have unmet dependencies: xserver-xorg-video-intel : Depends: xorg-video-abi-11 E: Unable to correct problems, you have held broken packages. When I run: sudo apt-get install -f Nothing happens, because the program doesn't even get half way to installing. I am running Lubuntu 12.04 on a HP Mini 110 netbook. I have tried changing to several different ppa's but that doesn't work. I want to update my driver so that my mouse stops flickering and ScummVM stops flickering every minute.

    Read the article

  • Which tools helps to start Ubuntu GUI when boot?

    - by Vimal Kumar
    I am on the way to create a Live CD from scratch. I used Virtual Box for this purpose. I installed Ubuntu base from ubuntumini.iso and installed gnome-shell. And installed Remastersys and created a backup.iso. Burned in a CD and boot from a PC. It end in CLI. Not lead to GUI. I tried the same ISO in VirtualBox. But it work properly there. I think I missed some packages which help to start GUI. Can you help me to identify the packages missed to include in the CD?

    Read the article

  • I cannot install a proporietary fglrx driver

    - by Chris
    OK my install failed while installing the amd proprietary driver. I keep seeing references to a Nvidia driver, but I do not have or even want anything pertaining to Nvidia. Here are my latest entries for the jockey.log: 2012-10-11 20:31:24,103 DEBUG: fglrx_updates is not the alternative in use 2012-10-11 20:31:24,119 DEBUG: fglrx.enabled(fglrx_updates): target_alt None current_alt /usr/lib/fglrx/ld.so.conf other target alt None other current alt /usr/lib/fglrx/alt_ld.so.conf 2012-10-11 20:31:24,119 DEBUG: fglrx_updates is not the alternative in use 2012-10-11 20:31:24,322 DEBUG: fglrx.enabled(fglrx): target_alt /usr/lib/fglrx/ld.so.conf current_alt /usr/lib/fglrx/ld.so.conf other target alt /usr/lib/fglrx/alt_ld.so.conf other current alt /usr/lib/fglrx/alt_ld.so.conf 2012-10-11 20:31:24,323 DEBUG: XorgDriverHandler(%s, %s).enabled(): No X.org driver set, not checking 2012-10-11 20:31:24,450 DEBUG: fglrx.enabled(fglrx_updates): target_alt None current_alt /usr/lib/fglrx/ld.so.conf other target alt None other current alt /usr/lib/fglrx/alt_ld.so.conf 2012-10-11 20:31:24,450 DEBUG: fglrx_updates is not the alternative in use 2012-10-11 20:31:24,465 DEBUG: fglrx.enabled(fglrx_updates): target_alt None current_alt /usr/lib/fglrx/ld.so.conf other target alt None other current alt /usr/lib/fglrx/alt_ld.so.conf 2012-10-11 20:31:24,465 DEBUG: fglrx_updates is not the alternative in use

    Read the article

  • nomachine NX: Text missing on all gtk interface (Unity and Gnome Classic)

    - by hansioux
    [Edit] I later realized my issue only occurs when I am using NX to remote access my machine. Therefore I edited the title and description. I have also found the temp solution, which is to "disable render extension" in the custom display settings. But doing so makes the NX experience very slow laggy, and not that nice to look at. [/EDIT] I did a fresh install on a new computer, and was trying to setup my fonts. When I log in remotely via NX, my the text are missing on all gtk based interfaces. That means most menues (except for unity), right click menues, applications themselves, terminal, and so on. About the only thing unaffected is firefox. all the texts are showing just fine for firefox. So that probably already says something about text permissions. I went to check if my fonts have the correct permissions and they do. I removed my custom settings from /etc/fonts/config.d, and still the texts are missing. There is a work around by using "disable render extension" in the custom display settings. How do I fix this issue permanently?

    Read the article

  • Ubuntu Server 12.04 as a router. Problem with DNS?? Or Routing table?

    - by Lorenzo
    I have a virtualbox lab made up of 4 Windows 2008 R2 servers (DC/DNS,SQL,SHAREPOINT, EXCHANGE) that are configured with static ip addresses with NIC's attached to Internal network. Everything works. I had the requirement to execute some tests that also access external services available on the internet. To keep things clean and similar to the production environment I have installed another VM, with Ubuntu Server 12.04 64 bit and configured (I hope) to work as a router like described on this post. This VM has two network interfaces: first is Bridged with the host and is used as a WAN connection and the other one attached in the Internal Network with its own static IP address on the internal network subnet. But actually the Windows servers does not connect to the internet while the unix one connects. I did a route command. this is the result: Kernel IP Routing table Destination Gateway Genmask Flags Metric Ref Use Iface default 10.69.121.1 0.0.0.0 UG 100 0 0 eth0 10.69.121.0 * 255.255.255.0 U 0 0 0 eth0 192.168.83.0 * 255.255.255.0 U 0 0 0 eth1 Can somebody help me with this configuration? :) Thanks! Addendum: I forgot to mention that one of the windows server hosts a DNS service for which I should maybe configure a forwarding server but I do not exactly know which server to forward on... :(

    Read the article

  • What program can I use to open .mld (recorded webcam) files?

    - by mike
    I am looking for a program to open video files with the extension .mld (This is a file from a video recording software I had a long time ago). Does anybody know any programs in Ubuntu that can open such files? Zoals de titel luidt: ik ben op zoek naar een programma dat videobestanden met de extensie .mld kan openen. Dit is een bestand van een wecbamrecorder die ik vroeger had op Windows. Alvast heel erg bedankt.

    Read the article

  • How can I deal with file association in different application(not in Nautilus)?

    - by Julius
    Maybe i don't understand the system. Upgraded to (reinstalled) Ubuntu 11.04. Is there any way the applications can use something that i set in nautilus, or it's just a wrong idea about the usage? In nautilus the file association works great, easy, handy and so on... My first problem was when installed chromium. Downloaded a file, a popup ask for assocation, set nautilus. And it only opens folder, for any file show an error: it is not a direcrory. Ok, so i thought Google chrome changed, because previously .pdf open acrobat,.torrent open vuze and so on. But now i have to open nautilus on download folder with it, than select and open the preferable application by manually and can't use any automatism i used to. Then in gnome commander , it not followed the default association i set in nautilus. Ok maybe it is commander fault. use it's own. Then in calibre, the "read" use again this default "can't open its not a directory" error So it's seems to me the applications not using well this file associations or i really don't understand the aim of file associations system (mime,.desktop files,...) If there is no solution i think i have to search some program (if any exist's) which can identify and launch application and set as default instead nautilus.

    Read the article

  • Map caps-lock key to middle mouse click

    - by Stefano Palazzo
    Since I rarely use caps-lock, I'd like to map the key to a middle mouse click instead. I would also like to map Alt+Caps Lock to the original function of the caps lock key, should I ever need it. I can map any keyboard shortcut to xdotool click 2, but the Gnome Keyboard Shortcuts dialog won't let me assign a command to the caps-lock key, even with modifiers. I know this is a bit of a strange undertaking; How would I go about doing it?

    Read the article

  • How to handle gender and sexual orientation on a form with select boxes more inclusively?

    - by Drew
    The existing question and the answers for it are not satisfying when one wants to be more inclusive. Gender as Male, Female or No Answer works for some sites, but not others. Taking the view that Gender is not the same as Sex (assigned at birth based on bodily characteristics). Would it be more inclusive to include these two options: Transgender Male, Transgender Female? So instead would more inclusive options be the following? Gender Identity Male Female Transgender Male Transgender Female No Answer Sexual Orientation Straight Lesbian Gay Bisexual Asexual No Answer Gender Expression could also be included, but I think most people would find that too confusing (defined on GLAAD's website linked below) I'm going off what I've read on GLAAD's Transgender Glossary of Terms. Thanks!

    Read the article

  • Using multiple A-records for my domain - do web browsers ever try more than one?

    - by Jonas
    If I add multiple A-records for my domain, they are returned in a round robin order by DNS-servers. E.g: 1.1.1.1 A example.com 1.1.1.2 A example.com 1.1.1.3 A example.com But how does webbrowsers react if the first host (1.1.1.1) is down (unreachable)? do they try the second host (1.1.1.2) or do they return a error message to the user? Are there any difference between the most popular browsers? If I implement my own application, I can implement so that the second is used in case the first is down, so it's possible. And this would be very helpful to create a fault tolerant website.

    Read the article

  • How to draw textures on a model

    - by marc wellman
    The following code is a complete XNA 3.1 program almost unaltered to that code skeleton Visual Studio is creating when creating a new project. The only things I have changed are imported a .x model to the content folder of the VS solution. (the model is a simple square with a texture spanning over it - made in Google Sketchup and exported with several .x exporters) in the Load() method I am loading the .x model into the game. The Draw() method uses a BasicEffect to render the model. Except these three things I haven't added any code. Why does the model does not show the texture ? What can I do to make the texture visible ? This is the texture file (a standard SketchUp texture from the palette): And this is what my program looks like - as you can see: No texture! Find below the complete source code of the program AND the complete .x file: namespace WindowsGame1 { /// <summary> /// This is the main type for your game /// </summary> public class Game1 : Microsoft.Xna.Framework.Game { GraphicsDeviceManager graphics; SpriteBatch spriteBatch; public Game1() { graphics = new GraphicsDeviceManager(this); Content.RootDirectory = "Content"; } /// <summary> /// Allows the game to perform any initialization it needs to before starting to run. /// This is where it can query for any required services and load any non-graphic /// related content. Calling base.Initialize will enumerate through any components /// and initialize them as well. /// </summary> protected override void Initialize() { // TODO: Add your initialization logic here base.Initialize(); } Model newModel; /// <summary> /// LoadContent will be called once per game and is the place to load /// all of your content. /// </summary> protected override void LoadContent() { // Create a new SpriteBatch, which can be used to draw textures. spriteBatch = new SpriteBatch(GraphicsDevice); // TODO: usse this.Content to load your game content here newModel = Content.Load<Model>(@"aau3d"); foreach (ModelMesh mesh in newModel.Meshes) { foreach (ModelMeshPart meshPart in mesh.MeshParts) { meshPart.Effect = new BasicEffect(this.GraphicsDevice, null); } } } /// <summary> /// UnloadContent will be called once per game and is the place to unload /// all content. /// </summary> protected override void UnloadContent() { // TODO: Unload any non ContentManager content here } /// <summary> /// Allows the game to run logic such as updating the world, /// checking for collisions, gathering input, and playing audio. /// </summary> /// <param name="gameTime">Provides a snapshot of timing values.</param> protected override void Update(GameTime gameTime) { // Allows the game to exit if (GamePad.GetState(PlayerIndex.One).Buttons.Back == ButtonState.Pressed) this.Exit(); // TODO: Add your update logic here base.Update(gameTime); } /// <summary> /// This is called when the game should draw itself. /// </summary> /// <param name="gameTime">Provides a snapshot of timing values.</param> protected override void Draw(GameTime gameTime) { if (newModel != null) { GraphicsDevice.Clear(Color.CornflowerBlue); Matrix[] transforms = new Matrix[newModel.Bones.Count]; newModel.CopyAbsoluteBoneTransformsTo(transforms); foreach (ModelMesh mesh in newModel.Meshes) { foreach (BasicEffect effect in mesh.Effects) { effect.EnableDefaultLighting(); effect.TextureEnabled = true; effect.World = transforms[mesh.ParentBone.Index] * Matrix.CreateRotationY(0) * Matrix.CreateTranslation(new Vector3(0, 0, 0)); effect.View = Matrix.CreateLookAt(new Vector3(200, 1000, 200), Vector3.Zero, Vector3.Up); effect.Projection = Matrix.CreatePerspectiveFieldOfView(MathHelper.ToRadians(45.0f), 0.75f, 1.0f, 10000.0f); } mesh.Draw(); } } base.Draw(gameTime); } } } This is the model I am using (.x): xof 0303txt 0032 // SketchUp 6 -> DirectX (c)2008 edecadoudal, supports: faces, normals and textures Material Default_Material{ 1.0;1.0;1.0;1.0;; 3.2; 0.000000;0.000000;0.000000;; 0.000000;0.000000;0.000000;; } Material _Groundcover_RiverRock_4inch_{ 0.568627450980392;0.494117647058824;0.427450980392157;1.0;; 3.2; 0.000000;0.000000;0.000000;; 0.000000;0.000000;0.000000;; TextureFilename { "aau3d.xGroundcover_RiverRock_4inch.jpg"; } } Mesh mesh_0{ 4; -81.6535;0.0000;74.8031;, -0.0000;0.0000;0.0000;, -81.6535;0.0000;0.0000;, -0.0000;0.0000;74.8031;; 2; 3;0,1,2, 3;1,0,3;; MeshMaterialList { 2; 2; 1, 1; { Default_Material } { _Groundcover_RiverRock_4inch_ } } MeshTextureCoords { 4; -2.1168,-3.4022; 1.0000,-0.0000; 1.0000,-3.4022; -2.1168,-0.0000;; } MeshNormals { 4; 0.0000;1.0000;-0.0000; 0.0000;1.0000;-0.0000; 0.0000;1.0000;-0.0000; 0.0000;1.0000;-0.0000;; 2; 3;0,1,2; 3;1,0,3;; } }

    Read the article

  • Research and replace Word Rtf

    - by Perello
    I'm working on an application which has a workflow for postal mails. These postal mails are generated according to my application business rules. Models are in html or Rtf and it works perfectly as long the user do not create the rtf with word. This is not within the specs, but my hierarchy would welcome a Word compatibility if it don't involve too much work, and it would please and ease the life of our customer. The Rtf models have tags which are replaced by application values. In most RTF, tags are not splitted, so the search and replace works perfectly. I wish to be handle word with few modifications. Example data : [[FooBuzz]] in most rtf it's not splited. In word 2003 : {\rtlch\fcs1 \af0 \ltrch\fcs0 \insrsid5517131 [[}{\rtlch\fcs1 \af0 \ltrch\fcs0 \insrsid2708730 FooBuzz}{\rtlch\fcs1 \af0 \ltrch\fcs0 \insrsid5517131 ]]} And their word (word 2007) splitted also Foo{garbage inside} Buzz. So i wish to be able to handle common RTF perfectly, and detect tags even if they are splitted. I have 2 constraints. First no regression, second it has to stay simple. Performance is not an issue here. I'm using symfony 1.4. The actual relevant research code part : $regExpression = '/\[\[([^\[\]]*)\]\]/'; preg_match_all($regExpression, $sTemplate, $outKeys);

    Read the article

  • Pass first element of jsp list to javascript

    - by Lucian Enache
    Ok so I'm trying to access the first element of a JSP list, here's what I've come up with so far without any kind of luck: onclick="alert('<%=list[0]%>');" What's the best approach to access the first element and eventually to pass it to a javascript variable/function ? I've heard that the <% %> tags are deprecated and some are suggesting relaying on JSTL/EL how can one use those without having to iterate the entire list and put a breakpoint for the iterators ?

    Read the article

  • NullPointerException on TextView

    - by Stephen Adipradhana
    i get a null pointer exception and the program crash on each time i want to update the highscore text using setText(). what causes this problem? this code is when i set my layout, the layout is a part of the gameView using opengl, and i put the highscore textview on the upper left corner public void onCreate(Bundle savedInstanceState) { SFEngine.display = ((WindowManager)getSystemService(Context.WINDOW_SERVICE)).getDefaultDisplay();//ambl ukuran width height layar super.onCreate(savedInstanceState); gameView = new SFGameView(this); gameView.setLayoutParams(new RelativeLayout.LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT)); RelativeLayout layout = new RelativeLayout(this); layout.setLayoutParams(new FrameLayout.LayoutParams(LayoutParams.MATCH_PARENT, LayoutParams.MATCH_PARENT)); TextView textBox = new TextView(this); textBox.setId(1); textBox.setText("HIGH SCORE"); textBox.setBackgroundColor(Color.BLUE); textBox.setWidth(SFEngine.display.getWidth()/2); textBox.setHeight(50); Button pauseButton = new Button(this); pauseButton.setText("PAUSE"); pauseButton.setHeight(50); pauseButton.setWidth(SFEngine.display.getWidth()/2); pauseButton.setOnTouchListener(new OnTouchListener(){ public boolean onTouch(View v, MotionEvent e) { //pause game SFEngine.isPlaying = false; Intent i1 = new Intent(SFGames.this, pause.class); gameView.onPause(); startActivityForResult(i1,0);//hrs pk result soalny mw blk lg return true; } }); RelativeLayout.LayoutParams lp_pause = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT); RelativeLayout.LayoutParams lp_hs = new RelativeLayout.LayoutParams(RelativeLayout.LayoutParams.WRAP_CONTENT, RelativeLayout.LayoutParams.WRAP_CONTENT); lp_hs.addRule(RelativeLayout.ALIGN_PARENT_LEFT); lp_pause.addRule(RelativeLayout.ALIGN_PARENT_TOP); lp_pause.addRule(RelativeLayout.ALIGN_PARENT_RIGHT); textBox.setLayoutParams(lp_hs); pauseButton.setLayoutParams(lp_pause); layout.addView(gameView); layout.addView(textBox); layout.addView(pauseButton); setContentView(layout); and here is the setText code public boolean onTouchEvent (MotionEvent event){//buat nerima input user if(!SFEngine.isPlaying){ finish(); } textBox.setText("High Score :" + SFEngine.score);//here is the source of the prob .....

    Read the article

  • How to re-enable the idle timer in ios once it has been disabled (to allow the display to sleep again)?

    - by lindon fox
    I have figured out how to stop an iOS device from going to sleep (see below), but I am having troubles undoing that setting. According to the Apple Documentation, it should just be changing the value of the idleTimerDisabled property. But when I test this, it does not work. This is how I am initially stopping the device from going to sleep: //need to switch off and on for it to work initially [UIApplication sharedApplication].idleTimerDisabled = NO; [UIApplication sharedApplication].idleTimerDisabled = YES; I would have thought that the following would do the trick: [UIApplication sharedApplication].idleTimerDisabled = NO; From the Apple Documentation: The default value of this property is NO. When most applications have no touches as user input for a short period, the system puts the device into a "sleep” state where the screen dims. This is done for the purposes of conserving power. However, applications that don't have user input except for the accelerometer—games, for instance—can, by setting this property to YES, disable the “idle timer” to avert system sleep. Important: You should set this property only if necessary and should be sure to reset it to NO when the need no longer exists. Most applications should let the system turn off the screen when the idle timer elapses. This includes audio applications. With appropriate use of Audio Session Services, playback and recording proceed uninterrupted when the screen turns off. The only applications that should disable the idle timer are mapping applications, games, or similar programs with sporadic user interaction. Has anyone come across this problem? I am testing on iOS6 and iOS5. Thanks in advance.

    Read the article

  • Pulling $_GET data and creating multidimensional array using loop

    - by Chris J
    I'm creating a checkout for customers and the data about what's in their cart is being sent to a page (for just now) via $_GET. I want to extract that data and then populate a multidimensional array with it using a loop. Here's how I'm naming the data: $itemCount = $_GET['itemCount']; $i = 1; while ($i <= $itemCount) { ${'item_name_'.$i} = $_GET["item_name_{$i}"]; ${'item_quantity_'.$i} = $_GET["item_quantity_{$i}"]; ${'item_price_'.$i} = $_GET["item_price_{$i}"]; //echo "<br />Name: " .${'item_name_'.$i}. " - Quantity: " .${'item_quantity_'.$i}. " - Price: ".${'item_price_'.$i}; $i++; } From here I'd like to create a multidimensional array like such: Array ( [Item_1] => Array ( [item_name] => Shoe [item_quantity] => 2 [item_price] => 40.00 ) [Item_2] => Array ( [item_name] => Bag [item_quantity] => 1 [item_price] => 60.00 ) [Item_3] => Array ( [item_name] => Parrot [item_quantity] => 4 [item_price] => 90.00 ) . . . ) What I'd like to know is if there is a way I can create this array in the existing while loop? I'm aware of being able to add data to an array like $data = [] after delacring an empty array but the actual syntax eludes me. Maybe I'm completely off the right track and there is a better way of doing it? Thanks

    Read the article

  • Passing arguments to UILabel [ 2 ] *

    - by DesperateLearner
    I'm trying to call a method of the below (Scroll animation class) type from a viewcontroller class. -(void)CreateLabel:(CGRect )frame andLabel:(UILabel *[NUM_LABELS])label andview:(UIView *)view; I got some errors when I tried passing the argument. Any suggestion on how to call this? This is how I called that method ScrollAnimation *newAnimation = [[ScrollAnimation alloc] init]; [newAnimation CreateLabel:CGRectMake(0, 50, 300,30) andLabel:animateLabel[NUM_LABELS] andview:self.view]; I have the error /Volumes/Red Drive/CarTransition/CarTransition/ViewController.m:120:66: Implicit conversion of an Objective-C pointer to 'UILabel **' is disallowed with ARC /Volumes/Red Drive/CarTransition/CarTransition/ViewController.m:120:66: Incompatible pointer types sending 'UILabel *__strong' to parameter of type 'UILabel **'

    Read the article

  • Why does this log output show the same answer in each iteration?

    - by Will Hancock
    OK, I was reading an article on optimising JS for Googles V8 engine, when i saw this code example... I nearly skimmed over it, but then I saw this; |=; a[0] |= b; a = new Array(); a[0] = 0; for (var b = 0; b < 10; b++) { console.log(a, b) a[0] |= b; // Much better! 2x faster. } a[0] |= b; So I ran it, in my console, with a console.log in the loop and resulted in 15; [15] 0 [15] 1 [15] 2 [15] 3 [15] 4 [15] 5 [15] 6 [15] 7 [15] 8 [15] 9 WHAT?!?! Where the hell does it get 15 from, on every iteration?!?!?! I've been a web dev for 7 years, and this has stumped me and a fellow colleague. Can somebody talk me through this code? Cheers.

    Read the article

  • Reusable non generic method for generic methods

    - by Jehof
    I have the following base interface public interface IHandler{ void Handle(IMessage message); } and an generic interface inheriting the base interface public interface IHandler<TMessage> : IHandler where TMessage : IMessage{ void Handle(TMessage message); } My classes can implement the interface IHandler<TMessage> mutiple times. IMessage is an base interface for messages and isn´t relevant here. Currently i´m implementing the interfaces as follows. public class ExampleHandler : IHandler<ExampleMessage>, IHandler<OtherExampleMessag>{ void IHandler.Handle(IMessage message){ ExampleMessage example = message as ExampleMessage; if (example != null) { Handle(example); } else { OtherExampleMessage otherExample = message as OtherExampleMessage; if (otherExample != null) { Handle(otherExample); } } public void Handle(ExampleMessage) { //handle message; } public void Handle(OtherExampleMessage) { //handle message; } } What bothers me is the way i have to implement the Handle(IMessage) method, cause in my opinion its many redundant code, and i have to extend the method each time when i implement a new IHandler<TMessage> interface on my class. What i´m looking for is a more generic way to implement the Handle(IMessage) method (maybe in a base class for Handlers), but i´m currently stuck how to do that.

    Read the article

  • Python: how to run several scripts (or functions) at the same time under windows 7 multicore processor 64bit

    - by Gianni
    sorry for this question because there are several examples in Stackoverflow. I am writing in order to clarify some of my doubts because I am quite new in Python language. i wrote a function: def clipmyfile(inFile,poly,outFile): ... # doing something with inFile and poly and return outFile Normally I do this: clipmyfile(inFile="File1.txt",poly="poly1.shp",outFile="res1.txt") clipmyfile(inFile="File2.txt",poly="poly2.shp",outFile="res2.txt") clipmyfile(inFile="File3.txt",poly="poly3.shp",outFile="res3.txt") ...... clipmyfile(inFile="File21.txt",poly="poly21.shp",outFile="res21.txt") I had read in this example Run several python programs at the same time and i can use (but probably i wrong) from multiprocessing import Pool p = Pool(21) # like in your example, running 21 separate processes to run the function in the same time and speed my analysis I am really honest to say that I didn't understand the next step. Thanks in advance for help and suggestion Gianni

    Read the article

  • Timespan not accepting day in MVC3

    - by middelpat
    I have a MVC3 application in which i want to set a timespan to for example 2 days and 5 hours. when i enter 02:05:00:00 it gives me the following exception: System.OverflowException: SqlDbType.Time overflow. Value '2.05:00:00' is out of range. Must be between 00:00:00.0000000 and 23:59:59.9999999. When i enter 05:00:00 it correctly saves 5 hours into the database. according to MSDN timespan has a property for days. How do i correctly set the days? Model: public class ProductionTimeVM { [Required] public TimeSpan DefaultTime { get; set; } } In my view i just use: @Html.TextBoxFor(x => x.DefaultTime) For my controller: public ActionResult SaveProductionTime(ProductionTimeVM vm) { ProductionTime productionTime = new ProductionTime(); productionTime.Default = vm.DefaultTime; //some more code } Any idea's?

    Read the article

  • MySQL inner join different results

    - by Darryl at NetHosted
    I am trying to work out why the following two queries return different results: SELECT DISTINCT i.id, i.date FROM `tblinvoices` i INNER JOIN `tblinvoiceitems` it ON it.userid=i.userid INNER JOIN `tblcustomfieldsvalues` cf ON it.relid=cf.relid WHERE i.`tax` = 0 AND i.`date` BETWEEN '2012-07-01' AND '2012-09-31' and SELECT DISTINCT i.id, i.date FROM `tblinvoices` i WHERE i.`tax` = 0 AND i.`date` BETWEEN '2012-07-01' AND '2012-09-31' Obviously the difference is the inner join here, but I don't understand why the one with the inner join is returning less results than the one without it, I would have thought since I didn't do any cross table references they should return the same results. The final query I am working towards is SELECT DISTINCT i.id, i.date FROM `tblinvoices` i INNER JOIN `tblinvoiceitems` it ON it.userid=i.userid INNER JOIN `tblcustomfieldsvalues` cf ON it.relid=cf.relid WHERE cf.`fieldid` =5 AND cf.`value` REGEXP '[A-Za-z]' AND i.`tax` = 0 AND i.`date` BETWEEN '2012-07-01' AND '2012-09-31' But because of the different results that seem incorrect when I add the inner join (it removes some results that should be valid) it's not working at present, thanks.

    Read the article

  • UIDocumentInteractionController change title of presented view

    - by whatdoesitallmean
    I am using the UIDocumentInteractionController to display pdf files. My files are stored in the filesystem using encoded filenames that are not user-friendly. I do have access to a more friendly name for the file, but the file is not stored with this name (for uniqueness reasons). When I load the document into the UIDocumentInteractionController then the view displays the unfriendly 'real' filename in the titlebar. Is there any way to change the displayed title as presented by the UIDocumentInteractionController? Thanks.

    Read the article

< Previous Page | 1 2 3 4 5 6 7 8 9 10 11 12  | Next Page >