Active Directory user authentication problem

Hi There I have a piece of code that I am using to authenticate users of 
active directory, is very straightforward, here it is.

	IADsOpenDSObject *pDSO = NULL;

	//this is just a result code

	hr = ADsGetObject(L"LDAP:", IID_IADsOpenDSObject, (void**) &pDSO);

	if (SUCCEEDED(hr))
		IDispatch *pDisp;

		hr = pDSO->OpenDSObject(CComBSTR("LDAP://"),
My problem is that the HRESULT error code returned when someone trys to 
login incorrectly is the same for when an active directory user has the 
flagged "User must change their password next time they log in" set.  So from 
the error code I cant tell whether I should pop up a box allowing them to 
change their password or tell them that they have entered it wrong.  The 
error code returned is -2147023570

any ideas would be greatly appreciated, I've been looking for ages!
wdhough (17)
12/8/2008 4:19:01 PM
vc.mfc 33608 articles. 0 followers. Follow

0 Replies

Similar Articles

[PageSpeed] 45


Similar Artilces:

problem w/seperating e-mail from different accounts
I am currently using outlook 2002 and am having problems seperating e-mail I am receiving. First, I have two different accounts with each receiving e-mail from a different server. Second, I have my rules set up to put e- mail from each account into a seperate folder. The problem is that the program is putting e-mail from both servers into each server's individual folder. Anyone know how to correctly setup the program to seperate the email? Try adding "stop processing more rules" to the end of each of your rules so that only one of the rules gets a chance to act on each par...

Active Tasks in Outlook Today
Is there a way to only display active tasks in Outlook Today ...

Cannot receive e-mail from another user
Lately, someone from the Washington State Dept. of Ecology has had e-mails sent to us sent back to them with this reply: This is a delivery status notification, automatically generated by MTA on Mon, 28 Aug 2006 16:14:16 - 0700 Regarding recipient(s):, Delivery status: Failed. Message could not be delivered to the domain - Error while sending data. MTA response: 550 The original message is included as attachment. What could be the progblem? Is this our (recipient) problem or their (sendor) problem? It could be ...

User changed, no mail working what is with alias ?
Hi, I have changed almost all of a user: name , since then, I can send emails, but not receive some. what funtion does the Alis (exchange general) have? What do I have to do??? What NDR are you recieving back when not able to send to a user? Alias is the same as the user's logon name when you created the Mailbox. -- John Oliver, Jr. MCSE, MCT, CCNA, Exchange MVP Microsoft Certified Partner "balue" <> wrote in message > Hi, I have changed almost all of a user: name , since ...

Problems Using the Sharing Function of Excel
A number of people on different teams on a large project is trying to use the Sharing function of Excel. They have report numerous problems with lost data. Going to the 64,000 row and other problems. One person logged off the of one Excel sheet on one PC and then log on another PC and it indicated that he was still logged on to the file. Numerous reports of not being able to log on because of excessive number of users, etc. These problems and numerous more was encountered and the Sharing was turn-off. Does anyone know of a white paper that identifies/documents these types of problems usin...

send problem in Outlook xp
I have window 98 running outlook XP For a couple of weeks, when I hit the send button, it comes up illegal action" and cuts everything out. Or it will show "can't not send". Sometime the whole messgae will disappear not even save in draft. Any help would be much appreciated. Thanks! LJ ...

Import directory data into Excel 2003
I have over 1000 media files that I would like to extract information from and put into an Excel spreadsheet. Using Explorer, I have defined the fields I would like to see, such as title, duration, comment etc. Now, I need to import this data into Excel. So far, I've not been able to find a way to do this. Can someone offer some suggestions please? Thanks, Nigel -- - Tell your friends to tell their friends - Consultancy, Service, Sales, Networking... - Connect with British Expats World Wide

Internal e-mail activities are adding up
As people begin to use CRM and send internal e-mails regarding a particular entity we are seeing a HUGE number of activities adding up. It would be nice in the future if all internal e-mails regarding the entity would be summed up into one activity. ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most votes. To vote for this suggestion, click the "I Agree" button in the message pane. If you do not see the button, follow this link to open the suggestion in the Microsoft Web-based Newsreader and then click "I ...

Allow users to type a year in date drop-down. (Dex 9.0)
In Dexterity version 9, a drop-down has been added to the date control. In this drop-down, you can click on the year to get focus on it. You can then change the year using the up and down arrows on the keyboard or the buttons next to the year field. What you cannot do is type the year that you would like. In previous version, we used a lookup window to pick a date, but now that this drop-down is there, and we cannot disable it, we have removed our own calendar lookup. ---------------- This post is a suggestion for Microsoft, and Microsoft responds to the suggestions with the most ...

Recurring Service Activities / Items -- CRM 3.0 -- No capability?!
What's the rationale behind *not* having the ability to schedule recurring activities and service items? Have I missed something in workflows or some such? Thanks, ....dgg On May 25, 3:16 pm, David G <David> wrote: > What's the rationale behind *not* having the ability to schedule recurring > activities and service items? > > Have I missed something in workflows or some such? > > Thanks, > > ...dgg Hi David, Has anyone responded to your question? We are having the same issue and I'm hoping there is a solution avail...

Excel Macro Clipboard Problem
I am trying to copy data from a web page table to an Excel worksheet using a macro. I am doing this be opening the html file, copying the data, and closing the html file. When I close it, I am asked if I want to keep the clipboard contents (I do not). I have to select No manually while the macro runs. How can prevent this? Application.DisplayAlerts = false -- HTH - -Frank Isaacs Dolphin Technology Corp. "Glenn H" <> wrote in message news:00c701c3c978$cc7a2000$a301280a@phx.gbl... > I am trying to copy data from a web page tabl...

Journal Entry Batch Posting by another User
Hi, Is there a way in Dynamics GP to setup Journal Entry Posting so that the User(User1) that creates a batch cannot post their own batches. Then another User(User2) would post their batches. Yet User1 would post User2's batches. Any thoughts or ideas would be welcome. Thank you, Jon I initailly thought about turning on Batch approvals but it doesn't seem to apply here since you are just looking for a check to make sure someone else checks a batch. I might look in your SY00500 Table (which is your batch information) at the different fields. I am looking at one and it has a fi...

Create User Access
I want a user to be able to create users, mailbox and contacts on the server and nothing else. Waht groups should this user be member of? Elplz You'll probably want to make a custom set of permissions. Start with making them an Exchange View Only Administrator. Then apply permissions to the dbs or storage groups that you want them to be able to create mailboxes. Then use the AD delegation of control wizard to give them the permissions they need in AD. Nue "WILDPACKET" <> wrote in message news:00D12AC4-CDCB-4974-8E6B-509DB5C81188...

problem with OnEraseBkgnd
Hi, I am trying to perform custom drawing to a CStatic control. The problem I am experiencing is in OnEraseBkgnd. When I resize my window, that window in return resizes the controls on it... one of which is my own class, derived of a CStatic, which catches both OnPaint and OnEraseBkgnd. In OnEraseBkgnd, it seems I have tried everything to get it to actually draw to the static control. It seemed that this would be a relatively simple process. After pulling out excessive amounts of hair, I checked for sample code in MSDN. I found an example that called GetClipBox on the CDC pas...

User has two user records in CRM
This is a bit stupid... One of our customers have been running their CRM 3 installation for quite some time by themselvs. Not really knowing what they have been doing. Now they asked us to help with upgrade to CRM 4 That worked OK just had some rights problems in the SQL Server. Now the funny thing is that for some unknown reason they have one AD user with to users in CRM. One is disabled and on is active. The result is that the user gets error: "Invalid User Authorization" . Trace says "User does not exsist in CRM" Now I have tried to add the user to the UserGroup...

SDK install problem
I tried to install the Business Portal SDK on my computer, but it tells me that Business Portal isn't installed. Do I need to install the SDK on the server that has Business Portal 2.5 installed or can I install it on my laptop that is running Windows XP Pro. Seems silly I would need to install VS.NET on a Server just to get the SDK samples. Note: I don't have Great Plains installed on my workstation. Is this required? You need to install the Business Portal SDK onto a machine that has Business Portal installed. This system will also need to have Visual Studio .NET 2003 ...

Activity views 09-26-05
Folks When viewing the activities on an account or quote, there appears to be no obvious way to include the date of the activity in the view so it is difficult to determine when the activity was done - resulting in us having to open each and every activity to find the relevant one - and this is time consuming. Any ideas? Regards Gavin The current release of Microsoft CRM does not allow you to customize the activity views at least in a supported fashion. If you scan the archives of this group at for activity view you will find some unsupported methods. Microsoft CR...

Notified Office is Not Activated, but it is Activated
When my boss opens any of his Office 2007 products it notifies him that his copy of office is not activated. It has been activated and when I check it through Options it shows that it is activated, but the dialogue pops up each time the programs are opened. I have used the FixIt from KB 919895 to delete the Opa12.dat file which fixed a communications error in activatation, but the product still doesn't think it is properly activated when it is. ...

Outlook 2003 link problem
When I click on a link in my inbox, I receive the following error: "This operation has been cancelled due to restrictions in effect on the computer. Please contact your system administrator." I have checked my security settings in IE and locally, but cannot find anything that would restrict access. Also, I tried using the fix suggestions for this problem related to outlook 2002, KB article 310049. Any suggestions would be welcome. ...

Problem printing JPEGs in reports
I have a database built from scratch in Access 2007 that includes an attachment field which is used to store JPEG photos of people's faces that are printed onto ID cards. It has been working perfectly until recently when the photos get distorted (they look almost as though they have gone into 4-bit colour mode with lots of dithering). When you view the report in 'Report View' the picture looks perfect, but when you go to 'Print Preview' the distortion occurs. It is nothing to do with the images themselves, as ones that have printed perfectly before are now distorted....

Email to Activity in queue
Hi, I have created a queue and I don't get any email activity from incoming mail. I have this configuration: - CRM Server: CRM 3 (CRMSERVER) - SQL Server: SQL 2000 sp4 (SQLSERVER) - Exchange Server: Exchange 2003 sp2 Cluster environment (EXCCLU1, EXCCLU2). I have installed the CRM-Email Router in both nodes ( And I have created the queue in two steps: - Step 1: AD Account with Exchange Mailbox o SELF Allow “Associated external account” o CRMEmailEnabled (Custom Attribute...

Cannot log off users in GP 7.5
For some reason, even when I restart the server, when I go to the login screen, it shows 2 out of 4 users logged in. How can a get these users off? I tried to restart the whole server but i get the same message. Thanks! David Delete the user activity: Quickest way to do this is go to SQL Query Analzyer - Select the DYNAMICS database and type the following command: delete ACTIVITY Make sure you do not have any user currently using GP otherwise they will lose the connection to GP as well. Regards James "David Chang" <> wrote in ...

Comments problem
I've created a number of comments. When I position the comments where I want them, they only reflect their positions on "Show" or "Edit" comment. All the comments default to the same relationship to the cells when you pass over them. This is a problem because I've also used data vaildation (with lists) on these cells and you can't display the comment with the list pulled down at the same time because the comments are tool close to the validated cell. Thanks in adavance. The comment usually appears to the right of the cell, and should still allow you to see t...

Set Default View to Active Accounts
How do I set the default view to be Active Accounts for all users? I thought I had set it by going to Settings>Customizations>Customize Entities>Account>Forms&Views>Active Accounts>More Actions>Set Default. I logged out and logged back in and the default view was still set to My Active Accounts. Please Help. -- TC I hope you published the entity after making the change. Try an iisreset... Sam _______________ Inogic Innovative Logic Innovative solutions for your SME ERP/CRM products E-mail: Web: -------------------------- &qu...

The value become wrong when get value by using AppleScript while other worksheet is active.
Version: 2008 Operating System: Mac OS X 10.5 (Leopard) Processor: Intel I just want to send a bug report. Summary: The value become wrong when get value by using AppleScript while other worksheet is active. Description: 1. Create an AppleScript file with below script. tell application "Microsoft Excel" activate set OriginalWorkbook to workbook "Workbook1" set OriginalData to string value of column 1 of row 1 of worksheet 1 of OriginalWorkbook end tell 2. Launch Excel 2008 and create a Workbook called "Workbook1". 3. Enter time data "11...