
adude
Members-
Posts
22 -
Joined
-
Last visited
adude's Achievements
Newbie (1/14)
0
Reputation
-
Hi, I'm creating a program (VB.NET 2003) that needs to display a list of pictures (thumbnail size) (like one of the digital photo album programs). I've tried using PictureBoxes but they're painstakingly slow (especially when resizing, I have to adjust the location of all the thumbnails). I've experimented with DrawImage in Graphics, but how can I access each drawn item in the Graphics object. For instance, with PictureBoxes, I could say: dim ctrl as Control For Each ctrl in Me.controls If TypeOf ctrl is PictureBox Then MsgBox(PictureBox.Location.toString()) End If Next Although this is a pretty dull example, how can I access properties, methods, events of drawn items in Graphics? Do they even have props, methods, and events? For example, I couldn't find anything like a getImages() or getItems() or Items in the Graphics class. I also tried creating an ArrayList of Images... but it's properties are all ReadOnly... (I was trying to double the size of the first image in the graphics as a test) Thanks a lot.
-
IT'S ALIVE!!!! After some treading through Google results, I found an interesting article here (http://www.code101.com/Code101/DisplayArticle.aspx?cid=51) that told me to download the latest Windows Script v. 5.6... I downloaded & installed it from here (http://www.microsoft.com/downloads/details.aspx?FamilyId=C717D943-7E4B-4622-86EB-95A22B832CAA&displaylang=en) and it worked! (I guess the error must have reverted/corrupted/damaged the Window Script - that's why reinstallations did nothing) I hope my problems help someone else out there in the internet frantically searching for the perilous error "ClassFactory..." :)
-
Ok.... I uninstalled everything... even the .NET SDK... I deleted the Registry Folder... I reinstalled everything inc. VB.NET... Still the exact same message... Any help would be greatly appreciated...
-
thanks for the help... can anyone else offer any advice? I could delete delete the HKEY_LOCAL_MACHINE > Software > Visual Studio "registry folder", but I'm afraid making any more changes to the registry would mess it up more...
-
I completely uninstalled and reinstalled it.... However, it still gives the message. Also, for some reason, the uninstall didn't get rid of all the registry keys b/c after reinstalling, it still had the list of my last 20 projects. :( Is there anything else I can do? Granted the fact that I'm not too good with the registry, but I can manage if I have to.
-
Do you mean completely uninstalling and then reinstalling? (B/c I already Repaired/Reinstalled VB.NET)
-
Hi, I've been using Visual Basic .NET 2003 Standard for a long time already. Recently, (although I'm not sure if this is a related incident or not) my XP Home computer (with 3 GHz and 1 GB RAM) gave me a BSOD. When I restarted, XP gave me a message about something like it had restored the Registry after some kind of error. I had to reinstall Norton AntiVirus and rearrange some IE links. But, now in VB.NET, whenever I make a new project or Add New Item > Windows Form, it gaves me either "ClassFactory cannot supply requested class" or "Unspecified error". Also, I can view previous project, but I can't add new forms to them. And when I create a new project, it does create the proper folder, etc, just not the Windows Form "Form1". I was wondering if anyone knew what the origin of this kind of error is. I already did a "Repair/Reinstall" of VB.NET, but the problem didn't go away. Thanks.
-
Thank you, but unfortunately, it still doesn't work. (Though, I don't even know why I had a New Netstr in a timer) In response to your comment, I tried doing some kind of loop/timer where the "offset integer" would increase - then I made the "size" increase (the parameters for netstr.read()). Dim offInt as integer = 0 'Timer '... i = netStr.read(bytes, offInt, bytes.length) offInt += 2048 What is also interesting is that if I also use dSR.ReadtoEnd() it gets a different part of the file - but still only a small part. It makes sense, but I feel like I'm missing a small but crucial part. Unfortunately, nothing worked - except if I change the bytes(1024) --> bytes(2048) I get the first 2kb of info... I tried putting a large number in but the IDE warned me of a "overflow" problem.
-
Hi, I'm making an IRC Client in VB.Net (2003). I'm trying to incorporate a DCC (Direct Client-To-Client) Get, but I'm having problems. It only downloads the first kilobyte of information. I tried unsuccesfully using a BufferedStream. Here's most of my code: 'TO CONNECT DLipEndPt = New IPEndPoint(ipAddress, port) 'connect txtStatus.Text &= "Connecting, please wait..." & vbCrLf dSock = New Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp) 'make a tcp socket dSock.Connect(DLipEndPt) netStr = New NetworkStream(dSock, True) dSR = New StreamReader(netStr) dSW = New StreamWriter(netStr) Application.DoEvents() timerGetStr.Enabled = True 'THE TIMER (set to 100) Try If txtStatus.Text.ToLower.IndexOf("receiving file") = -1 Then ' does only the first time dSW.WriteLine("DCC GET " & nickName & " " & filename) dSW.Flush() txtStatus.Text &= "Sent acknowledgement..." & vbCrLf 'the acknowledgement is in accordance to the RFC guide 'to the IRC protocol netStr = New NetworkStream(dSock) End If Application.DoEvents() If txtStatus.Text.ToLower.IndexOf("receiving file...") = -1 And txtStatus.Text.ToLower.IndexOf("finished") = -1 _ Then txtStatus.Text &= "Receiving file..." & vbCrLf If netStr.DataAvailable Then Dim bytes(1024) As [byte] Dim data As [string] = Nothing Dim i As Int32 = netStr.Read(bytes, 0, bytes.Length) If i <> 0 Then ' Translate data bytes to a ASCII string. 'If Not serverWindow Then Console.Write("timer is working in channel window") data = System.Text.Encoding.ASCII.GetString(bytes, 0, i) fSW = New StreamWriter(saveFileTo, True) fSW.Write([string].Format("{0}", data)) fSW.Close() wroteToFile = True Application.DoEvents() End If ElseIf netStr.DataAvailable = False And wroteToFile Then If txtStatus.Text.ToLower.IndexOf("finished") = -1 Then txtStatus.Text &= "Finished downloading..." btnOpenFile.Enabled = True btnClose.Text = "Close" Beep() Application.DoEvents() End If End If Catch ex As Exception errorMsg(ex) txtStatus.Text &= "An error has occurred..." & vbCrLf End Try Basically, the problem is that it downloads a packet of data and stops. This is odd because I used almost the exact same code for the actual IRC part and it works great. (I also tried using dSR.Readtoend) and it also just gives me a packet of data). Thank you in advance.
-
I don't know what happened, but now that I re-downloaded it, it works (I think maybe the server didn't update your update right away?). Either way, I appreciate the code :). I'll be sure to add "Hamburger1984 of Xtreme .Net Talk" in my About Section. :D This site is the best
-
Thanks a lot for your time... but I don't know how to implement the code :confused: . I ran it without any modifications and nothing happened. I'm not too advanced of a VB programmer so I don't understand how, for example, CropControl.onMouseDown can be "linked" to the pnlEditPic.MouseDown event. To get it to even show the original pic I had to add some code, like: Dim myCropC As New CropControl myCropC.LoadImage(ofd.FileName) pnlEditImage.BackgroundImage = New Bitmap(ofd.FileName) ...otherwise it gave me an error: "Object reference not set to an instance of an object." on the LoadImage command. I'm guessing that I'm not doing something that I should be. (I d/led the attachment at 5:00 pm on March 15, so it should've had that "bug" fixed) I would appreciate any help on this. Thanks again.
-
Hi, I am trying to make a crop tool for a picture. Right now, I'm making the actual crop tool. I want it to be a simple box that is draggable & resizes to the mouse over a picture(box). I've tried many different things and nothing has worked (or worked well): I tried using graphics, but I needed to clear the graphics so that the past boxes won't be seen (so that it drags). However, when I cleared the graphics, it cleared the image in the picturebox. So I made it DrawImage each time it cleared... But this made it so flashy you couldn't see the dragging of the box (especially since I'm working with big picture files). I also tried resizing labels to look like lines... But this too was too slow and didn't seem like it was a good way to do it. I would appreciate any help any one could give, primarily on how to keep an image loaded while clearing the graphics on it. Or, how to have "layers" of graphics so that I could clear "Layer 2 - The Crop Tool" but not "Layer 1 - The Image". Thanks in advance. (Btw - I love the new look of the site. Good job!)
-
Thanks - it was right there! I guess I kept missing it cause it's a .NET Reference... :rolleyes:
-
Thanks for the clarification... but how come I don't have the System.Web.Mail namespace (when I try Imports System.Web.Mail and when I do New System.Web.Mail.Message) - I only have 3 things under System.Web that all start with "ASPNet" & something else - I don't have Mail. Is there other code I have to use if I'm just connecting to, for example, mx4.hotmail.com? Is it a reference or component of some sort? Thanks again.
-
Hi. I'm currently using Visual Studio .NET 2003 on Windows XP Home Edition. I've read several threads on "Email" in the forums but still have some questions... In this thread http://www.xtremedotnettalk.com/showthread.php?s=&threadid=73249&highlight=email, user "begin_with_A" said (as far as I understand) that to use the System.Web.Mail (since right now I don't have that option in VStudio), you would need to go the XP Add/Remove Windows Components and "activate SMTP." However, I don't seem to have anything that directly says "SMTP." I'm using Windows XP Home Edition... is this another one of those "Professional-Only Things"? And which has to have SMTP activated: 1. "Programming" Computer 2. Sending Computer 3. Receiving Computer If it is a professional thing, is the only other route to use an Outlook reference? Thanks.