×
INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Contact US

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Problems with WNetOpenEnum

Problems with WNetOpenEnum

Problems with WNetOpenEnum

(OP)
This may be too general for my 'language based' forum so I hope its ok to post it here as well.

I am using WNETOPENENUM in a function for enumering network resources.
The function has worked fine on my development machine and at least four others (3 XP, 1 95B and 1 98SE), but I am getting problems on some machines, where the function  returns errors, e.g 'command not supported' one one machine (W98 SE ) or 'no network present' on another (W98 SE) in both cases the machines are connected to a P2P network and network access seems to be OK from windows point of view, does anyone have any ideas why this function does not always work. Perhaps some extra windows networking componets are required?

Steve
getting better now thanks!

RE: Problems with WNetOpenEnum

(OP)
A slight mistype there the first error should have been Error 50 'Not supported'. after a lot of googling I came up with this http://support.microsoft.com/kb/q234573/
I suspect that WMNETOPENENUM calls getnetworkparams, and the machine in question may well have IE5 installed (I need to check), can anyone add to this.
I still have to find a cause for the 'no network present' error.
 

Steve
getting better now thanks!

RE: Problems with WNetOpenEnum

MSDN said: in 9X Family Unicode version of this function (WNetOpenEnumW) is supported only with MS layer for Unicode installed...
As far as I know in 9X we can work w/o network logon, but these functions works only after logon (see MSDN)...
May be it helps?..

RE: Problems with WNetOpenEnum

(OP)
Thanks ArkM
As far as I can tell the machine in question (API returns 'no Network' error) is logged onto the network.
'Client for MS networks' is installed and the network login dialog appears at startup if this is cancelled you see the windows login dialog (as normal).

Is MS Layer for Unicode an installable option for 9X?
I will do some googling.

If the function was not being supported at all would you expect to see any meaningful erro codes?

I have since checked the code that uses the API call on the remaining two machines on our network (7 in total) this is the only one where it dosnt work!
The only difference I do know about, is that all the other machines are set-up to use auto-logon via the TweakUI power Toy.

Steve
getting better now thanks!

RE: Problems with WNetOpenEnum

(OP)
Ah I see. My application is written in Borland Delphi, as far as I know all the API functions are 'wrappers' for the OS API.
The language help on WNETOPENENUM (No W postfix version is listed) does not mention the need to install any librarys.
This would be most unusual for a Delphi API call.
In fact it specifical states that the function is Win95 compatable.
Also it dosent explain why the function works Ok on most machines.
(I will ask about the unicows library in the Delphi forum)
 

Steve
getting better now thanks!

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members! Already a Member? Login

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close