|
And?
Are you really meant to convert the DataTable to byte array? Or by any chance you want to convert the field's content?
Change GetData so it will return only the data you need, something like this:
dt.Rows[0]["column-name-for-image-data"]
Skipper: We'll fix it.
Alex: Fix it? How you gonna fix this?
Skipper: Grit, spit and a whole lotta duct tape.
|
|
|
|
|
You are returning the wrong object type from your GetData method. A DataTable is not compatible with a Byte[] , so you cannot use a cast.
|
|
|
|
|
Two option for you .
1. Just Change "imgdata1" to "data" in you code .. for example
imgss.ImageUrl="data:image/png;base64," + base64String;
2. With the use of Handler file. (Do Google for it)
|
|
|
|
|
Your code is vulnerable to SQL Injection[^]. NEVER use string concatenation to build a SQL query. ALWAYS use a parameterized query.
Also, you won't have a control called imgss at the page level. The control is defined within a data-bound list; once the list is data-bound, there will be one copy of the control for each item in the list.
"These people looked deep within my soul and assigned me a number based on the order in which I joined."
- Homer
|
|
|
|
|
HI,
This the code:-
foreach(GridViewRow row in GridView1.Rows)
{
if(row.RowType==DataControlRowType.DataRow)
{
//code here
}
}
I didn't understand this line of code: if(row.RowType==DataControlRowType.DataRow)
Can anyone help???
|
|
|
|
|
the DataControlRowType can be the following:
DataRow
EmptyDataRow
Footer
Header
Pager
Separator
so if the row is a "DataRow" then it is a row with data
|
|
|
|
|
|
I am willing to embed live video into my asp.net+vb web page.
The input is from the camera and it is connected to the inbuilt DVR Card (in AGP slot in my PC)
i dont want to use the interface provided by the DVR firm. as they shows their names and menu
i want iyt to be embeded and futher i can change the layout etc.
|
|
|
|
|
Dear All!...
I am working in asp.Net with c# Language. I am using Date Time Picker with Text Box. If i am pick the Text Box date time picker is show in first time after Refresh the page date time picker is not shown again.(Note:I am using master page).
Following Script i am using in my page.
$(function () {
$(".date").datepicker({
changeMonth: true,
changeYear: true,
dateFormat: 'dd M yy',
yearRange: "-100:+10"
});
});
Thanks for advance!....
|
|
|
|
|
Let me guess, there is something vitally important about your problem you have chosen not to tell us, such that you're using an updatepanel, or some other kind of ajax?
|
|
|
|
|
|
In Google Chrome, hit F12, go to Console tab, see if you have any JavaScript errors.
|
|
|
|
|
Currentlly i have started on gps tracking software and i have no idea about it. Plz help me on this. On gps device i set ip and port then after on particular time interval gps send the data on server. Please tell me how to capture this data. Its urgent for me please help.
|
|
|
|
|
Amitk765 wrote: and i have no idea about it So pick your favorite search engine and start looking for material for your subject...
As now you only have a - somewhat hidden - code request only...
Skipper: We'll fix it.
Alex: Fix it? How you gonna fix this?
Skipper: Grit, spit and a whole lotta duct tape.
|
|
|
|
|
But, but it's urgent, don't ya see!
"I had the right to remain silent, but I didn't have the ability!"
Ron White, Comedian
|
|
|
|
|
How to drag cities into dropdownlist (city) from selected dropdownlist (state) of respected state.
E.g. In dropdownlist selected state is Maharashtra, so drag all respected state cities into dropdownlist (city).
|
|
|
|
|
It would require a lot of code. Where are you stuck?
There are only 10 types of people in the world, those who understand binary and those who don't.
|
|
|
|
|
Google "asp.net cascading dropdowns" and you'll find various ways of making one dropdown rely on the value of another. You'll need to get the actual data from somewhere yourself though.
|
|
|
|
|
Here, You have to use Dropdown DataTextField & DataValueField . in DataTextField you have to show State like Maharashtra and in DataValueField you have to set their State_id . after that you have to fetch city data through this state_id in Database.
|
|
|
|
|
I am writing a small MVC utility to add to a large MVC application. What is the best way to do this. It is for a customer and hope I can create an installer.
|
|
|
|
|
Possibly Nuget package will be solution.
|
|
|
|
|
At this point I am very confused. I think of a Nuget package as development add-in. What I need is to create something like a button panel and insert in into the MVC application. Is there a simple example of this using a Nuget Package?
|
|
|
|
|
You should explain a bit more what you trying to do, otherwise is too vague to give any advice
|
|
|
|
|
I am developing a backup and restore PowerShell database utility and need to install it into an existing MVC enterprise application. It was indicated to me that I can create a Nuget package to install this newly created backup and recover DB PowerShell utility. What I am looking for is an example of this type of package. Does anyone know of such an example?
|
|
|
|
|