Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Web Development
  3. ASP.NET
  4. DBCombo Replacement

DBCombo Replacement

Scheduled Pinned Locked Moved ASP.NET
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sam Heller
    wrote on last edited by
    #1

    Currently in the process of updating a project from V.1.1 to V.2. Previous project implemented a Drop down combo box which included auto complete. This drop down no longer works in V.2 and support is poor and no updates are available. We attempted using the Ajax extender control but the issue with this is it can only retrieve a single column of data. For most of the scenarios we are using it in we require a unique id to be retrieved too. Due to the original control being a drop down list it had a text and value attribute so could store this informaiton. Does anyone know of a new third party control or other solution that would fix this issue? Thanks

    D 1 Reply Last reply
    0
    • S Sam Heller

      Currently in the process of updating a project from V.1.1 to V.2. Previous project implemented a Drop down combo box which included auto complete. This drop down no longer works in V.2 and support is poor and no updates are available. We attempted using the Ajax extender control but the issue with this is it can only retrieve a single column of data. For most of the scenarios we are using it in we require a unique id to be retrieved too. Due to the original control being a drop down list it had a text and value attribute so could store this informaiton. Does anyone know of a new third party control or other solution that would fix this issue? Thanks

      D Offline
      D Offline
      Dr_X
      wrote on last edited by
      #2

      I had it working with Ajax beta 1. I think it was beta 1 or an earlier version. Project is on hold for now. Anyway, take a look below. Might be helpful as it did work. It also had add-on-the-fly option. aspx's javascript

      function lfV()
      {
      //onkeydown="blur();"
        try {
          ListData.GetVesselID(document.getElementById('<%= Vessel.ClientID %>').value, vesselIDReturn);
       } catch(e) { alert(e.message); }
      }
      
      function vesselIDReturn(vesselID)
      {
        if (vesselID==0)
        {
          //alert("vesselIDReturn");
          if (!(document.getElementById('<%= butSave.ClientID %>')==null))
          {
            if (document.getElementById('<%= Vessel.ClientID %>').value.length > 3) {
              if (confirm("The vessel, '" + document.getElementById('<%= Vessel.ClientID %>').value 
                  + "' does not exist. Please confirm it is spelled correctly with out abbreviations before adding. \\n"
                  + "Would you like to add the new vessel, '" + document.getElementById('<%= Vessel.ClientID %>').value + "'?")) 
              {
                //alert(uid);
                ListData.AddVessel(document.getElementById('<%= Vessel.ClientID %>').value, uid, AddVesselIDReturn);
              }
            }
          }
        }
        else
        {
          document.getElementById('<%= VesselID.ClientID %>').value=vesselID;
          document.getElementById('<%= butRefreshList.ClientID %>').click();
        }
      }
      
      function AddVesselIDReturn(vesselID)
      {
        try
        {
          if (vesselID==0)
          {
            alert("Failed to add new vessel.");
          }
          else
          {
            document.getElementById('<%= VesselID.ClientID %>').value=vesselID;
          }  
        } catch(e) { alert(e.message); }
      }
      

      aspx's html

                        <
                          <
                            <
                            <
                            <
      
      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups