I don't know because you still haven't told us what you want to do. You can either use my example and read up a bit more yourself or explain what you want to do. We need to know what you want to send...
Type: Posts; User: Joacim Andersson
I don't know because you still haven't told us what you want to do. You can either use my example and read up a bit more yourself or explain what you want to do. We need to know what you want to send...
Hi and welcome to the VBForums.
People here are usually reluctant to do that. This forum is for learning and to just give you the source is not what we consider to be a learning experience. If...
That is a barebone HTTP GET request. Basically that is what your web browser would send to the web server if you navigate to http://www.microsoft.com (in reality the web browser would send more...
PictureBox1.Load("c:\Path\ImageName.jpg")
Why not put a PictureBox on your Form and load the image into that?
Well, it depends on what you want to get back. Here's a quick example that access www.microsoft.com:
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
Dim...
If you can't tell us what you're trying to do then it's rather difficult to tell you what you're doing wrong. All communication must follow a specific protocol and there is no way of knowing what...
No, what I'm telling you is that the exception you say that you get tells you that the server has rejected your connection. I don't know if the IP or Port are wrong since I have no idea what you have...
I don't understand what you're trying to do. What is the layout of your file? Maybe you need to read in more information from the file before you even add an item to the list?
The problem is that you're declaring app_name inside the If .... End If statement. That means it only exist inside that code block so directly after the End If it doesn't exist anymore but there is...
So the server is rejecting your connection. So you're either trying to connect to the wrong connection or there's something wrong on the server side. There is no way of telling since all we see is...
Post the code you're using where you get this error when using the System.Net.Sockets.
As jmcilhinney already suggested. Start by replacing the ActiveX component with the .Net classes.
Well, I guess you need to change the code on line 127 because that might be the cause of the error. :)
You haven't posted any code so there is no way anyone can tell you how to solve it.
Yes, if you use the code I showed. The ReadLine that he had commented out will read the whole line and move the cursor to the next line so he never get to parse the line.
HRESULT 0x800a9c46 translates into this error message:
"Wrong protocol or connection state for the requested transaction or request"
A file that you just saved to disk might not actually be written back to disk immediately. Windows may cache the changes to a file and write these changes back at a later time (normally Windows...
That will not work if some of the data in the CSV contains a comma. Normally you would quote such data, take this line as an example:
C197642, "Smith, John", Carbon, 27
That will be parsed to...
I'm guessing that your myReader is an instance of the TextFieldParser class, if so you can use the PeekChars method to read a number of chars without advancing the cursor. If the number of chars you...
Of course he will see the content if he opens it up in another application. If the content is cached it will be taken from the cache instead of from the disk.
dday9 has the correct idea, however since you're using VS2008 there is no Count method on the array returned by GetProcessByName since that is an extension method introduced in VS2010. Hard coding in...
You can specify FileOptions with a FileStream object, a couple of the constructors take the FileOptions as an argument.
The FileOptions is an enumeration and one if its values are WriteThrough...
This sounds like a strange request. You usually do a risk analyze when you start a new project so the risk analyze itself is part of the project work (in other words the risk that the project itself...
I guess the confusion is that he posted the same icon image twice. That the website mentions aspect ratio has nothing to do with it, that is about how the conversion of the image to an icon is made...
Sorry but binary files (such as EXE's) are not allowed in attachments in this forum.
So not only want you want to learn how to send out spam you're also going to do it by hijacking someone else's Internet connection?
Thread closed.
Moved to the VB.Net forum (COM and ActiveX programming have nothing to do with COM ports).
The hex code just shows NULL values so I guess the file is empty.
I will close this thread since it was 8 years old but I just want to clarify what I wrote 8 years ago.
VB always creates the BSTR when you declare a string, even if the actual text already exists...
The only time that would result in an error is if you try to put that code outside of a sub or function. You can declare a variable at that point but not assign any value to it.
But the code is inherited, the OP did not write the project or this method. Why do you assume that the intended code should look different? The question that was asked was answered already in post #3...
Oh boy! Do you know how many projects I've created in VB6 through the years? This works perfectly:
Private Sub Command1_Click()
Dim value As String
value = ""
MsgBox value
End Sub
The OP has obviously inherited the code so he might not know where and how this function is used elsewhere. By just looking at the naming convention used by this method one must assume that it was...
You guys do realize that this is an 8 year old thread, right?
NULL for strings in API's = vbNullString not vbNullChar since that would be equal to an empty string in C.
Sorry but that is just...
That's most likely because Windows icon cache is corrupted. The icon cache is (normally) located here:
C:\Users\<username>\AppData\Local\IconCache.db
Try to delete that file and restart Windows....
The error is saying that there is no child control on the tab. You still must do something wrong, the code I posted was only to create the tab and set focus to it, you obviously still need to add the...
Why? If the text in the file is an integer why shouldn't the function return an integer? It would be safer to use Integer.TryParse than CInt but the function is still returning an integer, and...
You're adding the browser to the SelectedTab but that tab is not the same as the newly created tab. Try this:
Dim tabPage As New TabPage
tabPage.Text = "New Page"
...
Your default editor settings have been changed to use the Binary Editor instead of the Form Designer. To change that right click on the file in the Solution Explorer and select Open With... Make sure...
You're getting the warning since GetSettingInt returns an integer and you're assigning that to the Text property of a TextBox which is a String property. If you want to get rid of the warning use...