Trying to create an equals method

So I need to create an equals method within a class that and object can call with a second object to test equivalence. I mean whether or not the object's instance variable are all the same. Here's the snippets of code:
public class Circle implements Shape
    double radius;
    Point position;
    Color color;
    boolean filled;
public boolean equals(Object o)
        if(!(o instanceof Point)) {
            return false;
        Point p = (Point) o;
        return ((radius == p.radius) && (position == p.position) && (color == p.color) && (filled == p.filled));
}Obviously there's other methods going on in between the instance variables, but the constructor only sets the instance variables, nothing more. So the first error I'm getting is "cannot find symbol - variable radius", but clearly, it's there. What am I doing wrong?
I may have other questions when I get frther in my project.

sublimeph03nix wrote:
public boolean equals(Object o)
if(!(o instanceof Point)) {
return false;
}Not actually always desirable, that. Yes, yes, yes, it prevents a ClassCastException, but on the downside, it prevents a ClassCastException. What do I mean? Well, in situations where you know that nothing other than a Point object should be passed into this method - that's your intended behaviour - the presence of anything else here indicates a bug. Better to let the bug bring the app down than for it to continue doing the wrong thing. Testing will expose the bug, as long as you don't just ignore it.
Of course, this isn't always the case. It's one of those things you should consider on a case-by-case basis, rather than apply one idiom or the other all the time

Similar Messages

  • Pizza equals method

    I am trying to create an equals method for a class that defines pizzas.
    I am having trouble getting it to work. I know that I have to use ==
    because getPrice() is a an int, but it is always coming up as false,
    regardless of whether it is or not.
    Here is the method:
    public boolean equals (Pizza pizza2 )
            if(this.getPrice() == pizza2.getPrice())
                 return true;
              else
              return false;
       }any ideas?

    note this code
    public class Pizza
         int price;
         public int getPrice(){
              return price;
         public void setPrice(int price){
              this.price = price;
         public boolean equals(Pizza pizza2){
              if (this.getPrice() == pizza2.getPrice()){
                   return true;
              else{
                   return false;
         public static void main(String[] args)
              Pizza p1 = new Pizza();
              p1.setPrice(10);
              Pizza p2 = new Pizza();
              p2.setPrice(10);
              System.out.println(p1.equals(p2) ); //true
              System.out.println(p1.equals( (Object)p2) ); //false
    }

  • Error while creating a overwrite method in class

    Hello.
    I'm trying to create an overwrite method in the class CL_HREIC_EECONTACT2SRCHV_IMPL but it just won't let me. Every time I try I get the message "The class has not yet been converted to the new class-local types" and I cannot create it.The thing is I've tried to create overwrite methods in diferent classes and sometimes I get the message and sometimes I don't, so it seems to depend on the class I'm trying to enhance, but I don't seem to be able to see any pattern in it.
    Any help?
    Thanks

    Hello i had the same problem and i couldn't create enhancement pre or post methods.
    The message was:
    The class has not yet been converted to the new class-local types
    Exception of class CX_ENH_OLD_LOCAL_CLASS_TYPES
    This can be fixed by entering in SE24 transaction: Change class. From menu choose: Utilities -> Convert class-local types.
    After that activate the class.
    Now the class can be enhanced.
    However this action requires change of the class
    Regards,
    Rosen

  • Creating a new method in an enhanced component class implemetation

    Hello Experts,
    I am trying to create a new method in the enhanced component(BT115IT_SLSO) implementation class ( ZL_BT115IT__ITEMS_IMPL)to run our custom functionality. But somehow when I put a breakpoint and debug while I add a product to the sales order the method doesnt get trigerred.
    Is there some thing which I have to do  get this trigerred ? I just added a ned method and placed some custom code in it. Do I have to invoke it anywhere ?
    Pls help me out. I am new to Web UI.
    Thanks

    Hi Mavrick,
    As you are performing some action like item addition , there you need a method called as " event handler " to handle the event and perform the required actions.
    Place a break point in DO_HANDLE_EVENT method , and you will know the exact event handler method which is getting triggered . or if you are defining a new event ( by adding any new button) you should create a event handler method using wizard giving the same name which is defined on_click field of the button as it is case sensitive.
    Regards,
    Nithish

  • When i am trying to create an itunes account in ipad 3 and in payment method i select none and after it when i select create ID. "Please contact ITunes Support to complete the transcation" this message will appear. kindly help me

    when i am trying to create an itunes account in ipad 3 and in payment method i select none and after it when i select create ID. "Please contact ITunes Support to complete the transcation" this message will appear. kindly help me

    You can contact iTunes support via this page (these are user-to-user forums) : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page

  • TS3297 the 'none' payment option is not displayed in the preferred payment method while trying to create an apple id?

    While trying to create a new apple ID, I do not see the option of 'NONE' payment.  Only the VISA and MASTERCARD options are displayed.  What is the reason?

    Welcome to the Apple Support Communities, Joseph
    http://support.apple.com/kb/ht2534

  • Error when trying to create new BP in MSA 5.0 SP08

    Hi,
    We have currently an issue in MSA 5.0 SP08 when we are trying to create a new BP. We receive the message "Relationship (Employee) - Error handler in function EvalsfakvbeztpfromReltyp reached". Looking into the code we find this error handler in the BOINTBPEMP :
    The error is triggered when the standard method CreateBusineesObject is invoked. Sfamitabt contains a guid but it's a string and as you can see, the method should wait an object. Not sure if it is the source of our problem:
    Public Overridable Function CreateBusinessObject(ByVal typeName As String, Optional ByVal parameterNames As Object = Nothing, Optional ByVal parameterValues As Object = Nothing) As SAP.MT.FW.BLL.BusinessObject
         Member of: SAP.MT.FW.BLL.BusinessFactory
    Some more investigation we did : the object Err.Number equal 0 (no internal error) and i was not able to put a break point into the class constructor for BOEMPLOYEE because it is a protected event (CreateBusinessObject("BOEMPLOYEE" should be link to the class contructor of BOEMPLOYEE when a new object is created)
    However, I can confirm that SFAMITABT contains a valid guid (i checked smomitabt) and i also tried during the debug session to change interactively the guid with an other valid one, but i still have this problem.
    I started the sql profiler but i saw nothing relevant in there.
    I modified the sensitivity for the debug in order to see if i will have more informations but without success and the MSIL (intermediate languaged) did not help me more.
    Please advise,
    Thanks
    Christophe

    Aren't customer task not used anymore?
    Or am I mixing things up here.
    Well the problem isn't a problem it is SAP standard behaviour you simply can't configure customer tasks (type T in PFTC)
    You can only configure Standard Tasks (TS) or workflow templates (WS)
    Kind regards, Rob Dielemans
    Edited by: Rob Dielemans on May 29, 2009 12:51 PM
    Just had a look at the SAP help and indeed types T aren't allowed anymore SAP gives the solution to copy the customer task, this will automatically change it to a standard task

  • My Equal method is not working in array person!!! help me pls

    My assignment is to create an application program that declares an array of 100 components of type person. add a person into the array and (CHECK DUPLICATE ENTRIES ARE NOT ALLOWED)
    my code is(this is in another class):
    public Boolean equals(Person p1){
              return(name == p1.name&&address == p1.address&&telephoneNo == p1.telephoneNo&&email == p1.email);
    Become(this is in my main class):
    public static boolean isEquals(Person p1)
              if(Person.getPersonCount()==1)
                   return false;
              for(int i=0;i<Person.getPersonCount()-1;i++)
                   if(p1.equals(p))
                        return true;
              return false;
    my output code is:
    public static void addPerson()
              String name, address, telephoneNo, email;
              int count=Person.getPersonCount();
              int numberPerson = Integer.parseInt(JOptionPane.showInputDialog(null,
                   "Enter number of person you want to add in (1 to 100):","Person Adding Table",
                   JOptionPane.QUESTION_MESSAGE));
              for(int i=0;i<numberPerson;i++)
                   name = JOptionPane.showInputDialog(null,"Please enter a person name:","Person No."+(i+1+count),JOptionPane.QUESTION_MESSAGE);
                   address = JOptionPane.showInputDialog(null,"Please enter a person address:","Person No."+(i+1+count),JOptionPane.QUESTION_MESSAGE);
                   telephoneNo = JOptionPane.showInputDialog(null,"Please enter a person telephone number:","Person No."+(i+1+count),JOptionPane.QUESTION_MESSAGE);
                   email = JOptionPane.showInputDialog(null,"Please enter a person email address:","Person No."+(i+1+count),JOptionPane.QUESTION_MESSAGE);
                   p[i+count]=new Person(name,address,telephoneNo,email);
                   if(isEquals(p[i+count]))
                        System.out.println("Please take note! Your person details have duplicate data...");
              System.out.println("You has added "+numberPerson+" details of person!!!");

    Don't compare Strings with ==. Use the equals() method.
    if (string1.equals(string2))Using == checks if they are the exact same object (think of it as the same location in memory). The equals() method checks if their contents are equal...just like you're trying to set up for your Person class. You want to see if the various fields of a Person object are the same...not if they are in fact the same object.

  • Trying to create a flash gallery

    trying to create a simple clickable slideshow.
    my problem i think is in the math. but i clickable picture buttons on right and left. the center clickable too.
    i wanna know how can i increment decrement a variable depending on direction.
    currently it seems to go in one direction which is to the right.
    also can i make an array of functions: ex- function animate[count](e:event):void
    or do functions handle arrays differently.
    sorry if i sound stupid but its been awhile doing flash.
    heres little code:
    var picture:Array = new Array();
    picture[1] = new pic1();
    addChild(picture[1]);
    picture[1].x =50;
    picture[1].y =384;
    picture[2] = new pic2();
    addChild(picture[2]);
    picture[2].x =512;
    picture[2].y =384;
    picture[2].scaleX =10;
    picture[2].scaleY =10;
    picture[3] = new pic3();
    addChild(picture[3]);
    picture[3].x =974;
    picture[3].y =384;
    var counter = 1;
        picture[1].addEventListener(MouseEvent.CLICK, animate1)
        function animate1(e:MouseEvent):void
            trace(counter);
            picture[counter+1].x =50;
            picture[counter+1].y =384;
            picture[counter + 2].x =512;
            picture[counter + 2].y =384;
            picture[counter + 2].scaleX =10;
            picture[counter + 2].scaleY =10;
            picture[counter + 3].x =974;
            picture[counter + 3].y =384;
            counter++;
    5 more similar eventlisteners and function

    Sorry I think I misread your code before when I responded. Well I think I have a working version of what you are trying to do. You can view what I made at http://www.jeremyseverson.com/as3/flash_gallery/index.html . I created this all in straight AS3 but it should give you an idea of what I did and give you some direction to achieve what you want.
    package
         import caurina.transitions.*;
         import flash.display.Bitmap;
         import flash.display.SimpleButton;
         import flash.display.Sprite;
         import flash.events.MouseEvent;
         [SWF(backgroundColor="#000000", frameRate="31", width="800", height="300")]
         public class Main2 extends Sprite
              //  EMBED ASSETS
              [Embed(source='assets/rightArrow.png')]
              private var rightArrowClass:Class;
              [Embed(source='assets/leftArrow.png')]
              private var leftArrowClass:Class;
              [Embed(source='assets/IMG_0001.JPG')]
              private var img0001Class:Class;
              [Embed(source='assets/IMG_0002.JPG')]
              private var img0002Class:Class;
              [Embed(source='assets/IMG_0003.JPG')]
              private var img0003Class:Class;
              [Embed(source='assets/IMG_0004.JPG')]
              private var img0004Class:Class;
              [Embed(source='assets/IMG_0005.JPG')]
              private var img0005Class:Class;
              [Embed(source='assets/IMG_0006.JPG')]
              private var img0006Class:Class;
              [Embed(source='assets/IMG_0007.JPG')]
              private var img0007Class:Class;
              //  PRIVATE VARIABLES
              // Layout Properties
              private var imgPad:Number = 5;
              private var imgScale:Number = 2.5;
              private var btnSize:Number = 25;
              private var imgCounter:Number = 0;
              private var middleImgX:Number = 400;
              private var leftImgX:Number = 100;
              private var rightImgX:Number = 700;
              private var leftImgTransX:Number = leftImgX - (middleImgX - leftImgX);
              private var rightImgTransX:Number = rightImgX + (rightImgX - middleImgX);
              private var imgY:Number = 150;
              private var imgLeft:Sprite;
              private var imgMid:Sprite;
              private var imgRight:Sprite;
              private var imgTransIn:Sprite;
              private var imgTransOut:Sprite;
              // Image Array
              private var classList:Array = new Array(img0001Class,img0002Class,img0003Class,img0004Class,img0005Class,img0006Class,img0007Class);
              private var spriteList:Array;
              private var currImages:Array;
              //  CONSTRUCTOR
              public function Main2()
                   init();
              //  PRIVATE METHODS
              private function init():void
                   initSpriteList();              
                   updateInterface(imgCounter);
               * Creating an array of sprites so that my registration point
               * will be in the center of the image instead of the upper left
              private function initSpriteList():void
                   spriteList = new Array();
                   var tSprite:Sprite;
                   var tBmp:Bitmap;
                   for (var i:uint=0; i<classList.length; i++)
                        tBmp = new classList[i] as Bitmap;
                        tSprite = new Sprite;
                        tSprite.addChild(tBmp);
                        tBmp.x = (-tBmp.width / 2);
                        tBmp.y = (-tBmp.height / 2);
                        spriteList.push(tSprite);
              private function updateInterface(newPos:Number,direction:String=null):void
                   var maxPos:Number = spriteList.length - 1;
                   var minPos:Number = 0;
                   var midPos:Number;
                   var leftPos:Number;
                   var rightPos:Number;
                   var transInSprite:Sprite;
                   // Set center array position
                   midPos = newPos;
                   if (midPos > maxPos) midPos = minPos;
                   if (midPos < minPos) midPos = maxPos;
                   // Update Image Counter
                   imgCounter = midPos;
                   // Set left array position
                   leftPos = midPos - 1;
                   if (leftPos < minPos) leftPos = maxPos;
                   // Set right array position
                   rightPos = midPos + 1;
                   if (rightPos > maxPos) rightPos = minPos;
                   switch(direction)
                        case "L":
                             currImages[0].removeEventListener(MouseEvent.MOUSE_DOWN, moveRight);
                             currImages[2].removeEventListener(MouseEvent.MOUSE_DOWN, moveLeft);
                             // Add transition in img
                             transInSprite = spriteList[rightPos];
                             transInSprite.x = rightImgTransX;
                             transInSprite.y = imgY;
                             transInSprite.scaleX = transInSprite.scaleY = .05;
                             transInSprite.alpha = 0;
                             addChild(transInSprite);    
                             Tweener.addTween(transInSprite, {x:rightImgX, alpha:1, scaleX:1, scaleY:1, time:0.5});
                             Tweener.addTween(currImages[0], {x:leftImgTransX, scaleX:.5, scaleY:.5, alpha:0, time:0.5, onComplete:removeImage, onCompleteParams:[currImages[0]]});
                             Tweener.addTween(currImages[1], {x:leftImgX, scaleX:1, scaleY:1, alpha:1, time:0.5});
                             Tweener.addTween(currImages[2], {x:middleImgX, scaleX:imgScale, scaleY:imgScale, alpha:1, time:0.5});
                             break;
                        case "R":
                             currImages[0].removeEventListener(MouseEvent.MOUSE_DOWN, moveRight);
                             currImages[2].removeEventListener(MouseEvent.MOUSE_DOWN, moveLeft);
                             // Add transition in img
                             transInSprite = spriteList[leftPos];
                             transInSprite.x = leftImgTransX;
                             transInSprite.y = imgY;
                             transInSprite.scaleX = transInSprite.scaleY = .05;
                             transInSprite.alpha = 0;
                             addChild(transInSprite);    
                             Tweener.addTween(transInSprite, {x:leftImgX, alpha:1, scaleX:1, scaleY:1, time:0.5});
                             Tweener.addTween(currImages[2], {x:rightImgTransX, scaleX:.5, scaleY:.5, alpha:0, time:0.5, onComplete:removeImage, onCompleteParams:[currImages[2]]});
                             Tweener.addTween(currImages[1], {x:rightImgX, scaleX:1, scaleY:1, alpha:1, time:0.5});
                             Tweener.addTween(currImages[0], {x:middleImgX, scaleX:imgScale, scaleY:imgScale, alpha:1, time:0.5});
                             break;
                        default:
                             // Add left img
                             spriteList[leftPos].x = leftImgX;
                             spriteList[leftPos].y = imgY;
                             spriteList[leftPos].scaleX = spriteList[leftPos].scaleY = 1;
                             addChild(spriteList[leftPos]);                        
                             // Add middle img
                             imgMid = spriteList[midPos];
                             spriteList[midPos].x = middleImgX;
                             spriteList[midPos].y = imgY;
                             spriteList[midPos].scaleX = spriteList[midPos].scaleY = imgScale;
                             addChild(spriteList[midPos]);
                             // Add right img
                             spriteList[rightPos].x = rightImgX;
                             spriteList[rightPos].y = imgY;
                             spriteList[rightPos].scaleX = spriteList[rightPos].scaleY = 1;
                             addChild(spriteList[rightPos]);         
                   spriteList[leftPos].addEventListener(MouseEvent.MOUSE_DOWN, moveRight);
                   spriteList[rightPos].addEventListener(MouseEvent.MOUSE_DOWN, moveLeft);
                   currImages = [spriteList[leftPos], spriteList[midPos], spriteList[rightPos]];
              private function removeImage(spriteRef:Sprite):void
                   removeChild(spriteRef);
              //  EVENT HANDLERS
              private function moveRight(e:MouseEvent):void
                   imgCounter--;
                   updateInterface(imgCounter,"R");
              private function moveLeft(e:MouseEvent):void
                   imgCounter++;
                   updateInterface(imgCounter,"L");

  • On a tabbed panel, I am trying to create a form, but...

    On a tabbed panel I am trying to create a form, but I am having a couple of issues.
    The coding on my form is yellow - I can't figure out what is wrong. Also, I can't see the tab on the browser, only in live view. I haven't loaded it to my site as I haven't finished it yet. I don't want to go any further, until I solve the issues I have now. Any ideas?
    thanks,
    deb
            <form id="registrationForm" name="registrationform" method="post" action="">
              <fieldset>
                <legend>Contact Information</legend>
                <span id="sprytextfield1">
                  <label>Name <span class="inforequired">*</span><br />
                    <input type="text" name="name" id="name" />
                    <br />
                  </label>
                  <span class="textfieldRequiredMsg">value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield2">
                  <label for="businessname">(Business or Organization) Name<br />
                  </label>
                  <input type="text" name="businessname" id="businessname" />
                  <br />
                  <span class="textfieldRequiredMsg">value is required.</span></span> <span id="sprytextfield3">
                  <label for="address">Address <span class="inforequired">*</span><br />
                  </label>
                  <input type="text" name="address" id="address" />
                  <br />
                  <span class="textfieldRequiredMsg">value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield4">
                  <label for="email">City</label>
                  <span class="inforequired">*</span><br />
                  <input type="text" name="city id="city="city"" />
                  <br />
                  <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield5">
                  <label for="province">Province</label>
                  <span class="inforequired">*</span><br />
                  <input type="text" name="province" id="province" />
                  <br />
                  <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield6">
                  <label for="postalcode">Postal Code</label>
                  <span class="inforequired">*</span><br />
                  <input type="text" name="postalcode" id="postalcode" />
                  <br />
                  <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield7">
                  <label for="phone">Phone Number (including area code) <span class="inforequired">*</span><br />
                  </label>
                  <input type="text" name="phone" id="phone" />
                  <br />
                  <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield8">
                  <label for="fax">Fax Number</label>
    (including area code) <br />
    <input type="text" name="fax" id="fax" />
    <br />
    <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield9">
    <label for="email">Email Address <span class="inforequired">*</span><br />
    </label>
    <input type="text" name="email" id="email" />
    <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldInvalidFormatMsg">Invalid format.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="spryconfirm1">
    <label for="emailconfirm"><br />
      Re-enter Email Address <span class="inforequired">*</span><br />
    </label>
    <input type="text" name="emailconfirm" id="emailconfirm" />
    <span class="confirmRequiredMsg">A value is required.</span><span class="confirmInvalidMsg">The values don't match.</span></span>
    <p> My Interest in the Ability Axis Employment Expo is as a </p>
    <p><span id="spryradio1">
      <label>
        <input type="radio" name="RadioGroup1" value="business" id="RadioGroup1_0" />
        Business/Employer</label>
      <br />
      <label>
        <input type="radio" name="RadioGroup1" value="nonprofit" id="RadioGroup1_1" />
        Non-Profit/Service Organizatin</label>
      <br />
      <label>
        <input type="radio" name="RadioGroup1" value="jobseeker" id="RadioGroup1_2" />
        Job Seeker</label>
      <br />
      <label>
        <input type="radio" name="RadioGroup1" value="other)" id="RadioGroup1_3" />
        Other (please specify below)</label>
      <br />
      </span><br />
      <span id="sprytextarea1">
      <label for="contactcomments"> Comments or other information</label>
      <br />
      <textarea name="contactcomments" id="contactcomments" cols="45" rows="5"></textarea>
    </span> </p>
    </fieldset>
              <p></p>
              <fieldset>
                <legend>Booth Options</legend>
                <span id="spryselect1">
                  <label for="premierearlybird">Premiere (10 X 10)  until April 21 $375</label>
                  <span class="earlybirdpricing">Early Bird Pricing</span><br />
                  <select name="premierearlybird" id="premierearlybird">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">lease select an item.</span></span> <span id="spryselect2">
                  <label for="premierereg">Premiere (10 x 10) after April 21 $425</label>
                  <br />
                  <select name="premierereg" id="premierereg">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect3">
                  <label for="premierenpearlybird">Premiere Non-Profit (10 X 10) until April 21 $325 <span class="earlybirdpricing">Early Bird Pricing</span><br />
                  </label>
                  <select name="premierenpearlybird" id="premierenpearlybird">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect4">
                  <label for="premierenp">Premiere Non-Profit (10 X 10) after April 21 $375</label>
                  <br />
                  <select name="premierenp" id="premierenp">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect5">
                  <label for="standardregearlybird">Standard (8  X 10)  until April 21 $250 <span class="earlybirdpricing">Early Bird Pricing</span><br />
                  </label>
                  <select name="standardregearlybird" id="standardregearlybird">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect6">
                  <label for="standardreg">Standard (8 X 10)  after April 21 $300</label>
                  <br />
                  <select name="standardreg" id="standardreg">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect7">
                  <label for="standardnpearlybird">Standard Non-Profit (8 X 10)  until April 21 $200</label>
                  <span class="earlybirdpricing">Early Bird Pricing</span><br />
                  <select name="standardnpearlybird" id="standardnpearlybird">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect8">
                  <label for="standardnp">Standard Non-Profit (8 X 10) after April 21 $250<br />
                  </label>
                  <select name="standardnp" id="standardnp">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3 - please enter details in the comments box below</option>
                  </select>
                  <span class="selectRequiredMsg">Please select an item.</span></span>
    </fieldset>
              <br />
              <fieldset>
                <legend>Breakfast Tickets</legend>
                <span id="spryselect10">
                  <label for="breakfast1-5">Breakfast Tickets $40 each (up to 5 tickets)</label>
                  <br />
                  <select name="breakfast1-5" id="breakfast1-5">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="4">4</option>
                    <option value="5">5</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect11">
                  <label for="breakfast+5">Breakfast Tickets $35.00 each (more than 5 tickets)</label>
                  <br />
                  <select name="breakfast+5" id="breakfast+5">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="5">5</option>
                    <option value="6">6</option>
                    <option value="7">7</option>
                    <option value="8">8</option>
                    <option value="9">9</option>
                    <option value="10">10</option>
                    <option value="10+">more than 10 (please comment below)</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="spryselect12">
                  <label for="breakfasttable">Breakfast Tickets $400 each (table of 8 plus two event hosts)<br />
                  </label>
                  <select name="breakfasttable" id="breakfasttable">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="3+">More than 3</option>
                  </select>
                  <br />
                  <br />
                  <span class="selectRequiredMsg">Please select an item.</span></span> <span id="sprytextarea2">
                  <label for="breakfastticketscomment">Additional Information about Breakfast Tickets</label>
                  <span class="textareaRequiredMsg">A value is required.</span></span>
    </fieldset>
              <br />
              <fieldset>
                <legend>Seminar Tickets</legend>
                <p>Shayn Anderson, author of Taking Pride in That Which Sets US Apart, will host a one hour seminar at 11:00 am. </p>
                <p>
                  <label for="shayn11amreg">Shayn Anderson Seminar tickets $40 each</label>
                  <br />
                  <select name="shayn11amreg" id="shayn11amreg">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="4">4</option>
                    <option value="5">5</option>
                    <option value="6">6</option>
                    <option value="7">7</option>
                    <option value="8">8</option>
                    <option value="9">9</option>
                    <option value="10">10</option>
                    <option value="10+">more than 10</option>
                  </select>
                  <span class="selectRequiredMsg">Please select an item.</span></p>
                <p>
                  <label for="shayn11amnp">Shayn Anderson Seminar tickets (Non-Profit) $30 each</label>
                  <br />
                  <select name="shayn11amnp" id="shayn11amnp">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="4">4</option>
                    <option value="5">5</option>
                    <option value="6">6</option>
                    <option value="7">7</option>
                    <option value="8">8</option>
                    <option value="9">9</option>
                    <option value="10">10</option>
                    <option value="10+">more than 10</option>
                  </select>
                  <span class="selectRequiredMsg">Please select an item.</span></p>
                <p>Denise Bissonnette will do a seminar presentation at 1:00 pm on the topic Being True to the Dream of Diversity. Denise's presentation will run approximately 1.5 hours. </p>
                <p>
                  <label for="denise1pmreg">Denise Bissonnette Seminar tickets $50</label>
                  each <br />
                  <select name="denise1pmreg" id="denise1pmreg">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="4">4</option>
                    <option value="5">5</option>
                    <option value="6">6</option>
                    <option value="7">7</option>
                    <option value="8">8</option>
                    <option value="9">9</option>
                    <option value="10">10</option>
                    <option value="10+">more than 10</option>
                  </select>
                  <span class="selectRequiredMsg">Please select an item.</span></p>
                <p>
                  <label for="denise1pmnp">Denise Bissonnette Seminar tickets (Non-Profit) $40 each<br />
                  </label>
                  <select name="denise1pmnp" id="denise1pmnp">
                    <option value="0" selected="selected">Please Choose</option>
                    <option value="1">1</option>
                    <option value="2">2</option>
                    <option value="3">3</option>
                    <option value="4">4</option>
                    <option value="5">5</option>
                    <option value="6">6</option>
                    <option value="7">7</option>
                    <option value="8">8</option>
                    <option value="9">9</option>
                    <option value="10">10</option>
                    <option value="10+">more than 10</option>
                  </select>
                  <span class="selectRequiredMsg">Please select an item.</span></p>
                <p><span id="sprytextarea3">
                  <label for="seminarcomments">Other Information About Seminar Tickets</label>
                  <textarea name="seminarcomments" id="seminarcomments" cols="45" rows="5"></textarea>
                </span></p>
    </fieldset>
              <br />
              <fieldset>
                <legend>Processing Information</legend>
                <span id="spryradio2">
                  <label>
                    <input type="radio" name="RadioGroup2" value="invoice" id="RadioGroup2_0" />
                    Please invoice me</label>
                  <br />
                  <label>
                    <input type="radio" name="RadioGroup2" value="printmail" id="RadioGroup2_1" />
                    I will print and mail my form with my payment</label>
                  <br />
                  <label>
                    <input type="radio" name="RadioGroup2" value="emailcreditcard" id="RadioGroup2_2" />
                    I will submit my information and provide my credit card information</label>
                  in the box below <br />
      <label>
        <input type="radio" name="RadioGroup2" value="other" id="RadioGroup2_3" />
        Other - I will provide full details below<br />
      </label>
                </span><span id="sprytextarea4"><span id="sprytextarea5">
                <label for="processingcomments"><br />
                  Further Information for Processing Registration</label>
                <textarea name="textarea1" id="textarea1" cols="45" rows="5"></textarea>
                <span class="textareaRequiredMsg">A value is required.</span></span></span> <span id="sprytextarea6"> <span class="textareaRequiredMsg">A value is required.</span></span>
    </fieldset>
              <p>
                <input name="submit" type="submit" class="buttons" id="submit" value="Submit Information" />
                <input name="reset" type="reset" class="buttons" id="reset" value="Reset Form" />
              </p>
            </form>

    Gramps, you are always coming to my rescue.
    Okay, I loaded the page under a different name http://abilityaxis.com/test.html. Viewing the source code doesn't show the yellow.
    For demonstration purposes I copied a small amount of the text and changed the colour of what is yellow in Dreamweaver to this pinkish colour (I tried yellow but you couldn't read it)
              <form id="registrationForm" name="registrationForm1" method="post" action="">
                <fieldset>
                  <legend>Contact Information</legend>
                  <span id="sprytextfield1">
                    <label>Name <span class="inforequired">*</span><br />
                      <input type="text" name="name" id="name" />
                      <br />
                   </label>
                    <span class="textfieldRequiredMsg">value is required.</span><span class="textfieldMinCharsMsg">Minimum number of characters not met.</span><span class="textfieldMaxCharsMsg">Exceeded maximum number of characters.</span></span> <span id="sprytextfield2">
                     <label for="businessname">(Business or Organization) Name<br />
                      </label>
                      <input type="text" name="businessname" id="businessname" />
    It basically goes all the way through the form.
    Any advice?
    thanks,
    deb

  • Trying to create a form

    Newbie here. I am trying to create a form and have the information emailed to me. When I hit the submit button, it opens my outlook email. I have searched online and looked @ videos and am sure I have everything correct. What am I not doing? Thanks in advance.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <link rel="shortcut icon" href="commonmedia/favicon" />
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <meta http-equiv="Content-Language" content="en" />
    <meta name="description" content="Experience a call to joy! We encourage you to visit us and experience the difference Christ has made in our lives. " />
    <meta name="keywords" content="Missionary Baptist Church, African-American, Houston, Texas, Third Ward, Lilly Grove, Jesus, Christian, love, Salvation, God" />
    <title>Lilly Grove Missionary Baptist Church | Houston, Texas &gt; Vacation Bible School Registration</title>
    <script type="text/javascript"  src="popmenu.js"></script>
    <link rel="stylesheet" type="text/css" media="screen, print, projection"  href="prayer.css"></link>
    <style type="text/css">
    #apDiv1 {
              position:absolute;
              width:503px;
              height:188px;
              z-index:1;
              left: 845px;
              top: 313px;
    #apDiv2 {
              position:absolute;
              width:799px;
              height:1094px;
              z-index:2;
              left: 1px;
              top: 280px;
              font-family: "Trajan Pro";
              font-weight: bold;
              font-style: italic;
    #apDiv3 {
              position:absolute;
              width:811px;
              height:196px;
              z-index:3;
              left: 50px;
              top: 1206px;
    #apDiv4 {
              position:absolute;
              width:660px;
              height:268px;
              z-index:3;
              left: 799px;
              top: 515px;
              text-align: center;
    </style>
    </head>
    <body>
    <div  id="prayer">
      <div id="welcomeb"><a  href="index.php"  title="Welcome"></a></div>
      <div id="historyb"><a  href="history.php"  title="History"></a></div>
      <div id="leadershipb"><a  href="leadership.php"  title="Leadership"></a></div>
      <div id="ministriesb"><a  href="ministries.php"  title="Ministries"></a></div>
      <div id="eventsb"><a  href="events.php"  onclick="target='_blank';"  title="Events"></a></div>
      <div id="mediab"><a  href="http://www.streamingfaith.com/Lilly-Grove-Missionary-Baptist-Church/"  title="Media"></a></div>
      <div id="sermonsb"><a  href="sermons.php"  title="Sermons"></a></div>
      <div id="giveb"><a  href="give.php"  title="Give"></a></div>
      <div id="contactb"><a  href="contact.php"  title="Contact"></a></div>
      <div id="lillygroveb"><a  title="Lilly Grove"></a></div>
      <div id="visitusthissundayb"><a  title="Visit us this Sunday"></a></div>
      <div id="followuson"></div>
      <div id="facebookb"><a  href="http://tinyurl.com/lssyba"  onclick="target='_blank';"  title="Facebook"></a></div>
      <!--<div id="id110frame"></div>-->
      <div id="vbsbanner"></div>
      <!--<div id="prayerrequesttitle"></div>-->
      <div id="contactuspopup" class="PMcontactusb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="memberbereavementpopup" class="PMmemberbereavementb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="ministrymembershippopup" class="PMministrymembershipb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <!--<div id="id84prayerrequest"></div>-->
      <!--<div id="id85prayerrequest"></div>-->
      <div id="getdirectionspopup" class="PMgetdirectionsb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="churchdirectorypopup" class="PMchurchdirectoryb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="privacypolicypopup" class="PMprivacypolicyb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="sitemappopup" class="PMsitemapb" onmouseout="P2H_StartClock();" onmouseover="P2H_MenuItem(1);"></div>
      <div id="getinformedtitle"></div>
      <div id="getinvolvedtitle"></div>
      <div id="getconnectedtitle"></div>
      <div id="getinformedtext" onmouseout="P2H_StartClock();" onmouseover="P2H_Menu('PMgetinformedtext', 0, 0);">
        <p><a href="http://tinyurl.com/kjsg5r"  onclick="target='_blank';">News &amp;
          Updates</a></p>
        <p><a href="media.php"  onclick="target='_blank';">Watch Broadcast</a></p>
    <p><a href="covenant.php">Read Covenant</a></p>
        <p><a href="facilities.php">Rent Facility</a></p>
        <p><a href="privacy.php">Read Privacy Policy</a></p>
        <p><a href="http://tinyurl.com/m7mdsy"  onclick="target='_blank';">Email Webmaster</a></p>
      </div>
      <div id="getinvolvedtext" onmouseout="P2H_StartClock();" onmouseover="P2H_Menu('PMgetinvolvedtext', 0, 0);">
        <p><a href="pastor.php">Meet the Pastor</a></p>
        <p><a href="http://tinyurl.com/oat5p6"  onclick="target='_blank';">Send Email</a></p>
    <p><a href="give.php">Tithe or Donate Online</a></p>
        <p><a href="http://www.lillygrove.org/webmail.php"  onclick="target='_blank';">Check
        Webmail</a></p>
    <p><a href="http://tinyurl.com/ovy2fq"  onclick="target='_blank';">Member
          Access</a></p>
        <p><a href="contact.php">Contact Us</a></p>
      </div>
      <div id="shadow"></div>
      <div id="id29frame"></div>
      <div id="box"></div>
      <div id="i50thanniversity"></div>
      <div id="verticalresponseliteral">
        <form method="post" action="http://oi.vresp.com?fid=b1bab280e8" >
          <div style="font-family: verdana; font-size: 11px; width: 160px; padding: 10px; border: 1px solid #803124; background: #803124">
            <strong><span style="color: #ffffff;">Sign Up Today!</span></strong><br/>
            <br/>
            <label style="color: #ffffff;">Email Address:</label>
            <br/>
            <input name="email_address" size="15" style="margin-top: 5px; border: 1px solid #999; padding: 3px;"/>
            <br/>
            <input type="submit" value="Join Now" style="margin-top: 5px; border: 1px solid #999; padding: 3px;"/>
            <br/>
            <br/>
            <span style="color: #ffffff;"><a href="http://www.verticalresponse.com" title="Email Marketing by VerticalResponse">Email
            Marketing</a> by VerticalResponse</span> </div>
        </form>
      </div>
      <div id="footerelement"></div>
      <div id="nbcab"><a  href="http://tinyurl.com/kulzaw"  onclick="target='_blank';"  title="NBCA"></a></div>
      <div id="copyrighttext" onmouseout="P2H_StartClock();" onmouseover="P2H_Menu('PMcopyrighttext', 0, 0);">
        <p>&copy; 2011 Lilly Grove Missionary Baptist Church. All rights reserved.</p>
        <p><a href="http://tinyurl.com/nwjnx2"  onclick="target='_blank';">CSS Valid</a>
          | <a href="http://tinyurl.com/ncuxt5"  onclick="target='_blank';">XHTML
          Valid</a> | <a href="http://tinyurl.com/yw6p9r"  onclick="target='_blank';">Creative
          Commons License</a> | Design by <a href="http://www.quantumidentitygroup.com"  onclick="target='_blank';" style="text-decoration:underline;">Quantum
          Identity Group</a></p>
      </div>
      <div id="operab"><a  href="http://www.opera.com/"  onclick="target='_blank';"  title="Opera"></a></div>
      <div id="proudmemberofthe">
        <p>Proud member of the</p>
      </div>
      <div id="bestviewed">
        <p>Website best viewed in</p>
      </div>
    </div>
    <div id="apDiv1"><img src="img/media.jpg" alt="" width="476" height="178" /></div>
    <div id="apDiv2">
      <table width="794" height="422" border="3">
        <tr>
          <td width="780"><form action="mailto:[email protected]" method="get" enctype="text/plain" id="form12">
              <p> </p>
              <p> </p>
              <p>Name (Last, First)
                <label for="textfield"></label>
                <input type="text" name="textfield" id="textfield" />
              </p>
              <p>Address (Street, City, St., Zip)
                <label for="textfield2"></label>
                <input type="text" name="textfield2" id="textfield2" />
              </p>
              <p>Telephone Number
                <label for="textfield3"></label>
                <input type="text" name="textfield3" id="textfield3" />
              </p>
              <p>Email Address
                <label for="textfield4"></label>
                <input type="text" name="textfield4" id="textfield4" />
              </p>
              <p>Shipping Address If Different From Above
                <label for="textfield5"></label>
                <input type="text" name="textfield5" id="textfield5" />
              </p>
              <p>Time Preference
                <input type="radio" name="radio" id="radio" value="radio" />
                7:30 a.m
                <input type="radio" name="radio2" id="radio2" value="radio2" />
                11:00 a.m
                <label for="radio3"></label>
                <input type="radio" name="radio3" id="radio3" value="radio3" />
                6:30 p.m
                <label for="radio4"></label>
                <input type="radio" name="radio4" id="radio4" value="radio4" />
                7:00
              (midweek)</p>
              <p>Media Preference
                <label for="radio5"></label>
                <input type="radio" name="radio5" id="radio5" value="radio5" />
                cd
                <label for="radio6"></label>
                <input type="radio" name="radio6" id="radio6" value="radio6" />
              dvd</p>
              <p>Sermon Preference
                <label for="radio7"></label>
                <input type="radio" name="radio7" id="radio7" value="radio7" />
                consecutive
                <label for="radio8"></label>
                <input type="radio" name="radio8" id="radio8" value="radio8" />
              Pastor Anderson only
              <label for="radio9"></label>
              <input type="radio" name="radio9" id="radio9" value="radio9" />
              Special Services
              </p>
              <p>Series Start Date
                <label for="textfield6"></label>
                <input type="text" name="textfield6" id="textfield6" />
              </p>
              <p>Payment Information</p>
              <p>Credit Card Type
                <label for="radio10"></label>
                <input type="radio" name="radio10" id="radio10" value="radio10" />
                Visa
                <label for="radio11"></label>
                <input type="radio" name="radio11" id="radio11" value="radio11" />
                MasterCard
              </p>
              <p>Name On Credit Card
                <label for="textfield7"></label>
                <input type="text" name="textfield7" id="textfield7" />
              </p>
              <p>Credit Card #
                <label for="textfield8"></label>
                <input type="text" name="textfield8" id="textfield8" />
              </p>
              <p>Exp. Date
                <label for="textfield9"></label>
                <input type="text" name="textfield9" id="textfield9" />
              </p>
              <p>CSV #
                <label for="textfield10"></label>
                <input type="text" name="textfield10" id="textfield10" />
              </p>
              <p>Amount
                <label for="textfield11"></label>
                <input type="text" name="textfield11" id="textfield11" />
              </p>
              <p>Banking Information</p>
              <p>Name On Check
                <label for="textfield12"></label>
                <input type="text" name="textfield12" id="textfield12" />
              </p>
              <p>Check #
                <label for="textfield13"></label>
                <input type="text" name="textfield13" id="textfield13" />
              </p>
              <p>Account #
                <label for="textfield16"></label>
                <input type="text" name="textfield16" id="textfield16" />
              </p>
              <p>Routing #
                <label for="textfield14"></label>
                <input type="text" name="textfield14" id="textfield14" />
              </p>
              <p>Amount
                <label for="textfield15"></label>
                <input type="text" name="textfield15" id="textfield15" />
              </p>
              <p>
                <input type="submit" name="Submit" id="Submit" value="Submit" />
              </p>
              <p> </p>
          </form></td>
        </tr>
      </table>
      </form>
    </div>
    <div id="apDiv4"> MAIL ORDERS ONLY - FEE DUE IN ADVANCE<br />
       PRICES $30 DVD'S $20 CD'S<br />
       ALL MONIES ARE DUE BY THE 15TH OF THE MONTH.<br />
       4 TO 5 SERMONS RECEIVED (based on number of Sundays in the month the order is placed)<br />
      SERMON TIME PREFERENCES SHOULD BE PROVIDED AT TIME OF ORDER.(i.e. . , if you choose 7:45 am, you receive 4 sermons for that time, only.)<br />
      SERMONS MAILED FROM CONSECUTIVE SUNDAYS, REGARDLESS OF SPEAKER.(unless specified at the time order is placed).<br />
    ORDERS WILL BE MAILED OUT WEEKLY.</div>
    </body>
    </html>

    If you want to sell CD's, DVD's or subscriptions to digital downloads, look at PayPal or Google Checkout. 
    As Gramps said, e-mail is NOT web secure for on-line credit card transactions.  You could be putting yourself and your customers at risk.  See PCI Compliance FAQs:
    http://www.pcicomplianceguide.org/pcifaqs.php
    Nancy O.
    Alt-Web Design & Publishing
    Web | Graphics | Print | Media  Specialists 
    http://alt-web.com/
    http://twitter.com/altweb

  • How to create the custom method and make it available to clients:

    Hello, Can any one help me with this problem ASAP??
    I am trying to work on an example of "Customizing the Query and Creating an Associated Custom Method"
    from http://helponline.oracle.com/jdeveloper/help/topics/jdeveloper/developing_mvc_applications/adf_pviewcustommethod.html?tp=true#method. To do that, the first task is to create the custom method and make it available to clients.
    Following instructions in the helponline documentation, I completed the three steps: (1) "Specify a custom query for the View Object definition for EmployeesView", (2) "Add the custom method to the application module Java class", and (3) "Make the method available to clients".
    The following is the error message I got to test the application module. Can anyone tell me what the message really means and what I should do. I am wondering if there is any mistakes in the document.
    (oracle.jbo.SQLStmtException) JBO-27122: SQL error during statement preparation. Statement: SELECT Employees.EMPLOYEE_ID, Employees.FIRST_NAME, Employees.LAST_NAME, Employees.EMAIL, Employees.PHONE_NUMBER, Employees.HIRE_DATE, Employees.JOB_ID, Employees.SALARY, Employees.COMMISSION_PCT, Employees.MANAGER_ID, Employees.DEPARTMENT_ID FROM EMPLOYEES Employees WHERE Employees.SALARY > :1 and Employees.DEPARTMENT_ID = :2
    ----- LEVEL 1: DETAIL 0 -----
    (java.sql.SQLException) ORA-01008: not all variables bound

    You need to set values for the parameters in your query before you try to execute the query in the view object.
    So you need to call the setBindVars method before the query.

  • Trying to create a service that starts at boot

    People,
    I'm trying to create a service that will start at boot (in single-user mode, actually). I am up and running but I do NOT want to run the service now. I only want to run the service when the machine reboots.
    I've been rummaging around all day trying to figure this out but I'm stuck. I can create a service that runs. I can create an XML file in /var/svc/manifest/site/patch-install.xml that will be read when I boot- because after I boot, I can list the service:
    svcs -a | grep patch
    disabled       18:23:23 svc:/site/patch-install:defaultI have inserted the following in my xml:
    <create_default_instance enabled='true' />and also
    <create_default_instance enabled='false' />but it makes no difference. Anyone have any idea? What is the purpose of create_default_instance? I don't understand; item 9 on http://www.sun.com/bigadmin/content/selfheal/sdev_intro.html seems rather opaque to me.
    Also, what exactly is the purpose of /var/svc/profile/ ? I tried putting some code to enable my xml but it didn't do anything. Just wondering if this might fit into the picture.
    BTW, I do not want the login prompt to appear until my method is complete.
    Thanks.
    -mschwage
    Here fyi is my /var/svc/manifest/site/patch-install.xml file:
    <?xml version="1.0"?>
    <!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
    <service_bundle type='manifest' name='Patches:patch-install'>
    <service
            name='site/patch-install'
            type='service'
            version='1'>
            <create_default_instance enabled='false' />
            <single_instance />
            <dependent
                    name='patch-install_single-user'
                    grouping='require_all'
                    restart_on='none'>
                    <service_fmri value='svc:/milestone/single-user' />
            </dependent>
            <exec_method
                    type='method'
                    name='start'
                    exec='/var/tmp/S92delay'
                    timeout_seconds='86400' />
            <exec_method
                    type='method'
                    name='stop'
                    exec=':true'
                    timeout_seconds='0' />
            <property_group name='startd' type='framework'>
                    <propval name='duration' type='astring' value='transient' />
            </property_group>
            <stability value='External' />
            <template>
                    <common_name>
                            <loctext xml:lang='C'>
                            Install patchset upon boot.
                            </loctext>
                    </common_name>
            </template>
    </service>
    </service_bundle>

    Hushpuppy wrote:
    People,
    I'm trying to create a service that will start at boot (in single-user mode, actually). I am up and running but I do NOT want to run the service now. I only want to run the service when the machine reboots.I'd probably create the service now (by importing the manifest manually rather than waiting for the reboot), then set general/enabled in the default instance to be be true with svcprop. That should tell it to start at boot, but not enable it immediately.
    I've been rummaging around all day trying to figure this out but I'm stuck. I can create a service that runs. I can create an XML file in /var/svc/manifest/site/patch-install.xml that will be read when I boot- because after I boot, I can list the service:Yes, that's the default. Or you can load it immediately to create the service now.
    # svccfg import patch-install.xml
    I have inserted the following in my xml:
    <create_default_instance enabled='true' />and also
    <create_default_instance enabled='false' />but it makes no difference. Anyone have any idea? What is the purpose of create_default_instance? I don't understand; item 9 on http://www.sun.com/bigadmin/content/selfheal/sdev_intro.html seems rather opaque to me.There's a difference between a "service" like network/smtp or console-login and an "instance" like network/smtp:sendmail or console-login:default. In most cases, you just want a single "default" instance of your service. The above line sets the default instance 'enabled' property to true or false. When I import your manifest as is, the service comes in as 'disabled'. If I set it to true, it comes in as 'maintenance' (almost certainly because it was enabled, tried to start, and couldn't find the start method on my machine).
    Also, what exactly is the purpose of /var/svc/profile/ ? I tried putting some code to enable my xml but it didn't do anything. Just wondering if this might fit into the picture.'profiles' are loaded exactly once, and they are mainly used to set certain services to enabled or disabled.
    3 of them are loaded if present, platform.xml, generic.xml, and site.xml. The last is not generated by the OS, but left for you to use. But it's usually only useful as a "first boot" type thing. Because if you make changes to it, it will not be reread. This isn't usually a problem because after first boot you're in control of the services. The usual thing is that at first boot the manifests load to create services, then the profiles are loaded to set then enabled or disabled. This isn't possible before that point because there's no service to modify yet.
    BTW, I do not want the login prompt to appear until my method is complete.Any login prompt like a network login, or only the console login prompt? If the latter, then you'll want a dependency so that system-console-login depends on your service. But if your service has a problem at boot time, you'd make it difficult to log in.
    Darren

  • Application hangs while trying to create a socket

    Hello,
    We have a third party application that makes HTTP connections using a old version of HTTPClient. Recently we have run into problems where the application hangs as one thread seems to hang while trying to create a socket (thread dumps show the hang occurs in native code) and other threads end up waiting for this thread as they need to obtain a lock on HTTPClient.HTTPConnection. We found out that HTTPClient was not setting a timeout on the underlying socket (SO_TIMEOUT) and the relevant patch has been implemented in the hope that if the condition arises again the offending thread will be timed out and allow other threads to try and continue.
    We will not be able to see if the patch works until Monday and I would like to understand the problem a little better if it fails. My question at what point will the socket timeout starting ticking? As our offending thread is waiting in native code is there a chance that the timeout will not be "active".
    Also can anyone provide reasons for an application hanging while trying to create a socket and any suggestions for monitoring or mitigating this problem?
    Thanks a lot.
    Sun Solaris 5.8
    JDK 1.4.1 b02

    It looks like our version of the JDK offer a connect method with a timeout value, I think this will do the trick.

  • I am trying to create an apple ID for a child but I can't find where to change my shared payment info on my iPad

    I have an iPad Air IOS 8.1.2 and I am trying to create an apple ID for a child but I am unable to find how to change the "shared payment method" when I go into my account settings it does have my Credit card but in settings under iCloud > family > shared payment method it still have my debit card. How/where can I update this card to mt credit card instead of my debit card?

    Hi azbaby2000,
    If you need to change the payment method associated with your Apple ID, use the steps in this article -
    Change or remove your payment information from your iTunes Store account (Apple ID) - Apple Support
    Thanks for using Apple Support Communities.
    Best,
    Brett L 

Maybe you are looking for