Search Results

Search found 2390 results on 96 pages for 'morten green hermansen'.

Page 44/96 | < Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >

  • Conditional Formating in Excel

    - by littlevahn
    HI, Im very new to Excel and VBA and was wondering I there is a way I could make conditional formatting on drop down Lists. I currently have a warning if the user enters something that is not valid (data validation) but I want to change the cell's background color to red if invalid or green if valid. Again there only options are in a List box. Any help would be awesome. Thanks

    Read the article

  • Blending pixels from Two Bitmaps

    - by MarkPowell
    I'm beating my head against a wall here, and I'm fairly certain I'm doing something stupid, so time to make my stupidity public. I'm trying to take two images, blend them together into a third image using standard blending algorithms (Hardlight, softlight, overlay, multiply, etc). Because Android does not have such blend properties build in, I've gone down the path of taking each pixel and combine them using an algorithm. However, the results are garbage. Any help would be appreciated. Below is the code, which I've tried to strip out all the "junk", but some may have made it through. I'll clean it up if something isn't clear. Bitmap src = BitmapFactory.decodeResource(getResources(), R.drawable.base, options); Bitmap mutableBitmap = src.copy(Bitmap.Config.RGB_565, true); int imageId = getResources().getIdentifier("drawable/" + filter, null, getPackageName()); Bitmap filterBitmap = BitmapFactory.decodeResource(getResources(), imageId, options); float scaleWidth = ((float) mutableBitmap.getWidth()) / filterBitmap.getWidth(); float scaleHeight = ((float) mutableBitmap.getHeight()) / filterBitmap.getHeight(); IntBuffer buffSrc = IntBuffer.allocate(src.getWidth() * src.getHeight()); mutableBitmap.copyPixelsToBuffer(buffSrc); buffSrc.rewind(); IntBuffer buffFilter = IntBuffer.allocate(resizedFilterBitmap.getWidth() * resizedFilterBitmap.getHeight()); resizedFilterBitmap.copyPixelsToBuffer(buffFilter); buffFilter.rewind(); IntBuffer buffOut = IntBuffer.allocate(src.getWidth() * src.getHeight()); buffOut.rewind(); while (buffOut.position() < buffOut.limit()) { int filterInt = buffFilter.get(); int srcInt = buffSrc.get(); int alphaValueFilter = Color.alpha(filterInt); int redValueFilter = Color.red(filterInt); int greenValueFilter = Color.green(filterInt); int blueValueFilter = Color.blue(filterInt); int alphaValueSrc = Color.alpha(srcInt); int redValueSrc = Color.red(srcInt); int greenValueSrc = Color.green(srcInt); int blueValueSrc = Color.blue(srcInt); int alphaValueFinal = convert(alphaValueFilter, alphaValueSrc); int redValueFinal = convert(redValueFilter, redValueSrc); int greenValueFinal = convert(greenValueFilter, greenValueSrc); int blueValueFinal = convert(blueValueFilter, blueValueSrc); int pixel = Color.argb(alphaValueFinal, redValueFinal, greenValueFinal, blueValueFinal); buffOut.put(pixel); } buffOut.rewind(); mutableBitmap.copyPixelsFromBuffer(buffOut); BitmapDrawable drawable = new BitmapDrawable(getResources(), mutableBitmap); imageView.setImageDrawable(drawable); } int convert (int in1, int in2) { //simple multiply for example return in1 * in2 / 255; }

    Read the article

  • Show Color on WrkStat.aspx Page

    - by eru
    On the WrkStat.aspx page I would like to add emphasis to the status of each approval stage. e.g. I want to show "Approved" in green and "Rejected" text in red. I tried editing the page in SharePoint Designer but it gives an error about application.master. Does anyone know how to add color to this wrkstat.aspx page or any custom workflow status page?

    Read the article

  • jQuery multiple selectors into dynamic attribute

    - by Jason Fletcher
    I am trying to attach an event to a separate onhover trigger. But I am having problems using multiple selectors since its dynamic. Need help ::: Upon hovering on the yellow box named 'Rings', this should trigger the animated slide event for the green box above it. http://home.jasonfletcher.info/all/alliteration/index.html $('.boxgrid1').hover(function(){ $(".cover", this).stop().animate({top:'0px'},{queue:false,duration:300}); }, function() { $(".cover", this).stop().animate({top:'247px'},{queue:false,duration:300}); });

    Read the article

  • How to correctly highlight cursor line in VIM?

    - by Eye of Hell
    Hello. VIM can be configured to highlight current line via :hi cursorline guibg=green and set cursorline commands. But if I enable tabs display via: :hi specialkey guifg=grey guibg=grey :set listchars="tab" :set list Cursor line highlight will corrupt tabs display: Any hints how i can avoid corruption so may tabs are highlighted with one color and cursor line is highlighted with another color without any ^I displayed at intersection?

    Read the article

  • Reset selection of wx.lib.calendar.Calendar control?

    - by Joseph
    I have a wx.lib.calendar.Calendar control (not wx.lib.calendar.CalendarCtrl!). I am selecting a number of days using the following function call: self.cal.AddSelect([days], 'green', 'white') This works, and draws the days highlighted. However, I cannot work out how to reverse this (i.e., clear the selection so the days go back to their normal colouring). Any hints, please?

    Read the article

  • what is the best and easiest to draw a multi bar chart in php

    - by gin
    i want to display the results of students scores in a multi-vertical bar chart (red bar for correct , green bar for false) for each question,, i already tried Google chart, but it gives me result in this way:link text note: the bars that reached the top , should not be at top ,, only because they have the highest value (75%), Google chart makes it at top which i don't want.. any suggestions about how to draw simple vertical bar chart with php

    Read the article

  • Detecting Markers Using OpenCV

    - by Hamza Yerlikaya
    I am trying to detect various objects containing colored markers, so a red blue green marker identifies object A, and a red blue red marker identifies object B. My problem is I can't use template matching cause objects can be rotated, currently I am thinking about check for each color then find the object by checking the distance between colors but it seems inefficient, so my question is there a better way to do this?

    Read the article

  • converting rgb values to System.Drawing

    - by Chris
    Hi, I've looked around, but don't see this question - maybe its too easy, but I don't have it. If I have file containing color values like: 255, 65535, 65280 ( I think this is green) is there a way to either: convert these to a System.Drawing.Color type or....better yet.. have .NET accept them as is to represent the color? thanks,

    Read the article

  • jquery run function in infinite loop

    - by zac
    I am creating a background color animation with jQuery and the color animation plugin http://plugins.jquery.com/project/color How do I have a function stay in a loop repeating itself each time it has finished running? I tried this but it did not work : $(document).ready(function(){ function colorLoop(){ $("#window") .animate({ backgroundColor: "orange" }, 11000) .animate({ backgroundColor: "yellow" }, 1000) .animate({ backgroundColor: "green" }, 1000) .animate({ backgroundColor: "blue" }, 1000) .animate({ backgroundColor: "indigo" }, 1000) .animate({ backgroundColor: "violet" }, 1000) .animate({ backgroundColor: "red" }, 1000, colorLoop); }; });

    Read the article

  • iphone mapview current location

    - by satyam
    I'm able to show current location on mapview. It shows round blue color circle. When I click on the circle, it shows "Current Location". I want to show users current location as green pin. on click of pin, i want to show "My Location" annotation. How to do it. Please suggest me how to do it.

    Read the article

  • Changing RGB color image to Grayscale image using Objective C

    - by user567167
    I was developing a application that changes color image to gray image. However, some how the picture comes out wrong. I dont know what is wrong with the code. maybe the parameter that i put in is wrong please help. UIImage *c = [UIImage imageNamed:@"downRed.png"]; CGImageRef cRef = CGImageRetain(c.CGImage); NSData* pixelData = (NSData*) CGDataProviderCopyData(CGImageGetDataProvider(cRef)); size_t w = CGImageGetWidth(cRef); size_t h = CGImageGetHeight(cRef); unsigned char* pixelBytes = (unsigned char *)[pixelData bytes]; unsigned char* greyPixelData = (unsigned char*) malloc(w*h); for (int y = 0; y < h; y++) { for(int x = 0; x < w; x++){ int iter = 4*(w*y+x); int red = pixe lBytes[iter]; int green = pixelBytes[iter+1]; int blue = pixelBytes[iter+2]; greyPixelData[w*y+x] = (unsigned char)(red*0.3 + green*0.59+ blue*0.11); int value = greyPixelData[w*y+x]; } } CFDataRef imgData = CFDataCreate(NULL, greyPixelData, w*h); CGDataProviderRef imgDataProvider = CGDataProviderCreateWithCFData(imgData); size_t width = CGImageGetWidth(cRef); size_t height = CGImageGetHeight(cRef); size_t bitsPerComponent = 8; size_t bitsPerPixel = 8; size_t bytesPerRow = CGImageGetWidth(cRef); CGColorSpaceRef colorSpace = CGColorSpaceCreateDeviceGray(); CGBitmapInfo info = kCGImageAlphaNone; CGFloat *decode = NULL; BOOL shouldInteroplate = NO; CGColorRenderingIntent intent = kCGRenderingIntentDefault; CGDataProviderRelease(imgDataProvider); CGImageRef throughCGImage = CGImageCreate(width, height, bitsPerComponent, bitsPerPixel, bytesPerRow, colorSpace, info, imgDataProvider, decode, shouldInteroplate, intent); UIImage* newImage = [UIImage imageWithCGImage:throughCGImage]; CGImageRelease(throughCGImage); newImageView.image = newImage;

    Read the article

  • Questions on using enums as parameters and if/else conditions

    - by dotnetdev
    Hi, Is it possible to do the following with an enum in C#?: Pass in to a method a selected value of the enum (eg if an enum has members such as Red, Green, Orange, I can pass in Colors.Red). In the method body of the above method which accepts an enum, I can say if (Enum == Colors.Red). What would be the syntax for this? I've always seemed to have stalled on this.

    Read the article

  • iTunes style layout using CSS

    - by Liam
    What is the best way (using HTML/CSS) to create an iTunes-style layout with the following features: a left column with a fixed width but fluid height (scrollbars for overflow) (BLUE below) a main content column with fluid width and height (scrollbars for overflow) (RED below) a bottom right box with fixed width and height which remains stuck to the bottom of the browser? (GREEN below) Here is an example: I'm happy to use Javascript/JQuery if there really isn't a pure CSS solution. Thanks!

    Read the article

  • Code Coverage Analysis for Embedded C++ projects

    - by Steve Hawkins
    I have recently started working on a very large C++ project that, after completing 90% of the implementation, has determined that they need to demonstrate 100% branch coverage during testing. The project is hosted on an embedded platform (Green Hills Integrity). I'm looking for suggestions and experiences from others on StackOverflow that have used code coverage products in similar environments. I'm interested in both positive and negative comments regarding these types of tools.

    Read the article

  • How to set background color of a View

    - by Peter vdL
    I'm trying to set the background color of a View (in this case a Button). I use this code: // set the background to green v.setBackgroundColor(0x0000FF00 ); v.invalidate(); It causes the Button to disappear from the screen. What am I doing wrong, and what is the correct way to change the background color on any View? Thanks.

    Read the article

  • Hide/Show some HTML table cells individually and align the remaining cells as they belong to the same row [closed]

    - by Brian
    [Edited at the resquest of admins] The best way I can explain my problem is showning an example. I have the table that you can see on the link below (since I can't post images...), that ha a table head (blue) and four rows, whose cells are green and white in color. I just want the white cells to hide/show alternately by clicking on green cells, which would remain always visible as parent cells. After hiding white cells, the green ones should be aligned into the same row, as they would fit like tetris bricks. That's all, I think more clear is impossible. http://i.stack.imgur.com/3n3In.jpg (follow the link to see the image explanation) The table code: <table class="columns" cellspacing="0" border="0"> <tr> <td class="left" rowspan="2"> <div style="text-align:center;"></div> </td> </tr><tr><td class="middle"> <div id="detail_table_source" style="display:none"></div> <br> <table id="detail_table" class="detail"> <colgroup> <col style="width:20px;"> <col style="width:40px;"> <col style="width:70px;"> <col style="width:20px;"> </colgroup> <thead> <tr> <th width="88">Blahhh</th> <th width="211">BLAHH</th> <th width="229">BLAHH</th> </tr> </thead> <tbody> <tr class="parent" id="row123" style="cursor: pointer; " title="Click to expand/collapse"> <td bgcolor="#A6A4CC">Blahhh</td> <td bgcolor="#A6A4CC">blah blah </td> <td bgcolor="#A6A4CC">Blahh</td> </tr> <tr class="child-row123" style="display: none; "> <td rowspan="3" bgcolor="#5B5B5B">&nbsp;</td> <td>blah blah </td> <td>blah blah</td> </tr> <tr class="child-row123" style="display: none; "> <td>blah blah</td> <td>blah blah</td> </tr> <tr class="child-row123" style="display: none; "> <td>blah blah</td> <td>blah blah</td> </tr> <tr> <td bgcolor="#6B7A94" class="parent" id="row456" style="cursor: pointer; " title="Click to expand/collapse"><strong>Blahh</strong></td> <td bgcolor="#FFFFFF" class="child-cell456" style="display: none; ">blah blah</td> <td bgcolor="#FFFFFF" class="child-cell456" style="display: none; ">blah blah</td> </tr> <tr> <td rowspan="4" valign="top" bgcolor="#5B5B5B" class="child-row456" style="display: none; ">&nbsp;</td> <td bgcolor="#6B7A94" class="parent" id="cell456" style="cursor: pointer; " title="Click to expand/collapse">blah blah</td> <td bgcolor="#6B7A94" class="parent" id="cell456" style="cursor: pointer; " title="Click to expand/collapse">blah blah</td> </tr> <tr> <td class="child-cell456" style="display: none; ">blah blah</td> <td class="child-cell456" style="display: none; ">blah blah</td> </tr> <tr> <td class="child-cell456" style="display: none; ">blah blah</td> <td class="child-cell456" style="display: none; ">blah blah</td> </tr> </tbody> </table> The script to hide/show whole rows (this works because it is copied from another example): <script language="javascript"> $(function() { $('tr.parent') .css("cursor","pointer") .attr("title","Click to expand/collapse") .click(function(){ $(this).siblings('.child-'+this.id).toggle(); }); $('tr[@class^=child-]').hide().children('td'); }); </script> And the failed attempt at expanding/hiding individual cells: <script language="javascript"> $(function() { $('td.parent') .css("cursor","pointer") .attr("title","Click to expand/collapse") .click(function(){ $(this).siblings('.child-'+this.id).toggle(); }); $('td[@class^=child-]').hide().children('td'); }); </script>

    Read the article

  • UML enumeration as a return type

    - by Ryan Fernandes
    << enumeration>> E1 | .RED .GREEN .BLUE | I have the above as an enumeration class in a UML diagram. I associate it with another class say House. I now need a method on House say +getColor() which returns a color from the above enumeration. How would I depict this in UML? would it be like : +getColor(): E1 ?

    Read the article

  • How to convert a string color to its hex code or RGB value?

    - by Abs
    Hello all, I am not sure if its possible but I would like to create some sort of function where you pass in a string such as "yellow" or "green" and it returns its hex code or the range of hex codes that greens or yellows fit into. Is this possible in PHP? If not possible, I am willing to try anything else that can do this! Thanks all

    Read the article

  • iPhone: custom cell is overlaping with each other

    - by Nandakishore
    hi i am working on Table view, my Table view first custom cell is over ride other cell when Scrolling this is my code import UIKit/UIKit.h @interface MyTweetViewController : UIViewController { IBOutlet UITableView *tweetsTableView; NSMutableArray *tweetArray; } @property (nonatomic, retain) IBOutlet UITableView *tweetsTableView; @end import "MyTweetViewController.h" @implementation MyTweetViewController @synthesize tweetsTableView; (void)viewDidLoad { tweetArray = [[NSMutableArray alloc] init]; [tweetsTableView setBackgroundColor:[UIColor clearColor]]; [super viewDidLoad]; } pragma mark - pragma mark Table view data source (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { // Return the number of sections. return 1; } (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { // Return the number of rows in the section. return [tweetArray count]; } (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath { return 80; } - (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath { [cell setBackgroundColor:[UIColor clearColor]]; } //Customize the appearance of table view cells. - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { static NSString *identifier = @"Cell"; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:identifier]; if(!cell) { cell = [[UITableViewCell alloc] initWithStyle:UITableViewStyleGrouped reuseIdentifier:identifier]; cell.selectionStyle = UITableViewCellSelectionStyleNone; } cell.accessoryType = UITableViewCellAccessoryNone; UILabel * name = [[UILabel alloc]initWithFrame:CGRectMake(72,3,242,15)]; name.text = (NSString*)[(Tweet*)[tweetArray objectAtIndex:indexPath.row] userName]; [name setFont:[UIFont fontWithName:@"Helvetica" size:14]]; name.textColor=[UIColor colorWithRed:250 green:250 blue:210 alpha:0.5]; [name setBackgroundColor:[UIColor clearColor]]; UILabel * tweetLabel = [[UILabel alloc]initWithFrame:CGRectMake(72,20,242,60)]; tweetLabel.text = (NSString*)[(Tweet*)[tweetArray objectAtIndex:indexPath.row] tweet]; tweetLabel.numberOfLines = 3; tweetLabel.textColor=[UIColor colorWithRed:252 green:148 blue:31 alpha:1]; [tweetLabel setFont:[UIFont fontWithName:@"Helvetica" size:12]]; [tweetLabel setBackgroundColor:[UIColor clearColor]]; NSLog(@" lblUserTweet : %@ ",name.text); UIImageView *myImage = [[UIImageView alloc]initWithFrame:CGRectMake(6,3,58,49)]; NSURL url = [NSURL URLWithString:[(Tweet)[tweetArray objectAtIndex:indexPath.row] image_url]]; NSData *data = [NSData dataWithContentsOfURL:url]; [myImage setImage: [UIImage imageWithData:data]]; [cell.contentView addSubview:myImage]; [cell.contentView addSubview:tweetLabel]; [cell.contentView addSubview:name]; return cell; } (void)dealloc { [tweetsTableView release]; [tweetArray release]; [super dealloc]; }

    Read the article

  • How do I compare current date with dates stored in MySQL db?

    - by Gabriele
    Hello, I'm coding a uploader that saves into the db the date when a file is uploaded using CURDATE(). I want to compare the current date with the one stored into the db in order to change the color of the icon related to the file depending on how long has this feel been uploaded. For instance, if less than a week, the icon will be green, if more than a week, it will be yellow, if more than two weeks, red. How can I do it? Thanks.

    Read the article

< Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >