Forum   Search   Register   Log in SUPERJER FORA
 

Visual Studio 6

Pages: 1, [2]
Programming Help
Down Rodeo
Cap'n Moth of the Firehouse

Find the Hole II Participation Medal
2007 Oct 19 • 5258
57,583 ₧
It's telling you that a TextBox, i.e. component of a Windows form, is not a string. You need to so something like textbox.contents, or .text, or whatever the class definition says.
Everyone stares when you walk in the room, they stare when you go....
    2009 Dec 11 at 00:52
sprinkles

Chrome Whore
2009 Sep 6 • 2431
10 ₧
Down Rodeo said:
It's telling you that a TextBox, i.e. component of a Windows form, is not a string. You need to so something like textbox.contents, or .text, or whatever the class definition says.


So you're saying
code
map20text.Text

[map20text is the name of the inputbox]
or
code
map20text.contents

??

Edit ::
Thank you DR you're a freakin' genius.
vb code
map20text.text

That works...well until I fuck it up again.
...then I got some ap, and shot a big ass lazar at everyone.
    (Edited 2009 Dec 11 at 10:13)     2009 Dec 11 at 10:07
Rockbomb
Dog fucker

2009 Nov 13 • 1849
-190 ₧
Just so it makes a little more sense, the reason textbox.contents didn't work is because contents isn't a property of the textbox. When you do textbox1.text it is basically saying "The text property of textbox1". When you are in the design tab of your application, and you click on an object, the properties box down in the bottom right is all the properties for that object. So if you wanted to change the border style for the text box you could do textbox1.BorderStyle = BorderStyle.Fixed3D

So basically, anything in the properties box for a particular object is what you can use when your coding it.
    2009 Dec 11 at 10:26
Down Rodeo
Cap'n Moth of the Firehouse

Find the Hole II Participation Medal
2007 Oct 19 • 5258
57,583 ₧
Rockbomb is in fact correct. If you're using Visual Studio there should be some sort of code completion.
Everyone stares when you walk in the room, they stare when you go....
    2009 Dec 11 at 10:50
sprinkles

Chrome Whore
2009 Sep 6 • 2431
10 ₧
Down Rodeo said:
Rockbomb is in fact correct. If you're using Visual Studio there should be some sort of code completion.


Yes, I turned that off don't like it at all.

Edit :: New Question

So I have an ellipsis button that, when I click it, I wan't it to open a new gui specifically windows explorer so that they can search for their file.


Well lucky for you, Sprinkles, I happen to be a novice in Visual Basic, you would do something like this


Visual Basic code
Dim myStream As Stream = Nothing Dim openFileDialog1 As New OpenFileDialog() openFileDialog1.InitialDirectory = "c:\" openFileDialog1.Filter = "Map files (*.map)|*.map|All files (*.*)|*.*" openFileDialog1.FilterIndex = 2 openFileDialog1.RestoreDirectory = True If openFileDialog1.ShowDialog() = System.Windows.Forms.DialogResult.OK Then Try myStream = openFileDialog1.OpenFile() If (myStream IsNot Nothing) Then ' Insert code to read the stream here. End If Catch Ex As Exception MessageBox.Show("Cannot read file from disk. Original error: " & Ex.Message) Finally ' Check this again, since we need to make sure we didn't throw an exception on open. If (myStream IsNot Nothing) Then myStream.Close() End If End Try End If


I don't know what it does but Microsoft said it will work.
...then I got some ap, and shot a big ass lazar at everyone.
    (Edited 2009 Dec 11 at 12:27)     2009 Dec 11 at 11:12
SRAW
Rocket Man

2007 Nov 6 • 2069
601 ₧
why must vb have such long name for the functions
Free Steam Games
    2009 Dec 17 at 04:41
Down Rodeo
Cap'n Moth of the Firehouse

Find the Hole II Participation Medal
2007 Oct 19 • 5258
57,583 ₧
To make it easy, essentially. That's why they have code completion.
Everyone stares when you walk in the room, they stare when you go....
    2009 Dec 17 at 12:10
sprinkles

Chrome Whore
2009 Sep 6 • 2431
10 ₧
I think it's to show you exactly what its doing.

C++ code
string boblee;

VB.net code
Dim boblee As String


They do the same thing, but I guess the c++ one is more confusing?
...then I got some ap, and shot a big ass lazar at everyone.
    2009 Dec 17 at 14:59
SRAW
Rocket Man

2007 Nov 6 • 2069
601 ₧
vc++ 2008 doesnt have code completion, so does anyone know an editor that has that...
Free Steam Games
    2009 Dec 17 at 20:40
Down Rodeo
Cap'n Moth of the Firehouse

Find the Hole II Participation Medal
2007 Oct 19 • 5258
57,583 ₧
I thought it did... there should be a plugin called xcode or something screw it I can't be bothered finding it.
Everyone stares when you walk in the room, they stare when you go....
    2009 Dec 18 at 01:32

Pages: 1, [2]
Forum and design copyright © 2008-2010 SuperJer.com