Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Win95 Network (Workgroups?) routines?

Posted on 1998-07-19
4
Medium Priority
?
274 Views
Last Modified: 2010-04-04
How do I use the Windows Network? I mean the Win95 workgroups network. I want to access other
computers. How do I do it?
How do I enter the password for shared folders? Will it be possible to write a program that 'hacks' this
password? It seems possible to me...
0
Comment
Question by:ShadowHawk071998
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 

Accepted Solution

by:
lorenk earned 180 total points
ID: 1358243
Do you mean "how do you programmatically access other machines on the Windows Network?"  If so, then the answer is with the Shell API found in Shell32.dll.

The functions you want are:

SHGetDesktopFolder to get an instance of the desktop
then:

SHGetSpecialFolderLocation to get the instance of the network neighborhood.

-Loren
0
 

Author Comment

by:ShadowHawk071998
ID: 1358244
Okay.
Anyone has more 'concrete' suggestions? So I won't have to hack it down all
myself?
How do I ACTUALLY use these in Delphi? Anyone can give a short example?
0
 

Expert Comment

by:lorenk
ID: 1358245
Here's my code in C++Builder.  The conversion to Delphi should be trivial, but I can do it for you if you like

    LPSHELLFOLDER lpsf = NULL, lpsf2 = NULL;
    LPITEMIDLIST pidl, lpi = NULL;
    LPENUMIDLIST lpe;
 
    SHGetDesktopFolder(&lpsf);

    SHGetSpecialFolderLocation(Handle, CSIDL_NETWORK, &lpi);
    lpsf->BindToObject((LPCITEMIDLIST)lpi, NULL, IID_IShellFolder, (LPVOID *)&lpsf2);
    lpsf2->EnumObjects(Handle, 32 | 64 | 128, &lpe);
    while (S_OK == lpe->Next(1, &lpi, &ulFetched))
    {
        char lpName[MAX_PATH];
        memset(lpName, 0, 256);
        STRRET StrName;
        lpsf->GetDisplayNameOf(lpi, dwFlags, &StrName);
        switch(StrName.uType)
        {
            case STRRET_WSTR:
                WideCharToMultiByte(CP_ACP,0,StrName.pOleStr,-1,lpName,
                    sizeof(lpName),NULL,NULL);
                break;
            case STRRET_OFFSET:
                strcpy(lpName, (LPSTR)lpi+StrName.uOffset);
                break;
            case STRRET_CSTR:
                strcpy(lpName, (LPSTR)StrName.cStr);
                break;
        }

     }

Enjoy!
0
 

Author Comment

by:ShadowHawk071998
ID: 1358246
That is much better :)
I would hugely appriciate having you 'translate' it to delphi if you have the time. Although I 'know' C++ I haven't used it in years. I should start soon, but I'd prefer a pascal example...
Thanks again!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Objective: - This article will help user in how to convert their numeric value become words. How to use 1. You can copy this code in your Unit as function 2. than you can perform your function by type this code The Code   (CODE) The Im…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
Suggested Courses

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question