Jump to content

TriggerHappyUK

Members
  • Posts

    573
  • Joined

Everything posted by TriggerHappyUK

  1. Yeah, that's out test student account.
  2. Just added a message box to test the value of strDN inplace of the debug.print. It outputted the same value as above before crashing with the same error.
  3. Here is where I am now: Private Sub cmdExit_Click() End End Sub Private Sub cmdSubmit_Click() Dim objOU As Object, objUser As Object, objRootDSE As Object Dim strContainer As String, strDNSDomain As String, strPassword As String Dim strDN As String Dim intPwdValue As Integer 'Bind to Active Directory Domain Set objRootDSE = GetObject("LDAP://RootDSE") strDNSDomain = objRootDSE.get("DefaultNamingContext") strContainer = "OU=Domain Users," strPassword = "P@ssw0rd" strContainer = strContainer & strDNSDomain 'Here we force a change of password at next logon intPwdValue = 0 strDN = ("LDAP://cn=" & txtStuNum.Text & "," & strContainer) Debug.Print strDN Set objOU = GetObject(strDN) 'Set objOU = GetObject("LDAP://cn=" & txtStuNum.Text & "," & strContainer) objUser.SetPassword strPassword objUser.Put "PwdLastSet", intPwdValue objUser.SetInfo End Sub When I run it, I get the same error: "Run-time error '2147016656 (80072030)': There is no such object on the server" When I debug, the "Set objOU = GetObject(strDN)" line is highlighted in yellow. This may help, the value of strDN is: LDAP://cn=0007,OU=Domain Users,DC=arnewood,DC=net But the value of objOU has a value of: Nothing
  4. Thanks for the comments... Could you be a bit clearer please. It's been a while since I have done any programming. Chris.
  5. Excellent... Cheers for the help. Chris.
  6. Hi, This is almost exactly what I am looking for. Is there any way that there could be an option to force a password change at next logon? Cheers, Chris.
  7. Hi All, First let me tell you my scenario. I am a technician at a secondary school. We have a medium sized network with AD, running server 2003 and XP clients. I am trying to create a very simple VB6 executable that will reset a students password and force a password change at next logon. I'm no expert at VB but I can work my way around a program. I have designed the very simple form: see attached Here is the code: Private Sub cmdExit_Click() End End Sub Private Sub cmdSubmit_Click() Dim objOU As Object, objUser As Object, objRootDSE As Object Dim strContainer As String, strDNSDomain As String, strPassword As String Dim intPwdValue As Integer 'Bind to Active Directory Domain Set objRootDSE = GetObject("LDAP://RootDSE") strDNSDomain = objRootDSE.get("DefaultNamingContext") strContainer = "OU=Domain Users, " strPassword = "P@ssw0rd" strContainer = strContainer & strDNSDomain 'Here we force a change of password at next logon intPwdValue = 0 Set objOU = GetObject("LDAP://cn=" & txtStuNum.Text & ", " & strContainer) objUser.SetPassword strPassword objUser.Put "PwdLastSet", intPwdValue objUser.SetInfo End Sub When I run it, I enter the student's number in the text box and click submit, then and error is thrown at me. "Run-time error '2147016656 (80072030)': There is no such object on the server" When I debug, the "Set objOU = GetObject("LDAP://cn=" & txtStuNum.Text & ", " & strContainer)" line is highlighted in yellow. Any help to get this working would be greatly appreciated. Cheers for looking, Chris.
  8. You need to create a folder, say on the C: drive, to hold the background image. Then edit the registry key to point to the new BITMAP image. Type: 'regedit' into the run box Browse to: My Computer\HKEY_USERS\.DEFAULT\Control Panel\Desktop Edit the 'Wallpaper' value to the path of the new background. Eg: C:\backgound\image.bmp
  9. For staff we use [first initial].[surname] eg j.bloggs or m.jackson. For students we use their admin numbers eg 10101 or 9976. We have had a few members of staff with the same initial and surname. In these cases we were lucky that they had middle names, so we just added the initial of their middle name to the first name initial. eg jf.kennedy. We have had no problems yet with the students. Chris.
  10. I will post the answers after the deadline. (29.05.09) They should be in these pages anyway. But will post the answers when I can.
  11. Yipee!! First prize to you.
  12. 58 W H was a H for K B Could be: W H was a Hit for K B
  13. Only need 8 now
  14. I got another one: 74 R F is a T P from S: Roger Federer is a Tennis Player from Spain.
  15. I must say a BIG thank you to everyone that has helped. Only 29 to go now! Chris.
  16. 46 The F N of S and G are P and A
  17. Have a go at my quiz http://www.edugeek.net/forums/general-chat/34760-fill-blanks-quiz.html It's addictive. P.S. Congrats
  18. Your right, Catherine Howard was his 5th wife.
  19. Forgot to add the attachment.
  20. Hi All, I'm looking for a little help with a staff quiz running at our school. It's a 'complete the word' type of quiz, I think they call them Ditolids. Here is an example: there are 18 H on a G C = there are 18 Holes on a Golf Course. Any help would be much appreciated. edit: Questions in red have been answered. Chris. 1 The V of the K is in E 2 H is the O of C 3 The V of X in S is 8 P 4 F M was the L S of Q 5 There are 10 E in a D 6 C and A were the S of A and E 7 A is the F L of the A 8 R D was the A of C and the C F 9 The N is the L R in A 10 D C is a N by C D 11 The N P to the S is M 12 The S R of S F is 8 13 R S was the D in the B 14 E R B was the C of T 15 J L C is the D of T C 16 The E S B is the T B in N Y 17 There are 20 F O in a P 18 H D is an E in a N R 19 D B is the A of T D V C 20 There are 28 P on a M B 21 D H is the L S of B 22 O N J was the F S of the F G 23 R the R had a R N 24 C of A was the 1st W of H the E 25 There are 24 C in P G 26 T H won O for P and F G 27 A H was B in A in 1889 28 An A H has 32 T 29 A C was the C of H P and M M 30 The L P in the S S is J 31 There are 7 C in a R 32 There are 22 B in the G of S 33 B is the L C in S A 34 Each P has 15 P in the G of B 35 A H was the D of P 36 The O and the P is a P by E L 37 The A of the B P M is 10 D S 38 There are 4 S in a Y 39 D B is the R N of the I H 40 P P was the B who N G U 41 W A M was the C of T M F 42 A U has 1 W 43 S C is A N for F C 44 H, D and L are the N of D D 45 B and B were the F M 46 The F N of S and G are P and A 47 M M is the R N of J W 48 The G A was a S made by A L 49 The C of the M was J H 50 C D was a V from T 51 R Z is the R N of B D 52 E W is the Q of E 53 P is the C of F 54 M J is the L S of the R S 55 C C was the O N of M A 56 The S of R and J were M and C 57 The B H in the G of P is a R F 58 W H was a H for K B 59 C K is the R N of S 60 A C D was the C of S H 61 The T B in F is the E T 62 If you are B on C D your S S is C 63 I F was the C of J B 64 E B was the C of the F F 65 The M L was P by L D V 66 The 4 E are E, A, F and W 67 There are 13 C in a P of C 68 The A of the W H is 1600 P A 69 There are 13 P in a R L T 70 A was the M N of E P 71 K is the C S for P 72 L V B was the C of the M S 73 a B K is C a J 74 R F is a T P from S 75 There are 2 A of H in a M of W 76 P was the G G of the S 77 J B was P by S C 7 T 78 There are 90 B in the G of B 79 A, P and A were the N of the 3 M 80 The S D is the L D in the W 81 There are 6 B in an O in C
  21. Board, Board edit: too late!!
×
×
  • Create New...