PC Review


Reply
 
 
si_owen
Guest
Posts: n/a
 
      18th Oct 2006
i am used to vb6 nad now im using .net framework all the simple lines
of code have vanisehed!!!

for example in vb6 to move from one form to another the following code,
behind a command button, was magic:

form1.show
form2.hide

now how the hell do u recreate that kind of simple command button
navigation in .net????

any ideas, i have looked at breadcrumbs and tree style menus but not
what i want.

 
Reply With Quote
 
 
 
 
Norman Chong
Guest
Posts: n/a
 
      18th Oct 2006

si_owen schrieb:

> i am used to vb6 nad now im using .net framework all the simple lines
> of code have vanisehed!!!
>
> for example in vb6 to move from one form to another the following code,
> behind a command button, was magic:
>
> form1.show
> form2.hide
>
> now how the hell do u recreate that kind of simple command button
> navigation in .net????
>
> any ideas, i have looked at breadcrumbs and tree style menus but not
> what i want.


The attribute is called ' visible ' - I think the usage is obvious ;-)

But what do you want to do? I wizard-like application where you have a
'next' and 'previous' button? In this case I would recommend Groupboxes
for each "page" instead of forms. When clicking on the buttons, you can
then just change the visibility of the boxes. (You could do this with
forms too, but then you would always have lots of forms in background;
and it will be slower when clicking on next, because the whole new form
must be loaded)

By the way: Show won't work - This will load the form

 
Reply With Quote
 
si_owen
Guest
Posts: n/a
 
      18th Oct 2006
i know this wont work in .net im saying it was that simple in vb6!

and as i am creating a web site not standard windows form it's not that
obvious.

finally found it response.redirect()

 
Reply With Quote
 
Norman Chong
Guest
Posts: n/a
 
      18th Oct 2006

si_owen schrieb:

>
> and as i am creating a web site not standard windows form it's not that
> obvious.
>


Maybe you should have written this before...??

 
Reply With Quote
 
Phill W.
Guest
Posts: n/a
 
      18th Oct 2006
si_owen wrote:
> i am used to vb6 nad now im using .net framework all the simple lines
> of code have vanisehed!!!


> now how the hell do u recreate that kind of simple command button
> navigation in .net????


Welcome to the Brave .New World.

Visual Basic no longer keeps track of your Forms like VB "proper" did,
so you have to create instances of them and call methods on these
instances; well, they /are/ Classes, after all.

Dim f2 as New Form2
f2.Show()

HTH,
Phill W.
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off



Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:09 PM.