Background color of the cell in EXCEL not working....Pls help..

Hi gurus,
I have written a procedure to change the background color of the cell in EXCEL.The code is as below..
PROCEDURE set_header     (p_row IN NUMBER, p_col IN NUMBER, p_value IN VARCHAR2, p_border IN VARCHAR2 DEFAULT 'N',p_bgcolor IN VARCHAR2 DEFAULT 'N') IS
BEGIN
     v_args     := ole2.create_arglist;
     ole2.add_arg(v_args, p_row);
     ole2.add_arg(v_args, p_col);
     v_cell     := ole2.get_obj_property(v_worksheet, 'cells', v_args);
     v_font     := ole2.get_obj_property(v_cell, 'font');
     ole2.set_property(v_font, 'fontstyle', 'bold');
     ole2.set_property(v_font, 'size', 9);
     ole2.destroy_arglist(v_args);
     if p_border = 'Y' THEN
          v_border := ole2.get_obj_property(v_cell, 'Borders');
          ole2.set_property(v_border, 'LineStyle', 1);
          ole2.release_obj(v_border);
     End If;
     if p_bgcolor ='Y' THEN
          v_bgcolor := ole2.get_obj_property(v_cell,'Bgcolor'); --This is not woking
          ole2.set_property(v_bgcolor,'bgcolor','red');
          ole2.release_obj(v_bgcolor);
     End If;
          ole2.set_property(v_cell, 'value', p_value);
          ole2.release_obj(v_cell);
     END set_header;
Pls tell me how to change the backcolor and forecolor in the cell...
Thanks

The background color is set for the "Interior" object of the selected cells (Range).
Try something like this (haven't tested it):
v_interior := ole2.get_obj_property(v_cell,'Interior');
ole2.set_property(v_interior,'ColorIndex',3); --should be red
ole2.release_obj(v_interior);
If the Foreground color = Font Color then
ole2.set_property(v_font,'ColorIndex',6); --should be yellow
Gerald

Similar Messages

  • HT201412 my iphone 4s does not start by power switch, it starts when i connect to pc. the proximity sensor is not working. please help

    my iphone 4s does not start by power switch, it starts when i connect to pc. the proximity sensor is not working. please help.

    Sounds like it may be a hardware issue.
    Please contact Apple Support in your country.
    Here is a list of numbers: http://support.apple.com/kb/HE57
    Regards
    J

  • Why my apps are not transferring from PC to iPhone 5? When I connected to PC the icon shows when I select apps it show 'will install' but it never show on iPhone, I re installed iTunes, deleted all apps and downloaded again but its not working pls help.

    Why my apps are not transferring from PC to iPhone 5? When I connected to PC the icon shows when I select apps it show 'will install' but it never show on iPhone, I re installed iTunes, deleted all apps and downloaded again but its not working pls help.

    Next time an app update gets stuck try a reset. Press and hold both the home and power buttons for10-15 seconds till the Apple logo appears. Then release both buttons. Wait till your iPad starts on it's own. Try now. Also YouTube is still available. If you can't find it the the app store go to the bottom of the app store page and tap purchased. All your deleted apps will be listed and you can reinstall YouTube from there.

  • HT4972 i cant update my iphone 3gs to a more newer ios? it says here error! and the phone flashes some connect to itunes.. an if i connct nothing happens.. help me.. the ipgone wont open . and work pls help me thank you!

    i cant update my iphone 3gs to a more newer ios? it says here error! and the phone flashes some connect to itunes.. an if i connct nothing happens.. help me.. the ipgone wont open . and work pls help me thank you!

    Hello AlexCornejo,
    Thanks for using Apple Support Communities.
    The screen you're seeing on your iPhone indicates it is in recovery mode.  Now since the device is not appearing in iTunes on your PC, first follow the steps in this article:
    iOS: Device not recognized in iTunes for Windows
    http://support.apple.com/kb/TS1538
    After following those steps, you should be able to restore your iPhone.
    Take care,
    Alex H.

  • I have deployed one application containing youtube video but it is not working pls help

    I have deployed one application containing youtube video but it is not working pls help Application is build using struts2 and is deployed in oracle cloud, login page works fine but the success page is not displayed please help

    Hello,
    A wild guess, given the lack of details:
    I wonder whether it would violate the http://en.wikipedia.org/wiki/Same-origin_policy ?
    This is part of the security infrastructure.
    "Stealing" content to insert it anywhere else might also violate copyrights?
    Technically, does it at least work "on premises" onto WLS 10.3.6?
    Regards
    Patrick.

  • CALL Transaction in background not working pls help URGENT

    hi i have writtin a bdc program which uses CALL TRSANCTION everything is working in foreground.
    if i schedule the program in background the call transaction does not work. any idea why?????????
    pls help its urgent

    hi
    good
    have you checked in the debug mode, if you have checked in the debug mode check wheather it is giving any error before data is displaying in the screen, if any error is displaying as a message than check that error why it is coming there.
    If no error is coming than check your flow of the bdc screen in the debug mode , there must be some prob, so that it is not working in the background.
    thanks
    mrutyun^

  • I sign in tol my Firefox is out of date. did try to do the upgrade but did not work need help

    ''locking this thread as duplicate, please continue at [https://support.mozilla.org/en-US/questions/978554 /questions/978554]''
    I need help to get my sign in working. Need to upgrade?
    how to do that?
    <sub>edit: removed personal information for your protection. (philipp)</sub>

    I sign in told my Firefox is out of date. did try to do the upgrade but did not work. Need help
    Let me know how to get my sign in working

  • My ipad has a black screen and the power button is not working. Help!

    This is the second time my ipad screen has gone black. The power button is not working. I reset the ipad about two weeks ago  when this happened. However, this time I am not able to get itunes to recognize the device. It keeps asking to respond from the ipad (obviously with a black screen that isn't going to happen). Im not sure what to try next...thoughts?

    Have you tried to give it a reset?
    Reset
    Hold down the sleep and home keys for about 20 seconds. When you see the silver apple, let go and let it reboot. No data will be lost.

  • Jasper Export to excel: changing background color of the cell/field

    Hi all,
    I have designed a report containing a set of 5 different fields. All these are STRING values.
    Among these are two fields named: BUDGETED and ACTUAL.
    I want to show the data corresponding to ACTUAL in red color if the value of ACTUAL is greater than BUDGETED when exported in excel format.
    The value itself should be displayed in red color or the excel cell should have a color red
    Can someone please help me in this? How can we implement the logic to compare these two values?
    Thanks in advance.

    You are using Jasper and you thought: hey, let me post a question in the Oracle Reports forum?

  • The given link is not working sap help(best Practice documets)

    Hi Experts,
    http://help.sap.com/bpcrmv250/CRM_DE/BBLibrary/html/BBlibrary.htm_
    Please see the above link,
    Earliet  the link consists of documents for CRM 7.0 confrigration.
    But now the link is not working at all.
    PLease provide a link if it is there (which consists for the same documents such as CRM 7.0)
    Thanks in advance
    Prajith P

    HI,
    You can refer the correct link given below:
    http://help.sap.com/bp_crmv12007/CRM_DE/BBLibrary/html/BBlibrary.htm
    Regards,
    PP

  • Lenovo G580 the key "{/[" in the keyboard is not working.Pls help.

    Hi,
    I recently bought this laptop less than a month ago.  few day earlier this paranthesis key is not working any more.  Laptop keyboard is without any dust or blemish. I am running ubuntu and when I checked there is no press/release event being registered, using XEV package. I also ran the system with live cd same issue. Tried removing the key and cleaning the interior, nothing helps. 
    Is this a problem with some connection in the keyboard?  I cannot think of any software issues since It was working fine couple days ago? 
    Help would be greatly appreciated since I am in the middle of writing my dessertation.

    Hi
    Welcome To Lenovo Community
    We are really sorry to hear about the issue you are facing,  
    Based on what I read from the post, it seems to be a hardware issue with the keyboard
    Please contact Local Lenovo support to have system verified
    http://support.lenovo.com/en_IN/feedback/detail.page?LegacyDocID=MIGR-76613
    Do give this a try and let us know  
    Hope This Helps
    Cheers!!!
    WW Social Media
    Important Note: If you need help, post your question in the forum, and include your system type, model number and OS. Do not post your serial number.
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"!
    Follow @LenovoForums on Twitter!
    How to send a private message? --> Check out this article.
                            English Community   Deutsche Community   Comunidad en Español

  • CreateJavaVM not working pls help

    Hello folks,
    I am trying to get a simple windows console application to lauch the jvm
    but the call to JNI_CreateJavaVM keeps failing (returns -1). I have tried
    just about everything (with the paths, client dll, server dll,
    paths etc.) but nothing seems to work. I have checked the groups did not
    find anything that works for me. Please suggest something, even if you don't
    see the problem.
    I know that the program does find the jvm.dll, because if i reome it from
    the path, the programs complains about not finding the dll (i use the one
    from the client directory)
    Here is the code (it fails on the call to JNI_CreateJavaVM):
    (the call to launching the java class is commented out since i was not get
    past the problem of creating the jvm)
    This is my code
    #include <stdio.h>
    #include <jni.h>
    JNIEnv* create_vm() {
    JavaVM* jvm;
    JNIEnv* env;
    JavaVMInitArgs args;
    JavaVMOption options[1];
    int i;
    /* There is a new JNI_VERSION_1_4, but it doesn't add anything for the purpo
    ses of our example. */
    args.version = JNI_VERSION_1_4;
    // args.version = 0x30010024;
    args.nOptions = 1;
    options[0].optionString = "-Djava.class.path=c:\\users\\kabilesh\\javacheck\
    \jvm";
    args.options = options;
    args.ignoreUnrecognized = JNI_TRUE;
    printf("inside create vm\n");
    i = JNI_CreateJavaVM(&jvm, (void **)&env, &args);
    perror("error:");
    printf("after create vm : %d\n", i);
    switch(i) {
    case JNI_OK: printf("success");
    break;
    case JNI_ERR: printf("unknown error");
    break;
    case JNI_EDETACHED: printf("thread detached from the VM");
    break;
    case JNI_EVERSION: printf("JNI version error");;
    break;
    case JNI_ENOMEM: printf("not enough memory");
    break;
    case JNI_EEXIST: printf("VM already created");
    break;
    case JNI_EINVAL: printf("invalid arguments");
    break;
    return env;
    void invoke_class(JNIEnv* env) {
    jclass helloWorldClass;
    jmethodID mainMethod;
    jobjectArray applicationArgs;
    jstring applicationArg0;
    printf("inside invoke class\n");
    //helloWorldClass = (*env)->FindClass(env, "example/jni/InvocationHelloWorld
    helloWorldClass = (*env)->FindClass(env, "./InvocationHelloWorld");
    printf("before main method \n");
    mainMethod = (*env)->GetStaticMethodID(env, helloWorldClass, "main", "([Ljav
    a/lang/String;)V");
    printf("after main method \n");
    applicationArgs = (*env)->NewObjectArray(env, 1, (*env)->FindClass(env, "jav
    a/lang/String"), NULL);
    applicationArg0 = (*env)->NewStringUTF(env, "From-C-program");
    (*env)->SetObjectArrayElement(env, applicationArgs, 0, applicationArg0);
    (*env)->CallStaticVoidMethod(env, helloWorldClass, mainMethod, applicationAr
    gs);
    int main(int argc, char **argv) {
    JNIEnv* env = create_vm();
    printf("inside main\n");
    invoke_class( env );
    printf("after invoke class");
    os- windows xp
    C:/users/kabilesh/javacheck/c2javacheck> java -version
    java version "1.5.0"
    Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0-b64)
    Java HotSpot(TM) Client VM (build 1.5.0-b64, mixed mode, sharing)
    C:/users/kabilesh/javacheck/c2javacheck>
    C:/users/kabilesh/javacheck/c2javacheck> jview
    Microsoft (R) Command-line Loader for Java Version 5.00.3810
    Copyright (C) Microsoft Corp 1996-2000. All rights reserved.
    Usage: JView [options] <classname> [arguments]
    Options:
    /? displays usage text
    /cp <classpath> set class path
    /cp:p <path> prepend path to class path
    /cp:a <path> append path to class path
    /n <namespace> namespace in which to run
    /p pauses before terminating if an error occurs
    /v verify all classes
    /d:<name>=<value> define system property
    /a execute AppletViewer
    /vst print verbose stack traces (requires debug classes)
    /prof[:options] enable profiling (/prof:? for help)
    Classname:
    .CLASS file to be executed.
    Arguments:
    command-line arguments to be passed on to the class file
    C:/users/kabilesh/javacheck/c2javacheck>
    can you please let me know what should i do to make it run.
    thanks
    kabilesh

    Use formatting tags when you post code....
    http://forum.java.sun.com/features.jsp#Formatting
    And search this forum for examples that work....
    http://forum.java.sun.com/forum.jsp?forum=52

  • I have iphone 5. Have no sound and home button is not working pls help., I have iphone 5. Have no sound and home button is not working pls help.

    My iphone 5 has just stopped giving any sound no ringtones, no key clicking or button sounds nothing at all. And the home button has stopped working. Has anyone heard of software 6.1.4 being corrupt Im just updating software at the moment to 7.1. If anyone can offer a pieace of advise would be much appreciated.
    MANY THANKS
    JAY

    The iPhone warranty is not international and as you purchased in
    Malaysia the warranty is only valid in Malaysia
    You could try taking to an iPhone Authorised service provider
    in India but there have been many similar posts to yours
    and I am not aware  of them assisting  with an iPhone from
    outside India

  • I had to uninstall my photoshop elements 9 and now Im trying to reinstall and its not working pls help!

    I had to uninstall my photoshop elements as I deleted a texture and now I am trying to reinstall its just comes up saying that the wizard is saying that it was interrupted and its not installing pls help

    Reneeb41086198 without a specific error I would recommend reviewing Troubleshoot installation | Photoshop Elements, Premiere Elements | Windows which discusses common installation troubleshooting processes.
    You may also want to consider evaluating Photoshop Elements 13 from Picture editor, edit pictures | Adobe Photoshop Elements 13 as it was designed to install and function under Windows 8.1.  Windows 8.1 was not available when Photoshop Elements 9 was released.

  • Basic invisible button movie clip frame actions not working, pls. help!

    Hi,
    I've got a basic little slide show player which is timeline-based, rolling through 5 images with alpha transitions, and on the topmost layer, I have 5 invisible movie clips which have actions applied to them as follows:
    on (press) {
        gotoAndPlay(21);
    This action should allow for the on click button to navigate to that specific frame, or image, but for some reason it is not working.
    Did I do something wrong? I feel like I've done this before but I'm rusty with Flash since I don't use it all the time.
    Any help is greatly appreciated!
    Thanks,
    Sean

    The invisible movie clip is something I know I've done over the years on many occasions - I'm not sure I'm understanding your alternate technique, can you explain it better? The way my movie clips are invisible is just by setting the alpha to zero in the properties for the movie clip instance (clicking on the object on stage, then setting it in properties)..
    Also, the actions are on the invisible movie clips (buttons) and not the timeline.
    Cheers,Sean

Maybe you are looking for

  • SWF not working properly when sent to acrobat

    I am trying to place a simple swf file in a layout but Acrobat refuses to display it at the correct size. It shows me the correct dimensions in the import dialog, but then seems to ignore them. The final placed object comes in at 320x240 no matter wh

  • Ipod shuts down everyday using ITrip when driving

    I have an 80gb Ipod Video Classic I am using in my car with a Griffith Itrip so I can play my Ipod through my FM radio. This started happening a few weeks ago. About every 10 minutes or so when driving my Ipod will shut down saying I have to do a res

  • Sun cluster with netapps filers

    Has any one running sun cluster 3 with netapps filers. We would primary running oracle databases but would be running some apps servers as well. There does appear to be some issues in rgard to the fact that NFS file locking is not the same as on a st

  • Stock intransit

    Hi All, We have a inter PO where in GR is done after delivery from supplying plant. Now due to some reason GR is reversed and stock is in intransit since supplying plant has not reversed the delivery.Some one have removed stock from intransit (by doi

  • How to copy RKF and to change the techincal name ?

    How to copy RKF and to change the techincal name ?