|
How can i get the values in textbox to class
Please help me
the code is that:
Public Class islemler
.
.
Public Sub Calculate()
degisken2 = CDbl(textbox1.Text)
.
.
.
|
|
|
|
|
Get the values out of the textboxes first, then pass those to your class code:
Private Sub Button1_Click(blah, blah) Handles Button1.Click
Dim x As Double = Double.Parse(TextBox1.Text)
Result = Calcuate(x)
Public Class islemler
Public Function Calculate(ByVal d As Double) As Double
... do your calculation and return the result...
End Function
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi all
Any one knows about a good converter to convert Vb6 to Vb 2005.
Appricated if you can provide a URL to download.
/Prash
|
|
|
|
|
There is only one and it's built right into VB.NET. All you have to do is open the old .VBP file for the conversion to launch. But, it's most definitely not perfect! There's just so many differences between VB6 and VB.NET, that the resulting code looks like something Dr. Frankenstein threw together. Your best option is to rewrite the app from scratch. But the conversion is at a least a decent starting point if you want to rewrite the app in stages.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
I have an old VB6 legacy app that I'm maintaining at a client. Basically a client app connects to a server app and then receives data. The client connects when the app is loaded and stays connected until the program closes.
I have to add some code to this app that will get the client app to reconnect to the server app if the connection is broken. If the connection is broken, or if it fails to connect, I start a timer that tries to connect every minute or so.
Here's the problem. When I connect on Page Load it connects fine. If the inital connect does'nt work and I try connect later on with the timer the connection gets stuck in state 6 (which is connecting) and it never actually connects.
Here's the code I use to connect on both page load and in the timer:
Private Sub ConnectToEventPub()
wsReader.remotehost = strRemoteHost
wsReader.RemotePort = 100
wsReader.Connect
While wsReader.State = 3 Or wsReader.State = 4 Or wsReader.State = 5 Or wsReader.State = 6
DoEvents 'wait for connection to complete
Wend
If wsReader.State = 7 Then 'if connected send info
wsReader.SendData (aService & "|" & aAbandonTime)
bISWinsockConnected = True
tmrReconnect.Enabled = False
Else
bISWinsockConnected = False
tmrReconnect.Enabled = True
End If
End Sub
The Sub works fine when called from Page Load but not when called from the timer.
Any ideas? I'm stumped and sitting in a freezing server room.
Capital Punishment means never having to say "you again?"
As easy as 3.141592653589793238462643383279502884197169
|
|
|
|
|
i want to make an asp.net page which will be called by a vb.net application witin a pc. this application will send the username and password to this asp.net page and retrieve information (true or false). if the username exists witin the database of the website (server) then the function will throw a true. how can i make this happen without any asp.net page opened?
Adrian De Battista: .Net Programmer, Java Programmer and Web Designer.
|
|
|
|
|
You don't want a web site, you want a web service. A web service is called over the web, can return a value to your code, and has no pages.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
how to make a web service pls?? can i make one??
Adrian De Battista: .Net Programmer, Java Programmer and Web Designer.
|
|
|
|
|
This[^] is the definitive site on the subject.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
This[^] should tell you a bit more about what web services are and point you in the right direction.
|
|
|
|
|
Hi, is there any good free, documention on visual BASIC express edition? I am doing an A level, and I want to get the programming out the way as soon as possible. OR, are there any free podcasts I could get that I could run on my IPOD(The original)? Thanks for any suggestions!
|
|
|
|
|
Do these use the same langauge? I ask because I was typing into my school progam ( visual BASIC 6 ) Form1.Print "Hello" and it worked then I typed the same thing into my express edition version, and it didn't work, why is this?
|
|
|
|
|
There is no such thing as visual basic express. Only Visual Studio express for VB.NET
Visual basic 6 is not 100% compatible with Visual Basic.NET
--------------------------------------------------------
My portfolio & development blog
Q:What does the derived class in C# tell to it's parent?
A:All your base are belong to us!
|
|
|
|
|
Sorry, it says (On the top of the IDE) Microsoft Visual basic 2005 express edition. Can you tell me what the actual code should be for the VB.Net express edition?
|
|
|
|
|
VB6 is an old ( out dated and no longer supported ) non OO language that Microsoft has pretty much discarded. VB.NET Express is a free version of VB.NET 2005, which is a new, OO language that happens to use VB syntax. They are almost completely different from one another, your VB6 program will not work in VB.NET. Tell your school that VB6 is rubbish, it's dead, and VB.NET Express Edition is free. That's what they should be teaching you.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Ok, does that mean, that the express edition I have is up to date and is the right one. I need to get books etc. for visual BASIC 2005?
|
|
|
|
|
Yes. VB.NEt 2005 is the one to learn, between that and VB6. So, get some books, check out the information online, and remember you can ask any question you like here, but you'll do better if you try to do stuff and ask when you get stuck.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
hi,
I am creating a .txt file using .net.
The name of the file will be the selected item in a list box.
eg if i select "name" in the list box then the fule name will be name.txt.
My problem is if i select "name/sa" in my list box, it says path does not exist as it does not take it as one name.
it takes name as a filder name and sa as a file name.
how can i make the "/" to be part of the name?
|
|
|
|
|
Rigard wrote: how can i make the "/" to be part of the name?
Not sure, but perhaps you can use Linux ?
/ is NEVER part of a filename, it always denotes a path. If you're taking free text, you need to not accept this value, or the others that are unacceptable in a filename ( rename a file in explorer to that, and you'll get a list from Windows ).
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
By default, in all Windows versions, the "/" character is reserved for command line parameter switches and cannot be used in path names:
FORMAT A: /S
The "\" character is reserved for file system path spec's and also cannot be used in a filename.
<div class="ForumSig"><font color="Blue">Dave Kreskowiak
Microsoft MVP - Visual Basic</font>
</div>
|
|
|
|
|
Hi everyone,
In VS2003 we have ASP.NET Web Application on Visual Basic projects but i cant see it on VS2005
does it exist on vs2005 or no.
Thanks
|
|
|
|
|
File/NEw/Web site. You don't need a sln file anymore, you can create a website just by pointing to the directory it's in.
ASP.NET 2.0 is very different from 1.1.
Christian Graus - Microsoft MVP - C++
Metal Musings - Rex and my new metal blog
|
|
|
|
|
Hi Christian,
Please can you say one thing this different is also on classes and I need to learning a new things
Thanks
|
|
|
|
|
hi,
how to print a form including all its controls.
i have to create a document in VB.Net.i have used ritch texbox and and i placed labels and textboxes in the ritch textbox.all the labels and textbox values are taken from the database.then it looks like a document.
i have to print this document.can anybody help u.
|
|
|
|
|