We value your feedback.
Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
Protected Sub GetFeatureCache() 'Programmatic Caching Setup Dim DataGridCache As DataSet = CType(Cache.Get("DataGridCache"), DataSet) 'Check if Cache item is equal to Nothing If DataGridCache Is Nothing Then Dim IAdapter2 As New IDataSetTableAdapters.FeaturesTableAdapter() Dim features As IDataSet.FeaturesDataTable features = IAdapter2.GetFeatures GridView1.DataSource = features 'insert ito cache, expire in 1 day Cache.Insert("DataGridCache", GridView1.DataSource, Nothing, _ DateTime.Now.AddSeconds(60), TimeSpan.Zero) Else GridView1.DataSource = DataGridCache End If
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.