Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Program no longer work on Excel 2003

Hi, I've been running this VBA program on Excel 2002 for quite some tim
until I've upgraded one of my computers to Excel 2003 and the progra
would generate an error:

Compile Error:
Can't find project or library.

May I know how do I go about solving this problem? Thanks!

Here's the code I use.

---
Sub OkBtn_Click()
Dim b As Integer
Dim uid As String ' a = userid
Dim pwd As String ' c = password

uid = UserNameTB.Value
pwd = PasswordTB.Value

Sheets("EmpList").Select
For b = 2 To 100
Cells(b, 2).Select
If ActiveCell.Value = uid Then
If ActiveCell.Offset(0, 1).Value = pwd Then
chkGrp
Else
MsgBox ("Invalid Password")
Unload Me
End If
Else:
End If
ActiveCell.Offset(1, 0).Select
Next b
Cells(1, 1).Select
End Sub

Sub chkGrp()

Sheets("EmpList").Activate
With TimesheetEntry.TSENameCB
For Row = 7 To 106
TimesheetEntry.TSENameCB.AddIte
Sheets("EmpList").Cells(Row, 2)
Next Row
End With

If ActiveCell.Offset(0, 2).Value = "N" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
TimesheetEntry.Show
ElseIf ActiveCell.Offset(0, 2).Value = "A" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
LoginOption.Show
End If
End Sub
---

Thanks

--
Message posted from http://www.ExcelForum.com

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 8
Default Program no longer work on Excel 2003

Maxfire;

It seems to me that one of the references in VBA is not longer available or
valid.
I think the first is the case.

Check that in the VBE editor in :

Tools | References

Check for a checkmark for the desired project or library in the available
references dialogbox.

Mark.

--
More Excel ? www.rosenkrantz.nl or
--------------------------------------------------------------------



"maxifire " wrote in message
...
Hi, I've been running this VBA program on Excel 2002 for quite some time
until I've upgraded one of my computers to Excel 2003 and the program
would generate an error:

Compile Error:
Can't find project or library.

May I know how do I go about solving this problem? Thanks!

Here's the code I use.

---
Sub OkBtn_Click()
Dim b As Integer
Dim uid As String ' a = userid
Dim pwd As String ' c = password

uid = UserNameTB.Value
pwd = PasswordTB.Value

Sheets("EmpList").Select
For b = 2 To 100
Cells(b, 2).Select
If ActiveCell.Value = uid Then
If ActiveCell.Offset(0, 1).Value = pwd Then
chkGrp
Else
MsgBox ("Invalid Password")
Unload Me
End If
Else:
End If
ActiveCell.Offset(1, 0).Select
Next b
Cells(1, 1).Select
End Sub

Sub chkGrp()

Sheets("EmpList").Activate
With TimesheetEntry.TSENameCB
For Row = 7 To 106
TimesheetEntry.TSENameCB.AddItem
Sheets("EmpList").Cells(Row, 2)
Next Row
End With

If ActiveCell.Offset(0, 2).Value = "N" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
TimesheetEntry.Show
ElseIf ActiveCell.Offset(0, 2).Value = "A" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
LoginOption.Show
End If
End Sub
---

Thanks!


---
Message posted from
http://www.ExcelForum.com/



  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Program no longer work on Excel 2003

Hi!

Sorry for the late reply. That's what I did but it seems like MS Offic
Web Components is missing. I tried downloading and reinstalling th
component from microsoft.com but it doesn't seem to help.

Could there be any change in the way of coding in Excel 2003?


Rgds

Mark Rosenkrantz wrote:
*Maxfire;

It seems to me that one of the references in VBA is not longe
available or
valid.
I think the first is the case.

Check that in the VBE editor in :

Tools | References

Check for a checkmark for the desired project or library in th
available
references dialogbox.

Mark.

--
More Excel ? www.rosenkrantz.nl or
--------------------------------------------------------------------



"maxifire " wrote i
message
...
Hi, I've been running this VBA program on Excel 2002 for quite som

time
until I've upgraded one of my computers to Excel 2003 and th

program
would generate an error:

Compile Error:
Can't find project or library.

May I know how do I go about solving this problem? Thanks!

Here's the code I use.

---
Sub OkBtn_Click()
Dim b As Integer
Dim uid As String ' a = userid
Dim pwd As String ' c = password

uid = UserNameTB.Value
pwd = PasswordTB.Value

Sheets("EmpList").Select
For b = 2 To 100
Cells(b, 2).Select
If ActiveCell.Value = uid Then
If ActiveCell.Offset(0, 1).Value = pwd Then
chkGrp
Else
MsgBox ("Invalid Password")
Unload Me
End If
Else:
End If
ActiveCell.Offset(1, 0).Select
Next b
Cells(1, 1).Select
End Sub

Sub chkGrp()

Sheets("EmpList").Activate
With TimesheetEntry.TSENameCB
For Row = 7 To 106
TimesheetEntry.TSENameCB.AddItem
Sheets("EmpList").Cells(Row, 2)
Next Row
End With

If ActiveCell.Offset(0, 2).Value = "N" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
TimesheetEntry.Show
ElseIf ActiveCell.Offset(0, 2).Value = "A" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
LoginOption.Show
End If
End Sub
---

Thanks!


---
Message posted from
http://www.ExcelForum.com/


--
Message posted from http://www.ExcelForum.com

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Program no longer work on Excel 2003

Anyone able to assist?

Thanks

--
Message posted from http://www.ExcelForum.com

  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 3
Default Program no longer work on Excel 2003

Hello,

I'm experiencing the a similar type problem with Excel 2003, I will write a
line of code using the VB Editor an it won't run. However, when I use the
Record A Macro to generate the exact same line then copy/paste it in. The
code will run without a problem !!!! Apparently something has changed!!!
Regards,
gvlral

"maxifire " wrote in message
...
Hi!

Sorry for the late reply. That's what I did but it seems like MS Office
Web Components is missing. I tried downloading and reinstalling the
component from microsoft.com but it doesn't seem to help.

Could there be any change in the way of coding in Excel 2003?


Rgds

Mark Rosenkrantz wrote:
*Maxfire;

It seems to me that one of the references in VBA is not longer
available or
valid.
I think the first is the case.

Check that in the VBE editor in :

Tools | References

Check for a checkmark for the desired project or library in the
available
references dialogbox.

Mark.

--
More Excel ? www.rosenkrantz.nl or
--------------------------------------------------------------------



"maxifire " wrote in
message
...
Hi, I've been running this VBA program on Excel 2002 for quite some

time
until I've upgraded one of my computers to Excel 2003 and the

program
would generate an error:

Compile Error:
Can't find project or library.

May I know how do I go about solving this problem? Thanks!

Here's the code I use.

---
Sub OkBtn_Click()
Dim b As Integer
Dim uid As String ' a = userid
Dim pwd As String ' c = password

uid = UserNameTB.Value
pwd = PasswordTB.Value

Sheets("EmpList").Select
For b = 2 To 100
Cells(b, 2).Select
If ActiveCell.Value = uid Then
If ActiveCell.Offset(0, 1).Value = pwd Then
chkGrp
Else
MsgBox ("Invalid Password")
Unload Me
End If
Else:
End If
ActiveCell.Offset(1, 0).Select
Next b
Cells(1, 1).Select
End Sub

Sub chkGrp()

Sheets("EmpList").Activate
With TimesheetEntry.TSENameCB
For Row = 7 To 106
TimesheetEntry.TSENameCB.AddItem
Sheets("EmpList").Cells(Row, 2)
Next Row
End With

If ActiveCell.Offset(0, 2).Value = "N" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
TimesheetEntry.Show
ElseIf ActiveCell.Offset(0, 2).Value = "A" Then
Unload Me
TimesheetEntry.TSENameCB.Text = UserNameTB.Value
LoginOption.Show
End If
End Sub
---

Thanks!


---
Message posted from
http://www.ExcelForum.com/
*



---
Message posted from http://www.ExcelForum.com/





  #6   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default Program no longer work on Excel 2003

Oh no. This is bad. Any clue anyone

--
Message posted from http://www.ExcelForum.com

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Undo and redo no longer work. how can I fix this. Excel 2003 DickyD Excel Worksheet Functions 2 March 13th 09 01:37 PM
Arrow Keys in Excel no longer work correctly. bill Excel Discussion (Misc queries) 1 July 9th 08 08:48 PM
How to reload Excel-- no longer have the cd program? Chris Excel Discussion (Misc queries) 3 July 9th 06 07:54 PM
Arrow Keys No Longer Work in EXCEL RJM Excel Discussion (Misc queries) 6 April 4th 06 02:13 PM
VB scripts from Office 97 that no longer work in Office 2003 Christian Johansson Excel Programming 7 January 24th 04 12:34 PM


All times are GMT +1. The time now is 02:31 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"