Bill to Address same as Ship to

I'm new to JavaScripting and I'm trying to create a PDF form that has a check box that when checked will auto fill information.  Specifically, when the user fills out the bill to address they can click the check box "same as billing" and it will populate the ship to address.  Any advice would be greatly appreciated.   
My data fields are as follows:
BTName
Billaddress1
Billaddress2
BillCity
BillState
BillZIP
SAMEAS (this is the check box)
STName
ShipAddress1
ShipAddress2
ShipCity
ShipState
ShipZIP
My JavaScript that I added to the check box is as follows:
// check the state of the button
if(this.getField('SAMEAS').value == '1') {
// checked
// copy requestor information
// get each requestor field object's value and set the sponsor field's value
this.getField('BTName').value = this.getField('STName').value;
this.getField('BillAddress1').value = this.getField('ShipAddress1').value;
this.getField('BillAddress2').value = this.getField('ShipAddress2').value;
this.getField('BillCity').value = this.getField('ShipCity').value;
this.getField('BillState').value = this.getField('ShipState').value;
this.getField('BillZIP').value = this.getField('ShipZip').value;

Sorry for not mentioning the problem...I was actually not getting anything to happen.  I do have the trigger to be mouse up, and run JavaScript.  Now with the updated script when I check the box it clears all the bill to address info and nothing appears in the shipping fields?  Thanks so much for the quick response.  
I just updated the script to the following:
// check the state of the button
if(event.target.value !== 'OFF') {
// checked
// copy requestor information
// get each requestor field object's value and set the sponsor field's value
this.getField('BTName').value = this.getField('STName').valueAsString;
this.getField('BillAddress1').value = this.getField('ShipAddress1').valueAsString;
this.getField('BillAddress2').value = this.getField('ShipAddress2').valueAsString;
this.getField('BillCity').value = this.getField('ShipCity').valueAsString;
this.getField('BillState').value = this.getField('ShipState').valueAsString;
this.getField('BillZIP').value = this.getField('ShipZip').valueAsString;

Similar Messages

  • Default Shipping Address same as Billing address

    Hi
    Is there any OOTB settings to the default shipping address same as Billing address info?
    Or do we need to use workflow to populate the these fields..
    Does Account record type has Billing and Shipping fields?. How do we configure address fields.?.
    VSR

    VSR, there are no OOTB settings to make shipping address default to billing address. However, you use workflow to accomplish this requirement.
    You can not configure fields in the address block (billing and shipping). The fields are determined by which country is selected.

  • Ship to and bill to address

    Hi experts
    I am newly installed sap bone 2005B version.I using OEC computers.I creadted one customer with ship to and bill to address. but in that address is not come in print lay out.
    I selected database and given Bill to address in respective area.
    what is the reason?
    pls tell me
    regards

    Hi
    1. yes
    2. system PLD also
    3. yes i changed my PLD but it will not come
    Now i understood the correct one, the customer bill to address not come in the invoice logistics part.
    I create the customer this also not come in the Logistics bill to address part as well as ship to address.
    what should i do?
    regards

  • Error: Ship to/Bill To Address is Invalid. Please review the Address Setup

    After Upgrading to 12.1.3, Orders are failing during Import/Scheduling with "Error: Ship to/Bill To Address is Invalid. Please review the Address Setup" whenever Tax Engine is called. And this is happening for only specific addresses (that are vaild). I will appreciate any experience/suggestion on this regard.
    Thanks,
    Dipanjan

    ---  Here's a skeleton structure of the PLSQL that you should use----
    l_location_rec          APPS.HZ_LOCATION_V2PUB.LOCATION_REC_TYPE;
    -----Use this to find a good address from existing TCA in Oracle, by passing only the zip code:
    SELECT hgi.identifier_value,hg.geography_element4_id
                       ,hg.geography_element1 country
                       ,hg.geography_element2 state
                       ,hg.geography_element3 county
                       ,hg.geography_element4 city
                       ,hg.geography_element5 postal_code
                 FROM apps.hz_geographies hg,apps.hz_geography_identifiers hgi
                WHERE hgi.geography_id  = hg.geography_element4_id
                  AND hg.geography_name = :pp_zip_code
                  AND hg.geography_type = 'POSTAL_CODE'
                  AND primary_flag='Y';
    -----The Update the Location
                 l_location_rec.CITY  := rec_get_geo_elements.city;
                 l_location_rec.COUNTY := rec_get_geo_elements.county;
                 l_location_rec.STATE := rec_get_geo_elements.state;
                   hz_location_v2pub.update_location (p_init_msg_list           => FND_API.G_TRUE,
                                           p_location_rec            => l_location_rec,
                                           p_object_version_number   => l_object_version_number,
                                           x_return_status           => l_return_status,
                                           x_msg_count               => l_msg_count,
                                           x_msg_data                => l_msg_data);

  • Commerical inovice output ship-to/bill-to address issue

    Hi Guru,
    We are having a issue about the address on the output of commercial inovice for STO delivery.
    e.g.
    Plant A - Delivering plant
    Plant B - Receiving plant
    1. Create a STO - B purchasing 100 piece of material_1 from A.
    2. Then create a Delivery with reference to this STO;
    3. Use the customize program to print the commercial invoice.
    The issue is that we have 2 customer id for plant B.
    100001 is using the company's sales office address, work as a bill-to party.
    200001 is using our distribution center address, work as a ship-to party.
    The output will display bill-to address and ship-to address. but currently we have a issue that this output use 100001 as the bill-to and ship-to address.
    We want to use 200001 as the ship-to address. From the code, the output will pick the ship-to party's address on the delivery as the ship-to address.
    Anyone can tell me how to fix this issue?
    thanks

    Hi All,
    Happy New Year,
    We use ME27 to create the STO, there is only delivery plant and receiving plant filled in during creation.
    After that we can use ME22N to change the STO. but I can't find the ship-to party field in the STO.
    Following is some pics about the shipping information of STO, Please advise,
    1. Delivery Address Tab - Item:   // This address is correct, shows 200001's address.
    <a href="http://tu.6.cn/pic/show/id/2041312">[img]http://i3.6.cn/cvbnm/60/ff/ee/415b90544504575d425174f94c440b17.jpg[/img]</a>
    2. Shipping Tab in Item Level:
    <a href="http://tu.6.cn/pic/show/id/2041314">[img]http://i3.6.cn/cvbnm/c7/e3/69/6204cca510480f9c2c3b9b57a39a3ce9.jpg[/img]</a>
    3. Partner Functions in Header Level - Partner Tab
    <a href="http://tu.6.cn/pic/show/id/2041313">[img]http://i3.6.cn/cvbnm/3b/02/14/326a8f450dd3f696b8a01a964702ef5d.jpg[/img]</a>
    The Question here is:
    1. The delivery address in STO is correct, whether it will be copied to Delivery I created with reference to STO?
    2.  We didn't find the ship-to party in the STO. So the ship-to party of Delivery is not coming from STO How to determine the ship-to party in Delivery?
    Thank you very much for your help.
    Edited by: Rick Guan on Jan 6, 2009 2:39 AM

  • Regarding Ship to and Bill to Address on iStore.....urgent

    Hi All,
    In Address of Ship to and Bill to , I need extra search based on Address1..
    I am looking into jsp page;ibeCCkdSrchListAddr.JSP
    please give me any suggestions or steps to implement this feature.
    Thanks in advance..
    Best Regards,
    HHH

    Hi
    1. yes
    2. system PLD also
    3. yes i changed my PLD but it will not come
    Now i understood the correct one, the customer bill to address not come in the invoice logistics part.
    I create the customer this also not come in the Logistics bill to address part as well as ship to address.
    what should i do?
    regards

  • Restricting SHIP TO and BILL TO address in VD02

    Hi
    Does anybody have idea on how we can restrict accessing certain user community to change Ship to and Bill To address in VD02. Any thoughts on this will be helpfull.
    Thanks
    KV

    Alex
    <b>Thanks for your input.</b>
    After creating a Field Grp in IMG how can associate the Field Grp to the <b>F_KNA1_AEN</b> auth object. I have create the field Group in SPRO (IMG) via Financial Accounting -> Accounts Payable and Accounts Receivable -> Customer Accounts -> Master Data -> Prepare Changes to Customer Master Data -> Define Field Groups for Customer Master Data.
    Please let me know your thougts on this if this is correct what im doing.
    Thanks
    KV

  • You cannot maintain the address (partner function 'Ship-to party' is empty)

    Dear Experts,
          I create one outbound delivery but when I click on address ( Symbol next to ship to party) it is showing below error.
    You cannot maintain the address (partner function 'Ship-to party' is empty)
    Message no. VPD017
    I also check customer master , address is maintain properly.
    in partner functions Sold-to party , Bill-to party , Payer , Ship-to party all are same. ( example: if bill to party is ABC then payer , ship to pary , bill to party all are ABC).
    Please help.
    Regards,
    Nirav Desai

    Hii Nirav Desai,
    You do correctly "configure automatic partner determination". The steps are as below -
    Customer Master
    Sales Document Header
    Sales Document Item
    Delivery Type
    Shipment Type
    Billing Header
    Billing item
    Sales Activities
    1.     How to define partner?
    A grouping of partner functions. The procedure specifies which partner functions are allowed for a particular business transaction (for example, for processing a sales order) and which of those partner functions are mandatory.
    Use
    You define partner determination procedures in SD Customizing through Functions -> Partner determinat.
    u2022     In sales documents, for example, you can specify the partner determination procedure according to sales document type and item category. During order entry, the system first proposes partners from the customer master record of the sold-to party. If this information does not exist in the customer master, the system automatically proposes the mandatory partners from the partner determination procedure that you specify in the document header.
    u2022     For billing documents, for example, you can specify a partner determination procedure where the sold-to party, bill-to party, and payer are mandatory but the ship-to party is not (for billing, you are more interested in who orders and pays for the goods than in who receives them).
    Thanks and Regards,
    Santanu

  • Bill To Address contents is not showing in invoice logistics tab

    Hi All,
    Bill To Address contents is not showing in invoice logistics tab though i have defined the Bill To Addresses for Business Partners.
    Same is happening with my Ship To addresses.
    Please Suggest.
    Regards.
    ShriX.

    I encountered the same issue, please do the following to make the Bill to address in the documents work.
    In the Administration ->  Setup -> Business Partners -> Countries
    Look for the Code where your business partners country are set.
    Then in the Address Format, choose your format. In my case I choose our company format. Hope this help.
    Regards,
    Cyrous

  • Clarification regarding Bill-to-address

    Hi ABAPers,
    I got one Ticket that Replacing of Bill-to-address in place of Customer Address.
    Now i want to know one thing, what is the difference between Bill-to-address and Invoicing address. i think Both are same. Then why they need both the same addresses to be printed on the form.
    Please any one clarify this one.
    Thanks & Regards,
    Ramana Prasad.

    Hi,
        At billing level there are sold to party and ship to party, so both are different .
    Regards,
    Prashant

  • Can we auto populate the bill to address in an SR from the bill to from AR

    We have two customers that have a relationship setup in AR. We the ship the parts to one customer and bill the second customer. When we create a service request, can we have the second customers address automatically populate into the bill to address. We have a party relationship setup so we can select the bill to address from the LOV, but the user doesn't always know which bill to address they should be selecting, so it would be nice if we could get the correct one to auto populate.

    There are three options to do this (ofcourse none are standard).
    Source can be item instance or customer master itself.
    1. Maintain the relationship in the item instance (serial number) if you are using customer products to create service requests. If you have that bill to in the csi_ip_accounts, and when the instance is used for the service request creation, you can default that in the service request using custom.pll or personlization. This should be easy.
    2. Or using the same approach, you can go HZ tables to get the bill_to of that ship_to.
    3. If you are using SR workflow, plugin one node which updates this in the SR.
    Thanks
    Nagamohan

  • Creating BusinessPartner with both mail to and bill to address

    Hi,
    I am having problem creating a business partner with both mail to and bill to address. I want to create two instances (lines) in BPAddresses; one with mial to address and another with bioll to address. But I still get the error code -5002 with the message "Address is empty [OCRD: CardCode} line:1"
    Below is my code in C#:
    SAPbobsCOM.BusinessPartners bp = (SAPbobsCOM.BusinessPartners) conn.InternalConnection.GetBusinessObject(SAPbobsCOM.BoObjectTypes.oBusinessPartners);
                   bp.CardName = "Test Tester";
                   bp.CardType = SAPbobsCOM.BoCardTypes.cCustomer;
                   bp.CardCode = "TEST29";
                   bp.Address = "1305 Blue Raven Blvd";
                   bp.City = "Citrus Height";
                   bp.Country = "US";
                   bp.BillToState = "CA";
                   bp.ContactPerson = "Peter Snicker";
                   bp.Currency = "USD";
                   bp.ZipCode ="94521";
                   string errMsg;
                   int errCode;
                   int returnval = bp.Add();               
                   if(0 != returnval){
                        conn.InternalConnection.GetLastError(out errCode, out errMsg);
                        Console.WriteLine(errMsg);
                        return;
                   string cardCode;
                   conn.InternalConnection.GetNewObjectCode(out cardCode);
                   //Console.WriteLine("Added BP successfully",cardCode);
                   bp.GetByKey(cardCode);
                   bp.Addresses.Add();
                   bp.Addresses.SetCurrentLine(1);
                   bp.Addresses.AddressType = SAPbobsCOM.BoAddressType.bo_ShipTo;
                   returnval = bp.Update();
                   if(0 != returnval){
                        conn.InternalConnection.GetLastError(out errCode, out errMsg);
                        Console.WriteLine(errMsg);
                        return;
    I would appreciate if anyone can help me with this problem.
    Thank you in advance,
    Sunny

    Hi Sunny,
    The reason for your error is that you're trying to add a blank ship to address.
    bp.Addresses.AddressType = SAPbobsCOM.BoAddressType.bo_ShipTo;
    returnval = bp.Update();
    you are just specifying a type and then trying to update. If you want to add another line, you have to set some properties, like:
    bp.Addresses.AddressType = SAPbobsCOM.BoAddressType.bo_ShipTo;
    bp.Addresses.AddressName = "My Address";
    etc...
    etc...
    returnval = bp.Update();
    Hope it helps,
    Adele

  • Bill to address in AR

    I need to find Bill to address with customer names as View:
    When i try i am getting duplicates :::
    Can some one show me the missing link????
    CREATE OR REPLACE VIEW XX_PARTY_NAMES_V
    (CUSTOMER_NUMBER, PARTY_NAME, ADDRESS_LINE_1, ADDRESS_LINE_2)
    AS
    SELECT DISTINCT
    cust_acct.ACCOUNT_NUMBER AS CUSTOMER_NUMBER
    --party.party_number
    -- ,PARTY.PARTY_ID
    ,UPPER(PARTY.PARTY_NAME) AS PARTY_NAME
    ,loc.address1 address_line_1
    ,LOC.CITY ||' - ' ||DECODE(LOC.PROVINCE,NULL, LOC.STATE, LOC.PROVINCE)||' - ' ||LOC.COUNTRY ADDRESS_LINE_2
    FROM
    hz_cust_acct_sites_all acct_site,
    hz_party_sites party_site,
    hz_locations loc,
    hz_cust_site_uses_all site,
    hz_parties party,
    hz_cust_accounts cust_acct
    WHERE site.cust_acct_site_id = acct_site.cust_acct_site_id
    AND acct_site.party_site_id = party_site.party_site_id
    AND party_site.location_id = loc.location_id
    AND acct_site.cust_account_id=cust_acct.cust_account_id
    AND cust_acct.party_id=party.party_id
    AND site.site_use_code = 'BILL_TO'
    /

    There are three options to do this (ofcourse none are standard).
    Source can be item instance or customer master itself.
    1. Maintain the relationship in the item instance (serial number) if you are using customer products to create service requests. If you have that bill to in the csi_ip_accounts, and when the instance is used for the service request creation, you can default that in the service request using custom.pll or personlization. This should be easy.
    2. Or using the same approach, you can go HZ tables to get the bill_to of that ship_to.
    3. If you are using SR workflow, plugin one node which updates this in the SR.
    Thanks
    Nagamohan

  • Emaill address in the ship to first and then look for the sold to

    Hi,
    I have a requirement where-
    The output should use Emaill address in the ship to first and look for the sold to if the record is not available in the ship to.
    Can somebody help?
    Regards,
    Pankaj Jain

    If you are taling about the email address used in the output determination process, you can do the following.
    Set up the access sequence for the output with two steps:
    1.  For the ship-to
    2. For the sold-to
    (you can use the same table - just set up the fields assignment differently on the two steps>
    On the 1st step, assign a requirement routine that checks for the email address on the partner. If it isn't there (i.e. on the ship-to), the access will be skipped - and the system will determine the output for the  sold-to,
    You will need an ABAPer to create a requirement routine (VOFM).

  • Bill To Address

    Hi Experts,
           I have customer master record in my SAP B1 2007 B application for whom both Bill To and Ship To address are specified and defaults are set. But if I create any A/R Invoice for him, none of these addresses come in the logistic tab. Can any one tell me why is it so or what I should do inorder to have the address displayed in the Invoice.
    Please Advise...
    Thanks & Regards
    Jaics

    Hi Nat,
    Yes.. I have defied both Bill To and Ship To addresses for the customer and it is set as default. But when select this customer to the Invoice, the default address does not get copied into it and hence does not appear in the print preview
    Note:
    1) I have only one Bill To and only one Ship To address specified which I set as DEFAULT.
    2) I used the default system PLD with out any modification to see the preview
    Please Advise...
    Thanks & Regards
    Jaics

Maybe you are looking for

  • User Contributed Tips in Intel-based iMac Your Intel-based iMac Display

    *The following User Contributed Tips are located in the Intel-based iMac > Your Intel-based iMac Display forum:* a brody - Using a second Mac as a display for a first http://discussions.apple.com/thread.jspa?threadID=1587927 Publish date: July 7, 200

  • Table  for pegged requirement

    HI, I need to develop a report to  identify the pegged requirement against purchase requsition for the dependent requirements of low-level components. i have checked MD_PEGGING  and MD_PEGGING_NODIALOG but these FM are not suitable for my requirement

  • How to create an editable table in ADF 10g??

    Hi, I want to create a editable table using the Jdev 10g.. so that i can do read and write on the table. Can anyone tell me how i can create it... thanks in advance

  • Signal for non-child process death

    I am porting an NT system to Solaris. One process (HM) is responsible for starting groups of server processes, monitoring for death of a process, stopping/restarting/recovering the group. I know how to port this using fork/exec to start processes and

  • SLS changing short/login name

    I've seen this in other threads (at least on Apple's discussion board) and thought I had a temp fix, but it hit again today. When you add aliases to a user in Workgroup Manager, it can/has change the primary shortname for one of the aliases, thereby