Harvey Posted May 11, 2005 Posted May 11, 2005 (edited) My challenge right now is to encrypt the data stored in a database with a VB.Net application I am developing. I have a function to encrypt the data, but I can not figure out how to send it values in the dataset. I have no problems binding controls to my dataset, but when the application opens I want to send each value in the dataset to the function that decrypts the value so the data can been interacted with by the user. Then I want to send each value to a function to encrypt it when the app closes. This way the data stored in the database will always be encrypted. I can not find a way to edit values in the dataset unless it is through a bound control. Is there a way to populate an array with the dataset, change the values in the array, and repopulate the dataset? Or any better ideas? I am new to ADO.Net. Thanks in advance- Harvey Edited May 12, 2005 by Harvey Quote
Machaira Posted May 12, 2005 Posted May 12, 2005 Something like: Dim dt As New DataTable Dim iLp, ilp2 As Integer 'assumes you've filled the datatable For iLp = 0 To dt.Rows.Count - 1 For ilp2 = 0 To dt.Columns.Count - 1 dt.Rows(iLp).Item(ilp2) = Decrypt(dt.Rows(iLp).Item(ilp2)) Next ilp2 Next iLp dt.AcceptChanges() 'bind to controls Quote Here's what I'm up to.
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.