locked
datakeys for gridview control RRS feed

  • Question

  • User-1997257017 posted

    In a vb.net 2010 web form application, I see that there is a gridview control that use datakeys. When I do a search on the web, it looks like datakeys are only used up until visual studio 2010. Is this correct? If so, what control/property/ and/or  logic is used to replace the data keys control on a gridview control?

    If this is not true, up until what version of visual studio can I use for a gridview control?

    Monday, December 18, 2017 7:31 PM

Answers

  • User475983607 posted

    The DataKey Class is available in .NET framework 4.7.1 which is the latest.  At the top of the DataKey reference documentation there is a link that takes you to the .NET API Browser where you can lookup classes that you're interested in learning about.

    https://docs.microsoft.com/en-us/dotnet/api/system.web.ui.webcontrols.datakey?view=netframework-4.7.1

    The .NET API Browser shows that DataKey class is still part of the the .NET framework.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, December 18, 2017 7:44 PM
  • User-1716253493 posted

    In a vb.net 2010 web form application, I see that there is a gridview control that use datakeys. When I do a search on the web, it looks like datakeys are only used up until visual studio 2010. Is this correct? If so, what control/property/ and/or  logic is used to replace the data keys control on a gridview control?

    If this is not true, up until what version of visual studio can I use for a gridview control?

    Not correct, I never heard of it. GridView is related to netframework instead visual studio,

    From net 2.0 till now (latest netframework), from oldest till VS2017 I use GridView and the Datakeys

    Datakeys are used up till now instead vs 2010.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 19, 2017 12:52 AM
  • User-707554951 posted

    Hi wendy elizabeth, <o:p></o:p>

    As oned_gk mentioned, Gridview could be accessed since .NET Framework 2.0<o:p></o:p>

    https://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview(v=vs.110).aspx#Version Information

    it looks like datakeys are only used up until visual studio 2010. Is this correct?

    So, it is not correct.

    If this is not true, up until what version of visual studio can I use for a gridview control?

    for .NET Framework 2.0 be included  Visual Studio 2005

    So, we can use gridview control with datakeys property from Visual Studio 2005 

    https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/versions-and-dependencies

    <o:p></o:p>Best regards <o:p></o:p>

    Cathy<o:p></o:p>

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 19, 2017 9:30 AM

All replies

  • User475983607 posted

    The DataKey Class is available in .NET framework 4.7.1 which is the latest.  At the top of the DataKey reference documentation there is a link that takes you to the .NET API Browser where you can lookup classes that you're interested in learning about.

    https://docs.microsoft.com/en-us/dotnet/api/system.web.ui.webcontrols.datakey?view=netframework-4.7.1

    The .NET API Browser shows that DataKey class is still part of the the .NET framework.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Monday, December 18, 2017 7:44 PM
  • User-1716253493 posted

    In a vb.net 2010 web form application, I see that there is a gridview control that use datakeys. When I do a search on the web, it looks like datakeys are only used up until visual studio 2010. Is this correct? If so, what control/property/ and/or  logic is used to replace the data keys control on a gridview control?

    If this is not true, up until what version of visual studio can I use for a gridview control?

    Not correct, I never heard of it. GridView is related to netframework instead visual studio,

    From net 2.0 till now (latest netframework), from oldest till VS2017 I use GridView and the Datakeys

    Datakeys are used up till now instead vs 2010.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 19, 2017 12:52 AM
  • User-707554951 posted

    Hi wendy elizabeth, <o:p></o:p>

    As oned_gk mentioned, Gridview could be accessed since .NET Framework 2.0<o:p></o:p>

    https://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview(v=vs.110).aspx#Version Information

    it looks like datakeys are only used up until visual studio 2010. Is this correct?

    So, it is not correct.

    If this is not true, up until what version of visual studio can I use for a gridview control?

    for .NET Framework 2.0 be included  Visual Studio 2005

    So, we can use gridview control with datakeys property from Visual Studio 2005 

    https://docs.microsoft.com/en-us/dotnet/framework/migration-guide/versions-and-dependencies

    <o:p></o:p>Best regards <o:p></o:p>

    Cathy<o:p></o:p>

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, December 19, 2017 9:30 AM
  • User-1997257017 posted

    I was assuming the datakeys were not being used due to the link: https://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.datakeys(v=vs.110).aspx. At the top of the link, it did say current. However when other frameworks were listed, vs 2010 was at the top of the list. To me, this had implied like datakeys were not used in visual stuidio 2012, 20114, etc.

    Tuesday, December 19, 2017 2:54 PM
  • User475983607 posted

    I was assuming the datakeys were not being used due to the link: https://msdn.microsoft.com/en-us/library/system.web.ui.webcontrols.gridview.datakeys(v=vs.110).aspx. At the top of the link, it did say current. However when other frameworks were listed, vs 2010 was at the top of the list. To me, this had implied like datakeys were not used in visual stuidio 2012, 20114, etc.

    Try using the .NET API Browser when you have questions like this... all the old reference docs have a link to the new API docs.

    The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

    Tuesday, December 19, 2017 3:04 PM