Error on form?

  • Thread starter Thread starter Simon Harris
  • Start date Start date
S

Simon Harris

Hi All,

I have developed a basic invoicing system. I am seeing error popup on
certain machines, but not all. For example the system works Ok my machine,
but not on a clients - Both machines have the same version of Windows (xp
pro sp1) and Access (2k)

Problem is this - User opens a form, hits my save button which calls this
code:

Private Sub AddAmendOrderCloseButton_Click()
'User has clicked exit button, so close the form
ReturnValue = MsgBox("Are you sure you want to close with out saving?",
vbDefaultButton2 + vbQuestion + vbOKCancel, "Delete Record")
Select Case ReturnValue
Case vbOK
DoCmd.Close acForm, "FRM_add_amend_order"
Case vbCancel
End Select
End Sub

When they click Ok, they get a box popup, title is 'Enter paremter value'
required parameter is: 'Forms!FRM_add_amend_order_!SUBFRM_view_parts_orders'

'SUBFRM_view_parts_orders' is in fact a list box - This can have a value, or
can be empty, depending on whether or not the user entered any data, the
error seems to popup either way.

So - They click Ok to the error, the form closes and they get another box,
title is again 'enter parameter value' required paremter is
'Forms!FRM_add_amend_order!ID' which is used in the query that drives
'SUBFRM_view_parts_orders' (Mentioned above)

What I really dont understand is why this works on my machine, but not on
the clients (I've seen it happen) I have tried copying my version across to
them, and doing a compact and repair in case it was corrupt in some way. (I
always have the most up to date version anyway) also tried copying back onto
my machine - no errors. WEIRD!!!

Hopefully someone can point me in the right direction to diagnose this mess!
:)

Kind regards,

Simon.




--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
 
Simon:

It seems to me that the list box is requering (it has to requery to
show data just entered in the parent form) in your machine but not in the
others. For that to happen the ID control has to have data and it has to be
saved, otherwise the list box will show no record.
Those machines either don't requery the list or don't save the ID
(current record) for some reason.
I would check the compiling of the app. in the machines with the
error. Any module window, Debug menu, Compile database... Wether it compiles
or it doesn't, go to Tools menu as well and click on References to see if
there are conflicts. Resolve those and add any Reference you think should be
there. Or have a look at the existing references in the app on your machine
and duplicate the ones you can in the user's.

Hope it helps,

Phil

Hi All,

I have developed a basic invoicing system. I am seeing error popup on
certain machines, but not all. For example the system works Ok my machine,
but not on a clients - Both machines have the same version of Windows (xp
pro sp1) and Access (2k)

Problem is this - User opens a form, hits my save button which calls this
code:

Private Sub AddAmendOrderCloseButton_Click()
'User has clicked exit button, so close the form
ReturnValue = MsgBox("Are you sure you want to close with out saving?",
vbDefaultButton2 + vbQuestion + vbOKCancel, "Delete Record")
Select Case ReturnValue
Case vbOK
DoCmd.Close acForm, "FRM_add_amend_order"
Case vbCancel
End Select
End Sub

When they click Ok, they get a box popup, title is 'Enter paremter value'
required parameter is: 'Forms!FRM_add_amend_order_!SUBFRM_view_parts_orders'

'SUBFRM_view_parts_orders' is in fact a list box - This can have a value, or
can be empty, depending on whether or not the user entered any data, the
error seems to popup either way.

So - They click Ok to the error, the form closes and they get another box,
title is again 'enter parameter value' required paremter is
'Forms!FRM_add_amend_order!ID' which is used in the query that drives
'SUBFRM_view_parts_orders' (Mentioned above)

What I really dont understand is why this works on my machine, but not on
the clients (I've seen it happen) I have tried copying my version across to
them, and doing a compact and repair in case it was corrupt in some way. (I
always have the most up to date version anyway) also tried copying back onto
my machine - no errors. WEIRD!!!

Hopefully someone can point me in the right direction to diagnose this mess!
:)

Kind regards,

Simon.




--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
 
Hi Guys,

Many thanks for your replies which I appreaicte.

I have checked the references, my client has exactly the same as me, apart
from one which was a different version, I asked him to untick this reference
(DAO 3.6) and reload the DB, the system still worked, but the errors still
occured.

Would you have any idea on where I can go next with this?

Many thanks,

Simon.
 
Simon:
Try plan 2 then. Plan 1 was references and compiling, which you
don't mention but I trust you at least tried. What compiling a database does
is pointing you to inconsistencies in the code. If for some reason there is
conflict with a particular reference in a p'lar machine, compiling can bring
it out for you to fix.
If they compile then plan 3... it gets harder as you go so don't get
discouraged yet.
Check events in the order they happen on the OnClose event of the
form, there is where the problem is. Do it in a machine that pops up the
funny message. Go to the module window to do that.

When a form closes it saves the current record. So what you call
"saving" by clicking on the [AddAmendOrderClose] Button is something else...
That's ok but could that be the event that causes a conflict with the list
box? Check if the Parameter Popup warning happens because of a syntax error
in your code. Check the SQL the list box is based on, are there any criteria
that specifies anything about the Form's ID field? How do the two relate?
How do you want them to relate?...
If there is no code on the form's module except for your Close
vbOk-Cancel button, or even if there is, examine the list box closely. I
mean the source property, the fields it shows, the fields it has, it's
indexed field... somehow it all seems to lead to the list box's ID and the
form's ID Shouldn't the box's SQL ID field have a criteria like
Forms![FRM_add_amend_order]![ID] and code on the AfterUpdate of an
appropriate field that causes a Me![MyListBox].Requery action... probably
the ProductCode that causes the list to populate...

When you click the Close button what is it that happens that you
call "Save", particularly that affects the list box?
I don't mean that you answer all those questions to the newsgroups
or to me, so someone fixes the problem for you. But as you see you may not
be getting an answer because there are so many things involved here... be
daring and dig deep into it. Chances are you'll bump into the answer all by
yourself!
But if you don't then you are likely to find a very specific
question about a very specific event and get lots and lots of very specific
answers....

Regards,

Phil

Hi Guys,

Many thanks for your replies which I appreaicte.

I have checked the references, my client has exactly the same as me, apart
from one which was a different version, I asked him to untick this reference
(DAO 3.6) and reload the DB, the system still worked, but the errors still
occured.

Would you have any idea on where I can go next with this?

Many thanks,

Simon.
 
Generally when you get a parameter popup it means a field that may be
misreferenced or misspelled. If you have your database split and you gave
them only a new front-end, but your backend had a field added; did you add
this new field to there backend?

Double check to make sure all the fields on the form are being passed to the
underlying table.


Phil Carrero said:
Simon:
Try plan 2 then. Plan 1 was references and compiling, which you
don't mention but I trust you at least tried. What compiling a database does
is pointing you to inconsistencies in the code. If for some reason there is
conflict with a particular reference in a p'lar machine, compiling can bring
it out for you to fix.
If they compile then plan 3... it gets harder as you go so don't get
discouraged yet.
Check events in the order they happen on the OnClose event of the
form, there is where the problem is. Do it in a machine that pops up the
funny message. Go to the module window to do that.

When a form closes it saves the current record. So what you call
"saving" by clicking on the [AddAmendOrderClose] Button is something else...
That's ok but could that be the event that causes a conflict with the list
box? Check if the Parameter Popup warning happens because of a syntax error
in your code. Check the SQL the list box is based on, are there any criteria
that specifies anything about the Form's ID field? How do the two relate?
How do you want them to relate?...
If there is no code on the form's module except for your Close
vbOk-Cancel button, or even if there is, examine the list box closely. I
mean the source property, the fields it shows, the fields it has, it's
indexed field... somehow it all seems to lead to the list box's ID and the
form's ID Shouldn't the box's SQL ID field have a criteria like
Forms![FRM_add_amend_order]![ID] and code on the AfterUpdate of an
appropriate field that causes a Me![MyListBox].Requery action... probably
the ProductCode that causes the list to populate...

When you click the Close button what is it that happens that you
call "Save", particularly that affects the list box?
I don't mean that you answer all those questions to the newsgroups
or to me, so someone fixes the problem for you. But as you see you may not
be getting an answer because there are so many things involved here... be
daring and dig deep into it. Chances are you'll bump into the answer all by
yourself!
But if you don't then you are likely to find a very specific
question about a very specific event and get lots and lots of very specific
answers....

Regards,

Phil

Hi Guys,

Many thanks for your replies which I appreaicte.

I have checked the references, my client has exactly the same as me, apart
from one which was a different version, I asked him to untick this reference
(DAO 3.6) and reload the DB, the system still worked, but the errors still
occured.

Would you have any idea on where I can go next with this?

Many thanks,

Simon.


Simon Harris said:
Hi All,

I have developed a basic invoicing system. I am seeing error popup on
certain machines, but not all. For example the system works Ok my machine,
but not on a clients - Both machines have the same version of Windows (xp
pro sp1) and Access (2k)

Problem is this - User opens a form, hits my save button which calls this
code:

Private Sub AddAmendOrderCloseButton_Click()
'User has clicked exit button, so close the form
ReturnValue = MsgBox("Are you sure you want to close with out saving?",
vbDefaultButton2 + vbQuestion + vbOKCancel, "Delete Record")
Select Case ReturnValue
Case vbOK
DoCmd.Close acForm, "FRM_add_amend_order"
Case vbCancel
End Select
End Sub

When they click Ok, they get a box popup, title is 'Enter paremter value'
required parameter is: 'Forms!FRM_add_amend_order_!SUBFRM_view_parts_orders'

'SUBFRM_view_parts_orders' is in fact a list box - This can have a
value,
or
can be empty, depending on whether or not the user entered any data, the
error seems to popup either way.

So - They click Ok to the error, the form closes and they get another box,
title is again 'enter parameter value' required paremter is
'Forms!FRM_add_amend_order!ID' which is used in the query that drives
'SUBFRM_view_parts_orders' (Mentioned above)

What I really dont understand is why this works on my machine, but not on
the clients (I've seen it happen) I have tried copying my version across to
them, and doing a compact and repair in case it was corrupt in some way. (I
always have the most up to date version anyway) also tried copying back onto
my machine - no errors. WEIRD!!!

Hopefully someone can point me in the right direction to diagnose this mess!
:)

Kind regards,

Simon.




--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
 
Hi,

Thanks for your reply - I did try compiling, no luck i'm afraid, could you
possibly tell me what compiling does in Access? To me, compiling is going
from runtime code to executable file/dll/com object...

I took a backup of the DB before I compiled just in case. I dont see any
difference, I can still access all the code, and form design etc.

I will try the outstanding ideas and post back soon.

Thanks again,
Simon.

Phil Carrero said:
Simon:
Try plan 2 then. Plan 1 was references and compiling, which you
don't mention but I trust you at least tried. What compiling a database does
is pointing you to inconsistencies in the code. If for some reason there is
conflict with a particular reference in a p'lar machine, compiling can bring
it out for you to fix.
If they compile then plan 3... it gets harder as you go so don't get
discouraged yet.
Check events in the order they happen on the OnClose event of the
form, there is where the problem is. Do it in a machine that pops up the
funny message. Go to the module window to do that.

When a form closes it saves the current record. So what you call
"saving" by clicking on the [AddAmendOrderClose] Button is something else...
That's ok but could that be the event that causes a conflict with the list
box? Check if the Parameter Popup warning happens because of a syntax error
in your code. Check the SQL the list box is based on, are there any criteria
that specifies anything about the Form's ID field? How do the two relate?
How do you want them to relate?...
If there is no code on the form's module except for your Close
vbOk-Cancel button, or even if there is, examine the list box closely. I
mean the source property, the fields it shows, the fields it has, it's
indexed field... somehow it all seems to lead to the list box's ID and the
form's ID Shouldn't the box's SQL ID field have a criteria like
Forms![FRM_add_amend_order]![ID] and code on the AfterUpdate of an
appropriate field that causes a Me![MyListBox].Requery action... probably
the ProductCode that causes the list to populate...

When you click the Close button what is it that happens that you
call "Save", particularly that affects the list box?
I don't mean that you answer all those questions to the newsgroups
or to me, so someone fixes the problem for you. But as you see you may not
be getting an answer because there are so many things involved here... be
daring and dig deep into it. Chances are you'll bump into the answer all by
yourself!
But if you don't then you are likely to find a very specific
question about a very specific event and get lots and lots of very specific
answers....

Regards,

Phil

Hi Guys,

Many thanks for your replies which I appreaicte.

I have checked the references, my client has exactly the same as me, apart
from one which was a different version, I asked him to untick this reference
(DAO 3.6) and reload the DB, the system still worked, but the errors still
occured.

Would you have any idea on where I can go next with this?

Many thanks,

Simon.


Simon Harris said:
Hi All,

I have developed a basic invoicing system. I am seeing error popup on
certain machines, but not all. For example the system works Ok my machine,
but not on a clients - Both machines have the same version of Windows (xp
pro sp1) and Access (2k)

Problem is this - User opens a form, hits my save button which calls this
code:

Private Sub AddAmendOrderCloseButton_Click()
'User has clicked exit button, so close the form
ReturnValue = MsgBox("Are you sure you want to close with out saving?",
vbDefaultButton2 + vbQuestion + vbOKCancel, "Delete Record")
Select Case ReturnValue
Case vbOK
DoCmd.Close acForm, "FRM_add_amend_order"
Case vbCancel
End Select
End Sub

When they click Ok, they get a box popup, title is 'Enter paremter value'
required parameter is: 'Forms!FRM_add_amend_order_!SUBFRM_view_parts_orders'

'SUBFRM_view_parts_orders' is in fact a list box - This can have a
value,
or
can be empty, depending on whether or not the user entered any data, the
error seems to popup either way.

So - They click Ok to the error, the form closes and they get another box,
title is again 'enter parameter value' required paremter is
'Forms!FRM_add_amend_order!ID' which is used in the query that drives
'SUBFRM_view_parts_orders' (Mentioned above)

What I really dont understand is why this works on my machine, but not on
the clients (I've seen it happen) I have tried copying my version across to
them, and doing a compact and repair in case it was corrupt in some way. (I
always have the most up to date version anyway) also tried copying back onto
my machine - no errors. WEIRD!!!

Hopefully someone can point me in the right direction to diagnose this mess!
:)

Kind regards,

Simon.




--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
 
Good point! The database is split, but I am sure I havent changed the
backend...just the queries (Which reside in the front end)

Thanks,
Simon.

GVaught said:
Generally when you get a parameter popup it means a field that may be
misreferenced or misspelled. If you have your database split and you gave
them only a new front-end, but your backend had a field added; did you add
this new field to there backend?

Double check to make sure all the fields on the form are being passed to the
underlying table.


Phil Carrero said:
Simon:
Try plan 2 then. Plan 1 was references and compiling, which you
don't mention but I trust you at least tried. What compiling a database does
is pointing you to inconsistencies in the code. If for some reason there is
conflict with a particular reference in a p'lar machine, compiling can bring
it out for you to fix.
If they compile then plan 3... it gets harder as you go so don't get
discouraged yet.
Check events in the order they happen on the OnClose event of the
form, there is where the problem is. Do it in a machine that pops up the
funny message. Go to the module window to do that.

When a form closes it saves the current record. So what you call
"saving" by clicking on the [AddAmendOrderClose] Button is something else...
That's ok but could that be the event that causes a conflict with the list
box? Check if the Parameter Popup warning happens because of a syntax error
in your code. Check the SQL the list box is based on, are there any criteria
that specifies anything about the Form's ID field? How do the two relate?
How do you want them to relate?...
If there is no code on the form's module except for your Close
vbOk-Cancel button, or even if there is, examine the list box closely. I
mean the source property, the fields it shows, the fields it has, it's
indexed field... somehow it all seems to lead to the list box's ID and the
form's ID Shouldn't the box's SQL ID field have a criteria like
Forms![FRM_add_amend_order]![ID] and code on the AfterUpdate of an
appropriate field that causes a Me![MyListBox].Requery action... probably
the ProductCode that causes the list to populate...

When you click the Close button what is it that happens that you
call "Save", particularly that affects the list box?
I don't mean that you answer all those questions to the newsgroups
or to me, so someone fixes the problem for you. But as you see you may not
be getting an answer because there are so many things involved here... be
daring and dig deep into it. Chances are you'll bump into the answer all by
yourself!
But if you don't then you are likely to find a very specific
question about a very specific event and get lots and lots of very specific
answers....

Regards,

Phil

Hi Guys,

Many thanks for your replies which I appreaicte.

I have checked the references, my client has exactly the same as me, apart
from one which was a different version, I asked him to untick this reference
(DAO 3.6) and reload the DB, the system still worked, but the errors still
occured.

Would you have any idea on where I can go next with this?

Many thanks,

Simon.


Simon Harris said:
Hi All,

I have developed a basic invoicing system. I am seeing error popup on
certain machines, but not all. For example the system works Ok my machine,
but not on a clients - Both machines have the same version of Windows (xp
pro sp1) and Access (2k)

Problem is this - User opens a form, hits my save button which calls this
code:

Private Sub AddAmendOrderCloseButton_Click()
'User has clicked exit button, so close the form
ReturnValue = MsgBox("Are you sure you want to close with out saving?",
vbDefaultButton2 + vbQuestion + vbOKCancel, "Delete Record")
Select Case ReturnValue
Case vbOK
DoCmd.Close acForm, "FRM_add_amend_order"
Case vbCancel
End Select
End Sub

When they click Ok, they get a box popup, title is 'Enter paremter value'
required parameter is: 'Forms!FRM_add_amend_order_!SUBFRM_view_parts_orders'

'SUBFRM_view_parts_orders' is in fact a list box - This can have a
value,
or
can be empty, depending on whether or not the user entered any data, the
error seems to popup either way.

So - They click Ok to the error, the form closes and they get another box,
title is again 'enter parameter value' required paremter is
'Forms!FRM_add_amend_order!ID' which is used in the query that drives
'SUBFRM_view_parts_orders' (Mentioned above)

What I really dont understand is why this works on my machine, but not on
the clients (I've seen it happen) I have tried copying my version
across
to
them, and doing a compact and repair in case it was corrupt in some
way.
(I
always have the most up to date version anyway) also tried copying
back
onto
my machine - no errors. WEIRD!!!

Hopefully someone can point me in the right direction to diagnose this mess!
:)

Kind regards,

Simon.




--
-
* Please reply to group for the benefit of all
* Found the answer to your own question? Post it!
* Get a useful reply to one of your posts?...post an answer to another one
* Search first, post later : http://www.google.co.uk/groups
* Want my email address? Ask me in a post...Cos2MuchSpamMakesUFat!
 
Van,

Thanks alot mate - that looks like it might be the solution - Fingers
crossed, I'll be seeing my client tonight, I'll post back and let you know
what happens.

Thanks again all!

Simon. (Now feeling hopeful about this one!)
 
Back
Top