How order items on listbox after filled up

I am trying to order items on windows phone c# ListBox after to receive data
my code:
foreach (DataRes listItem in itens)
listView.Items.Add(new Item {
Name = listItem.Name,
Value = compute(listItem.X,listItem.Y),
Best = listItem.Z,
listView.Items.OrderBy(Best => Math.Abs(Best));
I want order by Best absolute value...
GHELFER

Hi helferg01,
Since I do not have your code, I suppose you use the following definition for the Item class:
public class Item
public string Name { get; set; }
public double Value { get; set; }
public double Best { get; set; }
Then in order to order items on listbox by Best absolute value, please try to refer to the following code:
List<Item> MyBoxList = new List<Item>();
foreach (DataRes listItem in itens)
//listView.Items.Add(new Item
// Name = listItem.Name,
// Value = compute(listItem.X, listItem.Y),
// Best = listItem.Z,
MyBoxList.Add(new Item
Name = listItem.Name,
Value = compute(listItem.X, listItem.Y),
Best = listItem.Z,
listView.ItemsSource=MyBoxList.OrderBy<Item,double>(Best=>Math.Abs(Best.Best)).ToList();
Best Regards,
Amy Peng
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.

Similar Messages

  • Unable to update Sales order item level prices after invoice is created

    Dear All ,
    I have the following issue .
    When the sales order was created Z001 price was populated based on the condition record and  the order was in complete status  Then we created delivery and  invoice , the invoice had the same price as that of sales orders.
    Due to some code change related to pricing condition type - Z001 the prices in the sales order is changed to "ZERO" , when the sales order is opened in VA02 .
    We now corrected the code related to condition type - Z001  and now need to get back the on the line items . I wanted to Update prices by clicking on icon " Update" in the line item condition tab . I am not able to do it as the update icon is grayed out.
    Can any one help me with ideas for  fixing this issue  or any SAP utility  program .
    Looking forward to your help .
    Thanks and regards
    Veera

    Hi
    Without reversing invoice we can't update price and this is standard bevaior which is logical too. For your scenario I am wondering why would you want to change price for a line item or order which is alrady invoiced and posted to FI. What difference would it make to change price in sale order when this has already been posted in FI?
    Thank$

  • System resets the sales order item price changes after save in VA02.

    Hi All,
    We have implemented automatic credit control at sales order level.
    System is blocking the sales order once saved in VA01.
    But if I do any changes in prices at item level in VA02 and save before credit releasing the sales order then system agian reset to the original prices from pricing condition records.
    Can any body tell me why this is happening? I should able to change the sales order prices manually before releasing the sales order credit block. Is it possible?
    Regards,
    Kartheek.

    Like Lakshmipathi said, you should be able to change the prices in the order even if the order is under credit limit block.
    Please check the condition types which are being changed . In the condition type definition( T Code V/06) for the field Manual Changes - the value should be either "Manual entry has priority" or "....should allow to change manually...".
    Also in your pricing procedure ( T Code V/08) , against your pricing procedure , please select the value for pricing type as ..."copy manual conditions and redetermine others".
    Hope this helps
    Regards
    Sai

  • Auto completion of Sales order item after upto 90% delivery

    Hello,
    Business Requirement:
    After 90% quantity of an order quantity is delivered, the item should not be considered by MPS planning run and the item should not appear in MD04.
    Current workaround:
    Currently, for that item we are setting Partial Delivery / item = A, manually, and then the order item disappears from MD04.
    Question:
    I found in the customer master sales area data, Partial Delivery / item can be set to A and it gets copied in the sales order. But, the underdelivery talerence is nil in our customer master records. So I dont know how to satisfy the condition of 10% underdelivery. Is there any way by which this can be done, other than writing a program and scheduling it for nightly batch job.

    Hello,
    Business Requirement:
    After 90% quantity of an order quantity is delivered, the item should not be considered by MPS planning run and the item should not appear in MD04.
    Current workaround:
    Currently, for that item we are setting Partial Delivery / item = A, manually, and then the order item disappears from MD04.
    Question:
    I found in the customer master sales area data, Partial Delivery / item can be set to A and it gets copied in the sales order. But, the underdelivery talerence is nil in our customer master records. So I dont know how to satisfy the condition of 10% underdelivery. Is there any way by which this can be done, other than writing a program and scheduling it for nightly batch job.
    Any help is appreciated.
    Thanks.
    Madhura

  • How to arrange the information in alphabetical order in a listbox?

    Can you guys help me out?
    How to arrange the information in alphabetical order in a listbox?
    *The information is taken from a text file using FileReader
    Thanks

    private void jbInit() throws Exception {
    // Get information for the text file
    File f1 = new File("Albums.txt");
    try {
    FileReader fr = new FileReader(f1);
    BufferedReader br = new BufferedReader(fr);
    //Use a loop to read
    for (String str = br.readLine();
    str != null;
    str = br.readLine())
    jListModel.addElement(str);
    //Closing the file
    fr.close();
    catch (Exception ex) {
    JOptionPane.showMessageDialog(this, "Error Retriving File", "error",
    JOptionPane.ERROR_MESSAGE);
    Can you explain to me how to use the Collection class? Above codes is getting the data from my text file and put it into my ListBox(jModelList)... So after inputting the text into it.. how do i arrange it using the Collection?
    Thanks

  • How to add three fields in Sales order item level and supress/hide many

    Hi Gurus,
    My client requirement is :
    1. Three fields to be added at Sales order Item level and they should flow till billing.
    2. Supress/hide most of the fields in Sales order, so that end user will be happy( thru SHDO how to do)
    Please share your experiences and help me.
    BEST REGARDS
    Srikanth

    Hi Subba Rao
    in VA01 screen - Material /qty/ after entering this client wants to enter three more details say X/Y/Z
    and after that he dont want to see maximum fields displayed in VA01 Screen.
    I think it makes sense.
    Regards
    Srikanth

  • How to do INIT for Sales order Itema Data (DS 2LIS_11_VAITM)

    Hi all
    I have a report on sales order item data, I have to reload it. DS 2LIS_11_VAITM
    Can any of you pls explain me the steps to do the INIT? Refill set up tables etc
    Many Thanks in advance
    Ishi

    Hi Hari
    Many Thanks for the explanation and steps. I deleted set up tables and executed to fill it.
    It says in R/3 Start of Processing, I ticked to continue and its still running.
    In the mean time I checked RSA3 and it says 1007 records selected. I am refreshing it and the no. of records are still the same.
    Can you tell me how long it takes to fill the table?
    And the R/3 system is still running (Start of Processing)
    Thanks again
    Ishi

  • New pricing on sales order item after partial delivered and billed

    Hi
    I want to change price of sales order item that already delivered partially and
    billed, but I can't search standard function.
    Can any one help me out  in changing the price of sales order item (VA02).....
    Thanks,
    Wizard.

    Hi DongWoo,
    Under what scenario would you want to re-price after billing?  If you change the price how will your customer know?  You will need to contact your customer and let them know not to pay the last invoice, then delete that billing document in SAP and re-issue it.  When you create the billing document in SAP from a delivery or order you can specify how to re-price in copy control.  Whether or not you want to reprice all conditions, taxes or whatever is in the re-pricing type.
    You need to make sure what we send the customer matches what is in SAP, which is why we generally can't re-price after billing.  Make sense?
    If you want to change the price on the still open items you can reject what is open and enter a new line item.  That will pick up whatever new pricing conditions exist, but you may lose your ATP position & allocation status.

  • Urgent: How to copy multiple sales order items into a return sales order?

    Dear developers,
    I have a requirement to copy multiple sales order items into a single return sales order. For example, generated return sales order have 2 items, item 10 is created with reference to sales item 2610/10 and item 20 is created with reference to sales item 2611/20. What's more, when it happens, copy control should be taken care of. I know it is possible to create this kind of order by transaction. But how to do it in coding?
    In current SAP release, there is only BAPI for creating with reference on 1:1 relationship which means copy one document to another but what I need is N:1 copy.
    Any suggestion is high appreciated!!
    BR,
    Tony.

    Hi ,
    If you are creating sales order by using bapi then after calling bapi you can check import parameter <i><b>SALESDOCUMENT</b></i> in the bapi function module .If this parameter is not initial then sales order is created in this case you can create return order. If this import parameter is initial then sales order is not created and you cannot use return bapi function module.
    Bapi is simple method than BDC.
    In above case it is required to call BAPI_TRANSACTION_COMMIT after every successful sales order creation.
    One more important point is you have to clear import parameter <i><b>SALESDOCUMENT</b></i>  before calling sales order creation function module.
    Thanks,
    shyla

  • Rejected sales order item after partial invoice

    Dear All,
    We have a partially invoiced (and paid) sales order. Now the customer (and we) wants to cancel a sales order item. So we set reason for rejection at item level. In VA05 it still displays the SOI as open and status is being processed. How to proceed, it should not be displayed as open when it is rejected in VA05.
    Can I change the billing plan so that the invoice does not mind the items I want to reject should I ste a billing block? Delivery Block?
    Best regards,
    Michaël
    Edited by: spimic on Oct 5, 2010 6:21 PM

    Hi,
    Take the help of ABAP'er, and explain him that as soon as sales order is invoiced(partially), set the rejection reason to sales order.
    And also define the rejection reason and assign these rejection reasons to billing types.
    Regards
    Ashutosh

  • How can i capture sales order items in C# and pass them to a BAPI?

    Hi everybody,
    here is another novice question for you.
    What control should i use in Visual Studio to allow the user to enter sales order items (material and qty) as a table on the screen and then put these items on a table and call the BAPI to create an order?.
    I've tried using a Datagrid and set the "edititemindex" as "1" but doesn't work.
    Any help will be greatly appretiated.
    thank you
    Javier ...

    Dear Todd,
    thanks for your reply. I'm using ASP. I tried a grid but i cannot seem to make it work, it doesn't appear at first because it's empty, i tried creating some blank rows but the same happens.
    The other thing i tried just to test is to create a row on the table "partners" to pass the needed "AG" (sold to party) and its number and the BAPI keeps returning an error "Please enter Sold ot or Ship to party". Like if the table was empty. Is there any special way to send a table to a BAPI ?. I'm sending it by ref, and i'm creating the record by first creating a structure, filling it an then calling the ADD method of the table and passing the structure. I'm i missing something here?
    Please Help, it's been days with this problem,
    I'll appreatiate it very much
    Best regards and have a great day.
    Javier ..

  • How to have a custom Item Number in Sales Order Items

    Hello Experts,
    We are creating a sales order using IDoc, sales order gets created but, its not taking value what we are populating in Item Number field for Item. Defualtly its filling 10,20 and so on...
    Is there any thing that I need to maintain, so that SAP accepts the custom number for Item number.
    Please help,
    Thanks,
    Suma

    Hi Suma,
    In VOV8, you can see the fields Number system..here u can see sub item increment u can enter 12 here then the next item number will be 500012, 500024 and so on. But if u want to maintain external number range then follow this steps.
    Determine which external number ranges are provided for the relevant
    document type. Choose the function "Maintain number range" of the
    document type (for example: Purchase order -> Maintain number range)
    for this purpose.
    Choose a number range and note its number.
    Enter the number of the desired number range.
    Thanks,
    Raja

  • How to split the Order items using standard procedure

    Hi All,
                   I am a BW Consultant and currently working for Sales Module. I have one question  regarding the Order Item changes in VA02.  For example a user creates one SO with Item 10 and the  quantity is 1000. Later they want to split this Order into two i.e. they change the first item quantity to 500 and create another item (20) with Quantity 500 .Users are doing this ,because of allocation process.
                 Now I would like to ask whether this is a standard procedure to follow.I have no issues with the new item , I am not sure  how they are changing the first order item qty in VA02, because Qty is greyed out . My assumption is, they are deleting the item first and then recreating with the new quantity.
                Hence I would like to check is there any other option/process  available to change the quantity and also would like to know whether it is a standard procedure? Reason I am asking this question is,extractor is not picking the correct records.Hence I suspect this is not a standard procedure to follow.
    Please advice .Thanks for your time.
    Thanks.

    hi raja,
    go to shedule line data of position 10
    here you want to have 1000 pcs for the 18.12.2009
    change her into
    500 pcs for the 18.12.2009   and
    500 pcs for the 21.12.2009
    at 18.12.2009 you will get adelivery of 500
    at 21.12.2009 you will get the rest.
    in total, the Position has 1000 pcs.
    hans

  • How to change material discription at sales order item level ?

    Dear Gurus,
            We have some requirement need to change material description at sales order item level , but in system it is in disable mode how to change that  into change mode in sales order item level?
    Thanks in advance
    Regards
    Venkat

    Not possible in SAP Standard.
    Instead why not create a Customer Material Info Record in T-Code - VD51?
    Alternatively it the requirement to change the Description is only for few Sales Order then create a Text ID & Enter the Description in Text Feild. Then in Smartform program wrie a code which will check for Material Description in the Text first & if not found then take from normal material Description in Sales Order.
    But Customer Material info Record seems to be the best solution.
    Hope this helps,
    Thanks,
    Jignesh Mehta

  • How to add a partner in sales order item by enhancement?

    Hi expert,
    Sales order item's bill-to and payer will be same with header if you do not change it manually. now I want to modify some item's bill-to and payer which different from the header automatically. Is there any enhancement for this function?
    Thanks and best regards
    Lance

    Hi Lance,
    You can populate the XVBPA structure with function module "VIEW_XVBPA_FILL".
    You have to pass the following values to the FM:
    COMWA-KUNNR <- the changed partner code
    COMWA-PARVW <- parter role
    COMWA-VBELN, COMWA-POSNR <- Salesorder and item: just fill it with VBAK-VBELN,VBAP-POSNR
    You'll get the result in parameter XVBPA, which can be used for append the internal
    table XVBPA in the userexit.
    BR,
    Barna

Maybe you are looking for

  • Hyperlink in obiee email reports

    Hi, Well I have a question on hyperlink in obiee dashboards. The requirement is to email obiee Report or dashboard with Hyperlink enabled on date column which opens up PDF from the server for that date. End user will not access obiee analytics at all

  • Need Help in Sender File Content Conversion

    Hi All, I request your expert advice on Sender File content Conversion. I need to process the below pasted file. I was able to achieve this by keeping a offset of 6 in Sender PI File Adapter (PI 7.1) to ignore first 6 lines and used a Unix script to

  • HOW-TO CLUSTER BOBJ XI 3.1 on HP-UX with MySQL

    Hello, I need to understand how to perform an installation of BOBJ XI 3.1 on HP-UX in a cluster. The official documentation it's a bit weird. Someone  can give more hints on the steps to follow? what should be installed on the first node , what in th

  • WEB INTERFACE LAYOUT TEXT ATTACHMENT

    Hi, In the Web Interface, Under the Layout, a Text was created by using Components and selected Text, in Text how do we attach some java code,  there as we have option like    Transfer Text From OTR    Transfer Text from Attributes    Edit Long Text

  • CC Serial Number Licensing Carryover to CC 2014 Versions

    I install CC apps in a college computer lab.  When I create a package with Creative Cloud Packager I specify the license type as "Serial Number License" & submit the required serial number. Installing the package presents no problems and the apps com