473,493 Members | 2,229 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Help With very basic operation of next button

1 New Member
Hi there,
Please be kind, I have seen some posts where you tell people off for asking without investigating, Im sure most have, anyway I have.

Ive only been doin VB 2008 for 7 weeks, and have been told at college to make 5 statges/wizards of login forms, Ive done the design easy...

What I need help with is the next and back button,
after many,many,many,many hours of searchin I worked out next botton for a button in response to a list of checkboxes..

Expand|Select|Wrap|Line Numbers
  1. Private Sub gobttn_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles gobttn.Click
  2.         If exist_rad_bttn.Checked Then
  3.             Form3.Visible = True
  4.             Me.Hide()
  5.         End If
  6.         If nucus_rad_bttn.Checked Then
  7.             Form2.Visible = True
  8.             Me.Hide()
  9.         End If
  10.     End Sub
This works..not sure if its good VB language but anyway, constantly being told I am doin 10 lines instead of 2

I cant think of a way to code a button to goto the next form with, the button has nothing linked to it. I want to load the next or previous form, while closing the current form.

Do I use dim, do I use elsewith, I am trying every variation, please anyone, help me, I can do some cool things, but this basic operation has got me stumped, and guess as its sooooooo simple there is nothing about it anywhere.

Lastly it needs to be in VB.net

Many Many thanks for your time, and if anyone helps me.
Dec 2 '08 #1
3 1167
Frinavale
9,735 Recognized Expert Moderator Expert
@ellishnoo
This only happens if it is plainly obvious that the person has not attempted to put any effort into their project. It is quite obvious that you have tried the problem so you should have no worries about that sort of response.

A good place to start your research on a control is the MSDN Library. There you'll find articles and how-tos on all .NET controls including the Wizard Control.

@ellishnoo
You are doing too much work here.
You should have set up Steps within your ASPX code for the Wizard control...you do not need to have multiple forms in the page. The Wizard control will navigate through the steps you have set up with very little code.
Dec 2 '08 #2
Plater
7,872 Recognized Expert Expert
This is a windows application yes?
You might consider designing all your forms (which you have done)
And instead of creating a Form2 and a Form3 and a Form4 (etc)
You would make an array of their base class Form.
You can add Form2 and Form3 (and others) to your Form array.

Then in your forward backward button code, you could tell it to show/hide the form from its index in that array.
That may sound confusing, but maybe I can explain better with some psuedo code:

Forward button:
if some checkbox THEN make myforms(3) be active
if some other checkbox THEN make myforms(4) be active

BackButton:
last form index was 2
make myforms(2) be active
Dec 2 '08 #3
Frinavale
9,735 Recognized Expert Moderator Expert
@Plater
>>blush<< I never considered this :P

Is there no "Wizard" control for windows applications?
Dec 2 '08 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

4
5957
by: KellyH | last post by:
Hi, I hope someone can point me in the right direction. I'll get it out of the way: Yes, I am a college student. No, I am not looking for anyone to do my homework, just looking for help. I have...
13
6038
by: Mike | last post by:
Normally scheduling a job is a very elementary operation but for some hidden reason I've been unable to schedule a job which runs on a 28 day cycle, even though I have at least 16 other jobs...
15
2060
by: DavidS | last post by:
Have Visual Studio.NET installed on MS 2000 Professional OS laptop. No issue ever with web development and SQL connections. Purchased new laptop with XP Professional SP2!!!!!!!! & Visual...
13
4295
by: Joner | last post by:
Hello, I'm having trouble with a little programme of mine where I connect to an access database. It seems to connect fine, and disconnect fine, but then after it won't reconnect, I get the error...
0
7119
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6989
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7157
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6873
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7367
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5453
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4889
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4579
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
1
644
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.