According to this post
you’ll have to cast it to a byte array.
byte[] dt = dataReader["dt"] as byte[];
More Related Contents:
- Procedure or function xxxxx has too many arguments specified [duplicate]
- How to pass an array into a SQL Server stored procedure
- Remove weird characters ( A with hat) from SQL Server varchar column
- SQL error: Incorrect syntax near the keyword ‘User’
- What represents a double in sql server?
- Passing List to SQL Stored Procedure
- Use of SqlParameter in SQL LIKE clause not working
- WHERE IN (array of IDs)
- SQL: Update a row and returning a column value with 1 query
- Generate class from database table
- Query validation using C#
- How do I calculate the equivalent to SQL Server (hashbytes(‘SHA1’,[ColumnName])) in C#?
- Passing array to a SQL Server Stored Procedure
- Generating sql code programmatically
- An unhandled exception of type ‘System.InvalidOperationException’ occurred in System.Data.dll?
- Using stored procedure output parameters in C#
- Insert entire DataTable into database at once instead of row by row?
- How to execute an SSIS package from .NET?
- How to retrieve data from a SQL Server database in C#?
- Bulk Update in C#
- Any way to SQLBulkCopy “insert or update if exists”?
- EF 6 – How to correctly perform parallel queries
- Delete a single record from Entity Framework?
- ExecuteNonQuery returning -1 when using sql COUNT despite the query string
- GO statements blowing up sql execution in .NET
- How to Identify the primary key duplication from a SQL Server 2008 error code?
- Provider named pipes provider error 40 could not open a connection to SQL Server error 2 [duplicate]
- Is it possible to use SqlGeography with Linq to Sql?
- Should the order of LINQ query clauses affect Entity Framework performance?
- How do I connect to a SQL database from C#?