🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.visual.basic
Article #21

Re: delete and rename form with in visual basic(urgent needed)

#21
From: Sparky
Date: Sun, 01 Dec 2002 18:55
92 lines
4461 bytes
Aha!  Now I gettit!

Well, I'd suggest making your life a bit easier, using only one form.  This
is how I'd do it:

On that form, create a function (you could make it public and/or put it in a
module if you like) as follows:

' ----------------------------------------------------
function IsTrial() as boolean

    if "we're running a trial version" then

        msgbox "This functionality is not available in this trial version.
Please upgrade to the full version", vbInformation

    else

        IsTrial = true

    end if

end sub
' ----------------------------------------------------

Now, when a user tries to use functionality (still on that one form) that
you wish to restrict, then put a call in to this funciton.  If it returns
true, then do what ever the functionality is supposed to do.  If not, do
nothing.  Rest assured that this little function will already have let the
user know why nothing else happens.

' ----------------------------------------------------
Private Sub Command1_Click()

    if not IsTrial then

        ' Do the required functionality, safe in the knowledge that if it's
a trial then the user will be informed as such by the IsTrial function.

    end if

end sub
' ----------------------------------------------------

Another option for commandbuttons and menus would be to disable them in
Form_Load if the program is running as a trial version.

--
Please reply to the group so that everyone benefits.

Cheers,

Sparky.
*********************************************


"Maaz" <mabowath52@rogers.com> wrote in message
news:zrsG9.193240$oRV.92742@news04.bloor.is.net.cable.rogers.com...
> what i want to do i s make shareware program.what i want is that in one
form
> it has limited programs and other with full function that i make.so when
> user enter serial # the first form is deleted and second one is
renamed.this
> is what i want.or if u guys have other solutiong on making my program demo
> and shareware please let me know.
> "Devo F" <thud732@yahoo.com> wrote in message
> news:1b85a8c6.0212010951.3a88f594@posting.google.com...
> > "preben nielsen" <prel@post.tele.dk> wrote in message
> news:<3de9eb26$0$237$edfadb0f@dread16.news.tele.dk>...
> > > "Maaz" <mabowath52@rogers.com> skrev i en meddelelse
> > > news:bcIF9.181003$YSz1.88659@news01.bloor.is.net.cable.rogers.com.
> > > ..
> > > > Hello I have create two form in Visual basic.How do i delete the
> > >  1st from
> > > > when i press on button and rename the 2nd from to first one.i
> > >  want program
> > > > to automatically delete form and rename other form to form i
> > >  deleted when
> > > > button is pressed in exe file of the project
> > >
> > > Why ??????? (and then a few more ??????????????)
> > >
> > > If it's because you refer to the for by name in many places then
> > > you are doing it wrong !
> >
> >
> > Until, and unless, we have a clear picture of what your final
> > objective is, it is difficult to come up with a solution.
> >
> > DF
>
>
Technical Details
Message-ID: <asdlvs$1lt$1@news7.svr.pol.co.uk>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed.icl.net!newsfeed.fjserv.net!colt.net!diablo.theplanet.net!news.theplanet.net!not-for-mail
References: <bcIF9.181003$YSz1.88659@news01.bloor.is.net.cable.rogers.com> <3de9eb26$0$237$edfadb0f@dread16.news.tele.dk> <1b85a8c6.0212010951.3a88f594@posting.google.com> <zrsG9.193240$oRV.92742@news04.bloor.is.net.cable.rogers.com>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f51ba,f8c0f9bd56938de7
X-Google-Attributes: gidf51ba,public
X-Google-Thread: fb992,f8c0f9bd56938de7
X-Google-Attributes: gidfb992,public
X-Google-ArrivalTime: 2002-12-01 10:56:08 PST
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-03!sn-xit-01!sn-xit-08!supernews.com!news.tele.dk!news.tele.dk!small.news.tele.dk!newsfeed.icl.net!newsfeed.fjserv.net!colt.net!diablo.theplanet.net!news.theplanet.net!not-for-mail
From: "Sparky" <dopey@yahoo.com>
Newsgroups: comp.lang.visual.basic,dk.edb.programmering.basic.visual-basic
Subject: Re: delete and rename form with in visual basic(urgent needed)
Date: Sun, 1 Dec 2002 18:55:53 -0000
Lines: 94
Message-ID: <asdlvs$1lt$1@news7.svr.pol.co.uk>
References: <bcIF9.181003$YSz1.88659@news01.bloor.is.net.cable.rogers.com> <3de9eb26$0$237$edfadb0f@dread16.news.tele.dk> <1b85a8c6.0212010951.3a88f594@posting.google.com> <zrsG9.193240$oRV.92742@news04.bloor.is.net.cable.rogers.com>
Reply-To: "Sparky" <dopey@yahoo.com>
NNTP-Posting-Host: 81.76.137.133
X-Trace: news7.svr.pol.co.uk 1038768956 1725 81.76.137.133 (1 Dec 2002 18:55:56 GMT)
NNTP-Posting-Date: 1 Dec 2002 18:55:56 GMT
X-Complaints-To: abuse@theplanet.net
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2600.0000
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2600.0000