Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 104
Default error message with userforms

Hi, i have aprogram that uses multiple userforms that act as an
interface for the users. It works fine most of the time, every now and
then i get the following error message

DEBUG "THE OBJECT HAS DISCONNECTED FROM THE SERVER"

Is there anything i can do about this.

regards

John

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,452
Default error message with userforms

Will need some more information to have any chance of solving that.

RBS


wrote in message
ups.com...
Hi, i have aprogram that uses multiple userforms that act as an
interface for the users. It works fine most of the time, every now and
then i get the following error message

DEBUG "THE OBJECT HAS DISCONNECTED FROM THE SERVER"

Is there anything i can do about this.

regards

John


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 104
Default error message with userforms

what info do you need

  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,452
Default error message with userforms

Some sort of summary of what you are doing.
Any code that you think could be relevant to the problem.
Does the error happen at a particular line of code?
If so knowing that would be helpful.

RBS

wrote in message
oups.com...
what info do you need


  #5   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 104
Default error message with userforms

Hi,

It does not seem to happen at a specific point. The program only uses
userforms. Only one userform seems to have a problem below is some
code that is assigned to one of the command buttons on the userform.
The form displays a list box with data init. The user selects a row
from that data, there are several command buttons that take that data
off the list and pastes to another part of the spreadsheet. each
command button assigns some different data to the row. When the
program takes the dat off the list the userform unloads and reloads
when its pasted it somewhere else, so that the row the user selects
disapears in front of them. It seems as those the program is running
out of memory every now and then and just crashes. Hope this helps if
not i could always e-mail the programm to you to have alook.


code for command button 1

Dim FIVEFOUR
Dim answer
Application.ScreenUpdating = False

Sheets("menu").Select

Call comfirststage
If ActiveCell.Value = "" Then Sheets("MENU").Select
If ActiveCell.Value = "" Then Application.ScreenUpdating = True
If ActiveCell.Value = "" Then Exit Sub


FIVEFOUR = InputBox(PROMPT:="How Many?")
If FIVEFOUR = "" Then MsgBox Title:="POLETRACKER", PROMPT:="You
have not entered a number. If you still wish to complete this job then
select a unit again and ensure you type in the quantity"
If FIVEFOUR = "" Then Call clearback
If FIVEFOUR = "" Then Application.ScreenUpdating = True
If FIVEFOUR = "" Then Exit Sub

Sheets("COM").Select
Range("a2").Select
ActiveCell.Offset(0, 9).Activate
ActiveCell.Value = FIVEFOUR
ActiveCell.Offset(0, -9).Activate
answer = MsgBox(PROMPT:="another unit?", Buttons:=vbYesNo +
vbQuestion)
If answer = vbYes Then Sheets("menu").Select
If answer = vbYes Then Application.ScreenUpdating = True
If answer = vbYes Then Exit Sub
If answer = vbNo Then Call proactivecom


code for COMFIRSTSTAGE

Sub comfirststage()
Sheets("COM").Select
Range("A1").Select

If ActiveCell.Value = "" Then MsgBox Title:="POLETRACKER", PROMPT:="You
have not selected a job. Please retry"

If ActiveCell.Value = "" Then Exit Sub

Sheets("COM").Select
clear = Range("a1")
Sheets("DISPLAY").Select
Range("A1").Select
Selection.AutoFilter
Selection.AutoFilter Field:=1, Criteria1:=clear
Rows("2:700").Select
Selection.Copy
Sheets("COM").Select
Range("a3").Select
ActiveSheet.Paste
Range("A3:h3").Select
Selection.Copy
Range("a2").Select
ActiveSheet.Paste

CODE FOR PROACTIVECOM
Sub proactivecom()
Dim checker As Integer
Dim UNIT As Integer

checker = 0
UNIT = 0
Application.ScreenUpdating = False

Sheets("COM").Select
Range("A2").Select

Do While checker < 20

If ActiveCell.Value < "" Then UNIT = UNIT + 1
ActiveCell.Offset(0, 1).Activate

checker = checker + 1

Loop

If UNIT < 1 Then MsgBox Title:="POLETRACKER", PROMPT:="You cannot
complete this job as you have not assigned any units!"
If UNIT < 1 Then ActiveCell.Offset(0, -20).Activate
If UNIT < 1 Then Selection.End(xlToLeft).Select
If UNIT < 1 Then Exit Sub

Range("a2").Select

UserForm6.Show
End Sub


CODE FOR CLEARBACK

Sub clearback()

Sheets("COM").Select
Rows("1:1").Select
Application.CutCopyMode = False
Selection.ClearContents
Rows("2:2").Select
Application.CutCopyMode = False
Selection.ClearContents
Range("A1").Select
Sheets("DISPLAY").Select
Range("A1").Select
Selection.AutoFilter
Selection.AutoFilter Field:=1
Range("A1").Select
Sheets("MENU").Select
Application.ScreenUpdating = True

End Sub

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
VBA Error Message "Compile Error...." Steve Excel Discussion (Misc queries) 3 July 15th 05 09:20 AM
changing the message in an error message The Villages DA Excel Worksheet Functions 2 February 18th 05 05:30 PM
How do I get rid of "Compile error in hidden module" error message David Excel Discussion (Misc queries) 4 January 21st 05 11:39 PM
system error when inserting UserForms drewnkc Excel Programming 1 December 10th 04 04:47 PM
excel.exe error when adding controls to userforms Brian Excel Programming 0 February 20th 04 10:55 PM


All times are GMT +1. The time now is 03:45 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"