In your given sample code you get the creator ID into a variable
called "ifCreator" and then you check a variable called "Creator" in
you "if statement"
> if(Creator == netIFCreatorPPP)
You probably have another variable called Creator somewhere, but you
want to be checking "ifCreator" in this case.
--- Gavin
At 7:00 AM +0000 4/11/00, Palm Developer Forum digest wrote:
>
>Subject: NetLibIFAttach does not work
>From: "Chi Guan" <[EMAIL PROTECTED]>
>Date: Mon, 10 Apr 2000 14:36:00 -0700
>X-Message-Number: 60
>
>Hi, Greg, Thanks you for answering the question. I am sorry to accidently
>delete your message. Hope you can see this message. Every network settting
>are set for PPP default. Actually
> First I call err =
>NetLibIFAttach(AppNetRefnum,netIFCreatorPPP,ifInstance,AppNetTimeout), if
>paased
>Next : for (index = 0; 1; index++)
> {
> err = NetLibIFGet(AppNetRefnum, index, &ifCreator,
>&ifInstance);
> if(Creator == netIFCreatorPPP)
>
>
> break;
> }
> }
>
>Than: err = NetLibIFSettingSet(AppNetRefnum, ifCreator, ifInstance,
>netIFSettingServiceName, &Name, buflen);
>Than err = NetLibOpen(AppNetRefnum, &ifErrs);
>
>All above API calls are passed and have no error,( also, ifErrs = 0);
>
>However, the network opened is not the one I attached, but the old one.
>
>I believe another gentalman, Russell Bulmer, post a message "NetLibOpen -
>PalmOS 3.1 / 3.3 issues". He has the same problem as mine, except, he did
>not attach new one, but try to modify the current setting. (I have try to do
>the same thing but failed). If you take a look of his message, you may
>have clearer idea.
>Thank you.
--
For information on using the Palm Developer Forums, or to unsubscribe, please see
http://www.palm.com/devzone/mailinglists.html