-2

Ok so what I am trying to do is create a program that will do this:

Text Box 1: ASDFGHJK Text Box 2: ZXCVBNMO Result Text Box: AZSXDCFVGBHNJMKO

In a windows application using text boxes and buttons. Can somewhere give me a starting point on this? I don't even know how to research how to do this. My online teacher sucks so any help is appreciated. I am supposed to make this program in a struct and in a class. If you could help me figure out the difference, that would be awesome too! TIA

1 Answers1

0

It's been 11 days since you posted this question so I'm hoping you did get more answers from your teacher. If not, I can't do your homework for you but I can give you some hints.

The process you described above is "string concatenation" (a String is a variable with characters in it)

You tagged your question with windows-applications and basic so I assume you're using Visual Studio to write a VB.NET Windows Forms Application

Here's an example of concatenation

' Letters ("string" variables)
Dim a = "abc"
Dim b = "def"
Dim c = a & b ' concatenation, c = "abcdef"

The other aspects you mentioned were struct and class. Structures and classes are two different ways to make complex variables, where a variable can have multiple properties. Do searches on these terms for more information (e.g. "vb.net strucure class"). For example, I could create a Structure that has properties corresponding to the three variables listed above like this:

Public Structure ExampleStructure
    Public a As String
    Public b As String
    Public c As String
End Structure

Then, to use it in my concatenation example it would look like:

Dim s As New ExampleStructure
s.a = "abc"
s.b = "def"
s.c = s.a & s.b ' concatenation, s.c = "abcdef"

As far as getting started with a Windows Forms application with a textbox and a button, check out http://www.tutorialspoint.com/vb.net/vb.net_textbox.htm

user2638401
  • 401
  • 2
  • 4