11/26/2024 3:25:15 AM
|
|
slxdeveloper.com Community Forums |
|
|
|
The Forums on slxdeveloper.com are now retired. The forum archive will remain available for the time being. Thank you for your participation on slxdeveloper.com!
Forum to discuss building external web applications for SalesLogix. View the code of conduct for posting guidelines.
|
|
|
|
Reading BLOB data
Posted: 22 Jul 06 9:32 AM
|
fiogf49gjkf0d Does anyone have an example, or can point me in the right direction for reading blob data?
-- Thx Duncan |
|
|
|
Re: Reading BLOB data
Posted: 25 Jul 06 3:09 PM
|
fiogf49gjkf0d The script below works, but I'm sure its not the best way to do it, if anyone knows a better way before I figure it out please let me know
Dim sbHTMLdata As New StringBuilder Dim dbCon As New System.Data.OleDb.OleDbConnection(ConfigurationManager.AppSettings("ConnectionString")) Dim sql As String sql = "SELECT DATA FROM PLUGIN WHERE (Pluginid = '" & pluginID & "')" Dim dbAdapter As New System.Data.OleDb.OleDbDataAdapter(sql, dbCon) Dim ds As DataSet = New DataSet("myBlob")
Dim MyData() As Byte = New Byte(0) {} dbAdapter.Fill(ds, "myBlob") Dim myRow As DataRow myRow = ds.Tables("myBlob").Rows(0)
MyData = CType(myRow("DATA"), Byte()) Dim ArraySize As Integer = New Integer ArraySize = MyData.GetUpperBound(0)
Dim x As Integer For x = 0 To ArraySize sbHTMLdata.Append(Chr(MyData(x))) Next
Dim blobString = sbHTMLdata.ToString |
|
|
|
You can
subscribe to receive a daily forum digest in your
user profile. View the site code
of conduct for posting guidelines.
Forum RSS Feed - Subscribe to the forum RSS feed to keep on top of the latest forum activity!
|
|
|
|
|
|
|
|