It is looks like that you are trying to display outcome of code in a messgae box and a list box.May be some thing is missing in the code so that the your outcome(output) is null or something. Post the code here so others can see the problem.
// create a byte[] for the image file that is uploaded
int imagelen = Upload.PostedFile.ContentLength;
byte[] picbyte = new byte[imagelen];
Upload.PostedFile.InputStream.Read (picbyte, 0, imagelen);
// Insert the image and image id into the database
SqlConnection conn = new SqlConnection
// ("...
Hope this will help you:
Abstract method declaration provides no actual implementation, there is no method body; the method declaration simply ends with a semicolon and there are no braces ({ }) following the signature. For example:
public abstract void MyMethod();
The implementation is...
to change a color of control:
public class NewClButton : Button
{
protected override void OnPaint(PaintEventArgs e)
{
base.OnPaint(e);
int borderWidth = 2; //change the width
Color borderColor = Color.Blue;
ControlPaint.DrawBorder(e.Graphics...
Since he use only one customer (ID 111) can't he use a datareader to read the single record. I think this is more efficent (unless he is doing any update or delete etc.)
Are you trying to add a new row for the DataTable from a control( say TextBox) and the user should enter the new data to the control before it update the new row.?
If this is the case- Clear the the text fileds in the TextBoxs(control)
make sure the TextBox is not null before update it...
Hi I need to supply .mdf and .ldf file from msde database with my pacakage so that it can be attached to msde in target computer.
my question is how can I create .mdf and .ldf file from my msde database where I have tabe and other stuff.
I tried to copy.physically, from C:\Program...
I have different size fields in a table(image and text). I need to optimize the printed reports according to size of the field.
Say I print the image it takes more than half of page and
since I connected the rpeort on design time no matter I select the image or not report allocate the space...
Thank you Zhavic:
I use the following method and it worked.
Dim cmd As New SqlCommand("INSERT INTO tablename VALUES (@field1)", conn)
cmd.Parameters.Add(New SqlParameter("@field1", textbox1.text)
many thanks.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.