Make the cursor at an item

Hi (Salam Alaykom),
I have a button "clear" , I want when the button is clicked the items will be cleared and the cursor is at the first item, here is the code:
:emp.id:=null;
:emp.ename:=null;
:emp.sal:=null;
go_item('emp.id');
*=>but the problem that the item changes color, but the cursor remains at the button "clear"*
NOTE:
I used the "when-new-item-instance" trigger to change the color of text items

979155 wrote:
Hi (Salam Alaykom),walikum as salam
I have a button "clear" , I want when the button is clicked the items will be cleared and the cursor is at the first item, here is the code:
:emp.id:=null;
:emp.ename:=null;
:emp.sal:=null;
go_item('emp.id');Not need of this, simply issue of
go_block('emp');
clear_block;
*=>but the problem that the item changes color, but the cursor remains at the button "clear"*does your button in the same block ? means button also in the emp block or any other block ? EMP block is tabular ??
Do you have when-new-record-instance trigger at emp block ? if yes what is the code ?
NOTE:
I used the "when-new-item-instance" trigger to change the color of text itemsHope you are using the trigger at Block level
What is your form design ? i mean how may block and layout style..?
Hamid
Edited by: HamidHelal on Jan 26, 2013 12:32 AM

Similar Messages

  • How to make the cursor global if it has parameters that would be passed through calling environment

    What I am trying to do is:
    1. Pass two dates "p_start_date" and "p_end_date" to a procedure "calc_percnt". Based on these two dates the procedure creates a collection that has ticket info between the date range provided.
    2. Iterate through this collection to find out the number of tickets that took less than 4 hrs (p_count_4), less than 8 hours (p_count_8), less than 12 hours(p_count_12) and less than 24 hours (24).
    3. I want to move the logic of the  above point 2 (also mentioned between dotted lines in the below mentioned code) to a function and call that function.
    4. For the above point 3 I will have to create a function which will accept a collection variable something like this:
    create or replace cal_perc (collection_var total_tckt_colcn) .... 
    I cannot do this because total_tckt_colcn needs to be declared
    5. I cannot make the cursor and collection type as global by putting them in package specification because of the condition in cursor:
    WHERE created_date >= p_start_date AND created_date < (p_end_date + interval '1' DAY)
    it gives the error as "p_start_date"  and "p_end_date" needs to be declared.
    What is the best way to do this????
    create or replace
    PROCEDURE calc_percnt(
      p_start_date IN N01.cc_ticket_info.LAST_CHANGED%type ,
      p_end_date   IN N01.cc_ticket_info.LAST_CHANGED%type ,
    AS
      v_start_date N01.cc_ticket_notes.LAST_UPDATED_STAMP%type;
      v_end_date N01.cc_ticket_notes.LAST_UPDATED_STAMP%type;
      CURSOR cur_total_tckt
      IS
      SELECT  * from
      WHERE created_date >= p_start_date AND created_date < (p_end_date + interval '1' DAY)
    type total_tckt_colcn
    IS
      TABLE OF cur_total_tckt%rowtype;
      total_tckt_col total_tckt_colcn;
      total_coach_col total_tckt_colcn;
    BEGIN
      total_tckt_col  := total_tckt_colcn ();
      OPEN cur_total_tckt;
      LOOP
      FETCH cur_total_tckt bulk collect INTO total_tckt_col limit 100;
    END LOOP;
      EXIT
      WHEN (cur_total_tckt%NOTFOUND);
      END LOOP ;
      CLOSE cur_total_tckt;
    -- ---I want to move the following code in a function which finds the time required to close the ticket and increment the counter ------
    FOR i IN total_tckt_col .first..total_tckt_col .last
      LOOP
      no_of_seconds       := calc_time_diff(total_coach_col(i).created_date, total_coach_col(i).closed_date);
      IF (no_of_seconds    < 14400) THEN
      p_count_4          := p_count_4  + 1;
      p_count_8          := p_count_8  + 1;
      p_count_12         := p_count_12 + 1;
      p_count_24         := p_count_24 + 1;
      ELSIF (no_of_seconds < 28800) THEN
      p_count_8          := p_count_8  + 1;
      p_count_12         := p_count_12 + 1;
      p_count_24         := p_count_24 + 1;
      ELSIF (no_of_seconds < 43200) THEN
      p_count_12         := p_count_12 + 1;
      p_count_24         := p_count_24 + 1;
      ELSIF (no_of_seconds < 86400) THEN
      p_count_24         := p_count_24 + 1;
      END IF;
      END LOOP;
    END calc_percnt;

    I cannot add cursor definition to package because  of the following condition:
    WHERE created_date >= p_start_date AND created_date < (p_end_date + interval '1' DAY)
    it gives me an error: "p_start_date"  and "p_end_date" needs to be declared.
    p_start_date and p_end_date are parameters that would be passed by the user.
    Parameterized cursor to the rescue:
    I have changed my cursor definition to:
    create or replace
    PACKAGE ES_REPORTS AS
    CURSOR cur_total_tckt (p_start_date n01.cc_ticket_status_history.created_date%type, p_end_date n01.cc_ticket_status_history.created_date%type)
      IS
      SELECT  t.ticket_id ticket_id , t.created_date created_date, t.created_by created_by, t.ticket_status ticket_status, t.last_changed last_changed, h.closed_date
      FROM n01.cc_ticket_info t
      inner join
      (SELECT  ticket_id , MAX(created_date) closed_date
      FROM n01.cc_ticket_status_history
      WHERE ticket_status = 'CLOSED' AND created_date >= p_start_date AND created_date < (p_end_date + interval '1' DAY)
      GROUP BY ticket_id
      ) h
      on (t.ticket_id         = h.ticket_id)
      WHERE (t. ticket_status = 'NOTIFIED' OR t.ticket_status = 'CLOSED') AND t.last_changed >= p_start_date AND t.last_changed < (p_end_date + interval '1' DAY);
    END ES_REPORTS;
    Not sure if it is good programing practice though?

  • Is there any way to make the cursor appear larger in Mac OS X?

    Wow, love my 27" screen, but have trouble finding the cursor! Is there any way to make the cursor appear larger? Perhaps adjustable for fine print capture?
    Thanks!

    System Preferences -> Universal Access -> Mouse -> Cursor size
    However, I prefer using Mouse Locator (free download)
    <http://www.versiontracker.com/dyn/moreinfo/macosx/26157>
    I like this Mouse Locator Graphic
    <http://homepage.mac.com/douglasn/locatorexchange/AD/1/MouseLocator.png>
    I also enjoy my 27" iMac. It is just so nice withing on it.
    Message was edited by: BobHarris

  • How to make the cursor disappear?

    In a graphic screen the cursor should not be visible. What can I do in order to make the cursor disappear? Can anyone help me? Thank you in advance.

    for a GUI
    Image image = Toolkit.getDefaultToolkit().createImage(new java.awt.image.MemoryImageSource(16, 16, pixels, 0, 16));
    Cursor transparentCursor = Toolkit.getDefaultToolkit().createCustomCursor(image, new Point(0, 0), "invisiblecursor");
    frame.setCursor(transparentCursor);

  • Why does my computer seem to JUMP when i put the cursor on an item i want to click?

    why does my computer screen seem to JUMP when i put the cursor on an item i want to click on?

    You should post that on the Boot Camp  forum, that is where all the Boot Camp and Windows guys hang out.
    Good luck.

  • How to make the spacing between menu items equal with varied menu item sizes

    If the title isn't clear, what I mean is how do you make the space between each of the items in a horizontal the same when some of the menu items are up to double the size of others. Currently I am using the margin property and the space between the larger items is smaller than between the smaller items.
    If you need more information just ask.

    Screenshots don't tell the whole story which is contained in your HTML and CSS code.
    Without a link to your test page or a look at your code (all of it) the best we can provide is wild guesses.
    Help us help YOU by providing a link.
    HOW IMPORTANT IS CODE? A Plea to new posters.
    http://forums.adobe.com/thread/691654?tstart=0
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists
    http://alt-web.com/
    http://twitter.com/altweb

  • How can I make the cursor more visible?

    I have seen in some training videos a ring around the cursor to make it more visible. How can I get this ring around my cursor in Photoshop CS 3?
    Anyone knows? /Tommy

    This should do it:
    1. Go to systems preference  and click it.  (it'll be under the top L hand side, click the apple logo and "System Preferences" will appear in a drop menu)
    2. Go to Show All
    3. Click Universal (round blue shape with a person logo)
    4. Click Mouse
    5. Go to Cursor size (at the bottom of the page)  and adjust the size from normal to large.  Watch your actual cursor on screen so you can see how big or small you're making it.
    voila:   a change of arrow or cursor size.

  • When opening a new tab, how can you make the cursor automatically go to the address bar?

    In my previous version of firefox, the cursor would go directly to the address bar when I opened a new tab. Thus, I could start typing the web address I wanted to go to immediately. However I upgraded to Firefox 4 today and I now have to manually click in the address bar. Is there any way to change this in settings or by installing a specific add-on?
    Thanks!

    You only get the cursor in the search bar if you open the built-in about:home page.<br />
    For other websites you need an extension.
    *Custom New Tab: https://addons.mozilla.org/firefox/addon/custom-new-tab/

  • I have a regular usb mouse and it isn't working. It sometimes clicks, but it can't make the cursor move. The red light will not turn on.

    I have been using a mouse with my MacBook Pro for a very very long time now:
    Optical USB Mouse:
      Product ID:    0xc016
      Vendor ID:    0x046d  (Logitech Inc.)
      Version:     3.40
      Speed:    Up to 1.5 Mb/sec
      Manufacturer:    Logitech
      Location ID:    0x06200000 / 3
      Current Available (mA):    500
      Current Required (mA):    100
    I'm running OS 10.6.8 on a MacBookPro that is fairly old.
    The mouse is detected on the USB port, either one, but the red light won't light anymore so I can't use it to move the cursor. I've tried rebooting, I've tried the cammand-option.P.R thing. Still no red light.
    Help?

    Mouse Gas?
    I took both of them to work and both worked fine in a different Mac laptop. I brought home two other mice and they both work here in my home computer. That works, but I wish I knew why the first two don't work at home because the logitec mouse I bought for home has very light action and the center wheel needs only a very light touch. I really really liked it and can't find one like it to replace it with.

  • How can you make the Chart "Color Highlights" Item Condition val a variable

    Hi,
    I have a report with a chart on it.
    The chart has on Item Condition on it to change the color of each bar to red if the value is under a certain value.
    This value needs to be passed in as a parameter to the report.
    The condition looks like this
    if  Avg PerformancePercent < 90 then bar color = red
    The 90 in this condition needs to be set from a parameter P_PerformancePercent_Threshold.
    I am producing the report in Visual Studio 2005 using CrystalReportViewer to display the report.
    Since the value field seems to only take in numeric values I have assumed there is no way to use a parameter something like.
    So I am looking at doing this through code.
    The object model for the ChartObject does not have many properties/methods on it.
    Is there any other way to achieve this?
    Thanks, George

    Functionality using the Crystal Reports SDK in Visual Studio .NET is limited to the appearance of the chart in the viewer such as height and width. See the following for more details;
    [ChartOject Members described|http://devlibrary.businessobjects.com/BusinessObjectsXIR2SP2/en/en/CrystalReports_dotNET_SDK/crsdk_net_doc/doc/crsdk_net_doc/html/crlrfCrystalDecisionsCrystalReportsEngineChartObject_MembersTopic.htm].
    [ChartObject Properties described|http://devlibrary.businessobjects.com/BusinessObjectsXIR2SP2/en/en/CrystalReports_dotNET_SDK/crsdk_net_doc/doc/crsdk_net_doc/html/crlrfCrystalDecisionsCrystalReportsEngineChartObject_PropertiesTopic.htm].
    99% of this time, if you can not do something at design time, you will not be able to do it at runtime either. See [this|http://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/oss_notes_boj/sdn_oss_boj_dev/sap(bD1lbiZjPTAwMQ==)/bc/bsp/spn/scn_bosap/notes.do] note.
    Ludek
    Follow us on Twitter http://twitter.com/SAPCRNetSup

  • When I move the cursor over sidebar items they toggle becoming underlined?

    When I move the cursor over sidebar bookmarks lines, it toggles underline on or off. Very annoying. Happens in Firefox 3.6, too.

    You can try to disable some layers and gfx preference settings on the about:config page to see if that helps.
    *http://kb.mozillazine.org/about%3Aconfig
    Filter: /gfx|layers/
    layers.accelerate-all
    layers.accelerate-none
    layers.acceleration.disabled
    Tools > Options > Advanced : General: Browsing: [ ] "Use hardware acceleration when available"

  • When hitting return/enter, how can I make the cursor go right instead of down?

    I would like to change where the cursor goes after I hit return/enter - for it to go to the right instead of down. In Excel I could change it in preferences but I cannot find that option in Numbers. Please help!

    Numbers 3 doesn't have that option. You might give feedback to Apple via your menu:  Numbers > Provide Numbers Feedback.
    SG

  • Mail - Typing ll makes the cursor hop backwards

    Whenever I type a word that ends in ll, for example I'll, We'll, You'll, in an email in Mail, the cursor hops backwards to in-between the 2 'l's when I press the space bar. Therefore when I have finished writing, there is only one 'l' at the end of the word and the other one is at the end of the email.
    I can't imagine that there is a preference for this.... it must be a bug...... Does anyone else experience this?
    Macbook Pro Retina 13"
    OS 10.10.2

    From the menu bar, select
              Edit ▹ Substitutions
    and uncheck all the options. Test. If the problem is resolved, you can experiment with re-enabling some of the options to further isolate the cause.

  • HT4759 How can I make the google chrome toolbar items open up in chrome rather than internet explorer?

    I downloaded the new icloud control pannel and when I click on the links in the start menu it always opens in internet explorer. Chrome is my default browser, and the bookmarks are synced with Chrome. Why is this opening in internet explorer and how do i change it? Thanks!

    My understanding of this is that its not currently possible
    I have read in other forums you needs to have Safari or IE to launch the apps, no other browser can be set as default.
    Hope for an update as I am

  • Can I change the cursor.

    Hi:
    Recently, on of our users asked if it would be possible to make the current context (current item where cursor is located) in the form easier to tell. Now, I believe I can accomplish this by writing probably a couple of triggers (possibly PRE-TEXT-ITEM/POST-TEXT-ITEM) at the form level and then use DISPLAY_ITEM to set the display attribute for the item.
    My question is: Is it possible to set some registry or Windows property to change the appearance of the cursor?
    If the answer is no, has anyone out there implemented the code needed to accomplish this and would you be willing to share it. We are still in Client/Server, no java yet.
    Thanks in advance,
    Thomas

    Torsten,
    I don't want to leave fields red when you leave them -- the color is supposed to change back to normal when user leaves the field. But I have a WVI trigger that re-validates, and if it is not valid, turns it back to red. If I have a pair or more fields that are edited together (in a WVR trigger), I allow user to leave the first field and go to the next in the pair, but if user leaves the record, validation tries again and the field turns red again. This method works quite well for our needs.
    I think there is a little bit of additional code necessary, like storing the old
    background for the current item somewhere...You DON'T need to store it. Setting the Displayitem NULL effectively returns the item back to its defined attributes.
    Kevin,
    I tried doing without the PTI, and using WNII only. BUT--that doesn't work in a multi-record scrolling block. You have to store the record of the item, and navigate back to the original record number, and if the record has scrolled out of view, you have to scroll the records to the prior view, then back to the current view. The PTI method requires one line of code, and the other requires dozens.

Maybe you are looking for