Deleting an Image from the DevEx PictureEdit Control


Author
Message
Bill Cunnien
Bill Cunnien
StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)
Group: Forum Members
Posts: 785, Visits: 3.6K
The image from the DB displays fine.  I can add/edit the image on the form.  It persists in the DB without errors.

If I choose CUT or DELETE from the context menu, I get a DBNull error popping up.  Of course, this is not expected (is it ever?) since I spent a good chunk of time yesterday wrestling with the null issue and the image.  I thought I had that thing licked.

Ermm

What can I do about the delete/cut process on the pictureedit control?

Thanks,
Bill

Replies
Bill Cunnien
Bill Cunnien
StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)StrataFrame VIP (1.2K reputation)
Group: Forum Members
Posts: 785, Visits: 3.6K
Oh...btw...I removed the following code (in red):

private void SketchPictureEdit_EditValueChanged(object sender, EventArgs e)
{

   
if (SketchPictureEdit.EditValue == new byte[] {})
    {
       
this.partsBO1.sketch = new byte[] {};
        SketchPictureEdit.EditValue =
string.Empty;
   
}
   
else
   
{
       
this.partsBO1.sketch = (byte
[])SketchPictureEdit.EditValue;
    }
}

Since I have the control bound to the data already, this was redundant.  And, it caused other navigation problems at various points in the user experience.

Trent Taylor
Trent Taylor
StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)StrataFrame Developer (14K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 7K
Ah...yeah, that could cause an issue Smile  Glad you found it.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Threaded View
Threaded View
Bill Cunnien - 17 Years Ago
Trent L. Taylor - 17 Years Ago
Bill Cunnien - 17 Years Ago
Bill Cunnien - 17 Years Ago
Bill Cunnien - 17 Years Ago
                         Since this error is happening within the Set, not the Get, it looks...
StrataFrame Team - 17 Years Ago
                             Nope...no NullValue property that I can discover. There is a NullText...
Bill Cunnien - 17 Years Ago
                                 Oh...btw...I removed the following code (in red): private void...
Bill Cunnien - 17 Years Ago
                                     Ah...yeah, that could cause an issue :) Glad you found it.
Trent L. Taylor - 17 Years Ago

Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search