locked
Complete Extender RRS feed

  • Question

  • User1224235962 posted

    I have created AutoCompleteExtender and showing Employee_Id-EMployee_Name combination.

    Is there a way to store only EMployee_ID in database. It is storing employee_id-Employee_Name

    Wednesday, October 29, 2014 5:12 AM

Answers

  • User1636150863 posted

    hi,

    If you are trying to save your AutoCompleteExtender result.

    try to Extract Only Employee_Id part from each record and then save it.

    something like below before your actual save logic.

    string yourString = "Employee_Id-Employee_Name"; 
    string[] splitString = yourString.split('-'); // '-' is you EmpId and EmpName Separator 
    string empID = splitString[0].Trim();


    regards,

    Ajay

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, October 29, 2014 5:52 AM
  • User61956409 posted

    Hi Sandy,

    Thanks for your post.

    Is there a way to store only EMployee_ID in database. It is storing employee_id-Employee_Name

    As for your problem, I agree with Ajay, you could use String.Split Method to split your AutoCompleteExtender result and extract Employee_Id from string array then save Employee_Id into your database.

    If you’d like to get more information about String.Split Method, you could refer to the following link.

    If you have any question about this issue, please post back freely.

    Best Regards,

    Fei Han

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, October 30, 2014 2:43 AM

All replies

  • User1930269528 posted

    Complete Extender

    3 minutes ago

    I have created AutoCompleteExtender and showing Employee_Id-EMployee_Name combination.

    Is there a way to store only EMployee_ID in database. It is storing employee_id-Employee_Name

    You need to show how you have done it.

    Wednesday, October 29, 2014 5:17 AM
  • User1636150863 posted

    hi,

    If you are trying to save your AutoCompleteExtender result.

    try to Extract Only Employee_Id part from each record and then save it.

    something like below before your actual save logic.

    string yourString = "Employee_Id-Employee_Name"; 
    string[] splitString = yourString.split('-'); // '-' is you EmpId and EmpName Separator 
    string empID = splitString[0].Trim();


    regards,

    Ajay

     

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Wednesday, October 29, 2014 5:52 AM
  • User61956409 posted

    Hi Sandy,

    Thanks for your post.

    Is there a way to store only EMployee_ID in database. It is storing employee_id-Employee_Name

    As for your problem, I agree with Ajay, you could use String.Split Method to split your AutoCompleteExtender result and extract Employee_Id from string array then save Employee_Id into your database.

    If you’d like to get more information about String.Split Method, you could refer to the following link.

    If you have any question about this issue, please post back freely.

    Best Regards,

    Fei Han

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Thursday, October 30, 2014 2:43 AM