I'm writing a program that copys a file, but if the targfetfile already exists i want a replace form, preferebly just like windows own. I've googled my a-s of to find such a thing, but no luck so far. I've made one by my own, but it's not as good as the original. Help would be appreciated.
H3rman
Posts
-
Is there any replace file dialog/form in .net? -
bitmap.save(filename) - A generic error occurred in GDI+.You saved my day, Thanks.. I learn something new everyday! :D
-
bitmap.save(filename) - A generic error occurred in GDI+.I'm not very good at programing, and when i tries to save the bitmap to a file i get the "A generic error occurred in GDI+." what am i doing wrong? I wrote a smal app to demonstrate what my problem is. In the real app it modifies some exif data and are then supposed to save the file. Public Class frmSaveFile Private _bitmap As Bitmap Private _filename As String = "d:\husvagn.jpg" Private Sub btnOpen_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnOpen.Click _bitmap = New Bitmap(_filename) btnOpen.Enabled = False btnClose.Enabled = True End Sub Private Sub btnClose_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnClose.Click _bitmap.Save(_filename) btnClose.Enabled = False btnOpen.Enabled = True End Sub End Class
-
inserting value in start of arrayThank you guys, I'm forever gratefull.
-
inserting value in start of arrayHi again.... I got it workin but I'm note quite happy with my coding.... feels like alot of unnecessary steps just for combinding two arrays with a few bytes in it. Dim myMessage As New ArrayList Dim myByte() As Byte = {255, 255, 255, 255} myMessage.AddRange(myByte) myMessage.AddRange(Encoding.UTF8.GetBytes("rcon popeye status")) myByte = myMessage.ToArray(GetType(Byte))
-
inserting value in start of arrayImports System.Text Dim myBytes() As Byte myBytes = Encoding.UTF8.GetBytes("TESTSTRING") Dim myStartBytes() As Byte = {255, 255, 255, 255} I want the mystartbytes to be in mybytes(0,1,2,3) but not overwrite but to push in the value so the rest of the array is moved 4 steps. Do you understand what i mean?... My brain has freezed up.... thanks for your help.
-
inserting value in start of arrayI have struggling with this for a few days now and i can't come up with a solution, damn it I can't sleep. I have a array of bytes (iv'e used the UTF8 encoding from string to bytes) but i wan't to insert 4 bytes (255 = &HFF) before the result from the encoding. How do i do this the easiest way? do i have to loop through all values in the array? that seems to be a huge waste of cpu. Thanks. And a merry merry X-Mas!!!!