Hi Ralph, You'll have to get the profile, make a copy of the settings, delete the profile, and then add it back with your changes.
Painful, but it mostly works. I have had no end of troubles trying to switch services programmatically. There was an unsupported API published by Palm some time ago (NetPreferencesAPI). This is no longer available because it doesn't work that well and works differently in different OSes. The crux of the problem with both of these methods (CncXXX, or NetPreferencesAPI) was that after you programmatically changed the settings, things would look ok until you actually tried to dial up your new service. I ran into (what I thought were) several different behaviors depending on the OS. The number you tried to dial would be corrupted and/or the pulseDial setting would not work, etc. After writing some code gymnastics where I would save some settings, switch services and replace some settings, things seemed to work.... I thought I was fine until some additional testing was done on our product that tries to change settings programmatically. Finally (like yesterday), I installed a patch for the MdmDial function to see what was getting passed down by the Network to be dialed (other evidence led us to believe the number was messed up as we would hear an extra tone during dialing (which was usually a 6)). Lo' and behold, there were 8 extra characters preceding the actual number to be dialed getting passed into MdmDial!! These extra characters seem to always be there, they appear to be constant for each device, but whether or not they contain a character that messes up dialing seems to depend on the particular device type (m505 was ok, but m500 wasn't, IIIC ok, but Clie not, etc.). Some devices just have non-printable garbage, and so dial correctly anyway, while others contain a 6 that definitely messes things up. It is my speculation that there is a disconnect between the NetLib and its preferences database so that one of these entities is misinterpreting the structure used to store prefs, etc. and this causes an extra 8 bytes to be prepended to the phone number. Anyway, I simply remove those 8 characters, pass the fixed number to the old trap, and now we seem to be able to change services on all devices with proper results. I'm not happy with this hack, but what can you do when the OS is messed up? This has been a painful process because the NetPreferencesAPI is not supported by Palm and they would not really acknowledge that it didn't work properly (they did warn us that the code was not tested and not supported, so I'm not really complaining about their support as I did get more than I expected I would from DTS on this). Hope this info helps. Be warned, this stuff is at least partially broken, but we seem to be working now. Kevin -----Original Message----- From: Ralph Krausse [mailto:[EMAIL PROTECTED]] Sent: Friday, January 25, 2002 4:19 PM To: Palm Developer Forum Subject: CncGetProfileInfo but I need CncSetProfileInfo I can get the information with CncGetProfileInfo but I am looking for a way to set that information. Can that be done? Thanks Ralph Krausse -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/ -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/
