Go Back   nV News Forums > Software Forums > Software Development

Newegg Daily Deals

Reply
 
Thread Tools
Old 01-17-07, 08:48 AM   #1
Sycario
Registered User
 
Join Date: Nov 2006
Location: St. Louis, MO
Posts: 363
Send a message via AIM to Sycario
Default .NET forms

I've been writing web apps with VB.net for almost 2 years but now I am writing an installer for our app. What I need it to do is load 1 form and get all settings it needs for choosing the next form before using the one specified. It will have to automatically go to next form without a prompt or anything. I read in the XML and it sets a mode (install or update). Based on that I need to either load the install form or the update form. I can't figure out how to do this. I know the xml part but this is my first time working with forms. Is there an easier way to do this?

Thanks
__________________

Comp Specs:
Intel Q9650 @ 3.95Ghz
Asus Rampage Extreme
2x2GB Mushkin DDR3-1600 @ 6-6-6-17
eVGA GTX 280 SSC
BFG ES-800 PSU
Sycario is offline   Reply With Quote
Old 01-17-07, 08:54 AM   #2
superklye
 
Join Date: Jul 2004
Location: MKE
Posts: 13,629
Default Re: .NET forms

So wait...are they inputting data that needs to go from one form to another (i.e. username, password, etc) or are they two separate forms using the same XML data or both?

You can either use the querystring or use the POST function of an HTML form in order to pass variables such as usernames between two pages. Querystring isn't recommended for sending sensitive data because you can see them in the address bar.

Is that what you were talking about, or did I completely misunderstand?
superklye is offline   Reply With Quote
Old 01-17-07, 09:11 AM   #3
Sycario
Registered User
 
Join Date: Nov 2006
Location: St. Louis, MO
Posts: 363
Send a message via AIM to Sycario
Default Re: .NET forms

This is for a program, not a web app. I need it to go to either the form for updating or the form for installing. Basically I need to get the mode from the xml before going to the correct form. I was thinking that I need a form to load and get the info before going to where it needs to go. I am not sure if this is the correct way to do it though. The form it will first load should automatically go to the next form. The first form should have no prompt of any kind, I was just going to use it for deciding which form to go to next.
__________________

Comp Specs:
Intel Q9650 @ 3.95Ghz
Asus Rampage Extreme
2x2GB Mushkin DDR3-1600 @ 6-6-6-17
eVGA GTX 280 SSC
BFG ES-800 PSU
Sycario is offline   Reply With Quote
Old 01-17-07, 09:15 AM   #4
superklye
 
Join Date: Jul 2004
Location: MKE
Posts: 13,629
Default Re: .NET forms

Oh...I don't know much about non-web programming. Sorry dude.
superklye is offline   Reply With Quote
Old 01-17-07, 10:39 AM   #5
Greasy
1337 Noob
 
Greasy's Avatar
 
Join Date: Aug 2004
Location: Charlotte, NC
Posts: 372
Default Re: .NET forms

Why not just use the built in installer by creating a depolyement package?
Greasy is offline   Reply With Quote
Old 01-17-07, 11:00 AM   #6
Monolyth
Meow Mix Kills
 
Monolyth's Avatar
 
Join Date: Aug 2002
Location: END OF DAYS
Posts: 1,228
Default Re: .NET forms

Quote:
Originally Posted by Greasy
Why not just use the built in installer by creating a depolyement package?
I have to agree with this, is there any particular reason you require the XML? Building a deployment package can update if the application is already installed install if need be.
__________________
Gaming 5.0
Asus R4 Extreme | Core i7 3930K @ 4.8Ghz Corsair H100 | 16GB G.Skill@1866Mhz | EVGA GTX TITAN Superclocked | Sammy 40" LCD
Asus Essence One | OCZ Revo 3 120GB, Revo 3 X2 240GB | HSPC Tech Station | Corsair HX1200 | Windows 8.1 Pro


Storage 2.0
Gigabyte Z68XP-UD3-iSSD | Core i7 2600K @ 4.5Ghz NH-D14 | 16GB G.Skill@1600Mhz | Areca 1880ix-16 RAID HBA
Temp Storage - 1.8TB (4x450GB Hitachi 15k RPM SAS) | 18TB (12x3TB Hitachi RAID10) | HSPC Tech Station | Corsair HX620 | Windows 7 x64
Monolyth is offline   Reply With Quote
Old 01-17-07, 12:39 PM   #7
Head_slinger
DEP Hater :)
 
Head_slinger's Avatar
 
Join Date: Jul 2002
Location: Newcastle, UK
Posts: 277
Send a message via ICQ to Head_slinger
Default Re: .NET forms

Yo,

Deployment packages are only really for deploying code you have wrote in VS, they are limited when deploying other stuff, not sure what he is doing.

To open new Forms do this.

Create a new form object (right click project -> Add -> WindowsForm)
Give it a name (i will call it TestForm).

Then to open that dialog simply:

//Create a new instance of the form
TestForm myForm = new TestForm();

//Call the ShowDialog method
myForm.ShowDialog();

You can pass variables etc. to the new form by creating a custom constructor.

Hope this helps!

EDIT:

I just re-read your post, do you want to process the xml file before showing the user the Form. If this is the case simply put the code for reading in the xml in the constructor for the main form, do your processing and customise the form as appropriate.
__________________
AMD Athlon 64 3500+
1gb Corsair XMS3200C2PT
Leadtek 6800GT
Audigy 2
ASUS A8V

Windows XP Prof./SuSe 8.2
Head_slinger is offline   Reply With Quote
Old 01-17-07, 01:28 PM   #8
Sycario
Registered User
 
Join Date: Nov 2006
Location: St. Louis, MO
Posts: 363
Send a message via AIM to Sycario
Default Re: .NET forms

The program does alot more than just install or patch. I don't know much about the deployment but this is .net 1.1

The patcher executes alot of sql scripts to update the databases. Here is the code I used to make it work:

Code:
        Dim NextForm As Form
        If LCase(SetupMode) = "patch" Then
            NextForm = New MainPatchForm
        ElseIf LCase(SetupMode) = "install" Then
            NextForm = New MainInstallForm
        End If
        NextForm.Show()
__________________

Comp Specs:
Intel Q9650 @ 3.95Ghz
Asus Rampage Extreme
2x2GB Mushkin DDR3-1600 @ 6-6-6-17
eVGA GTX 280 SSC
BFG ES-800 PSU
Sycario is offline   Reply With Quote

Reply


Thread Tools

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
Forum Jump


All times are GMT -5. The time now is 09:18 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.