Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms / December 2005

Tip: Looking for answers? Try searching our database.

Button ghosts... click it works... click again it doesn't work

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Ben - 14 Dec 2005 10:59 GMT
What I try to do is make my addnew subform visible on click...

Private Sub Kommandoknapp74_Click()
If Me.Kommandoknapp74.Caption = "New Call" Then
   Me.Underobjekt73.Visible = True
   Me.Kommandoknapp74.Caption = "Save"
Else
   Me.Underobjekt73.Visible = False
   Me.Refresh
   Me.Kommandoknapp74.Caption = "New Call"
End If
End Sub

Now, the first time it makes it visible, it's an empty form ready for input.
Click again it saves the new data/record and nicely adds to the list below.
Click on New Call again and it shows the existing records... so not an
addonly form...
What simple thing am I doing wrong again?

Thanks for sharing  your skills
Ben

Signature

Novice

Graham R Seach - 14 Dec 2005 11:38 GMT
Ben,

If you want a new data entry form, use Me.Underobjekt73.DataEntry=True.

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
---------------------------

> What I try to do is make my addnew subform visible on click...
>
[quoted text clipped - 19 lines]
> Thanks for sharing  your skills
> Ben
Ben - 14 Dec 2005 11:57 GMT
Thanks for the answer from wonderfull Sydney,  but it doesn't seem to work.
In my properties of the subform, I had already put it on allowAdditions =
true and all the others on False... so no edit, no deletions. And I believe
that Me.Underobjekt73.DataEntry=True would do just that, right ?

On opening the form, it works and then you can record the call but suppose
that you would click again on it... it should reset the subform to an empty
addnew.. Hmmm, it could also just not show it again...
Is it easier to fix the problem or to just add a 3rd factor to the click
function which will hide it and replace by a text (you just created a new
call for this doctor!)
If so, how to add a 3rd factor to code below ?

Thanks again

Signature

Novice

> Ben,
>
[quoted text clipped - 29 lines]
> > Thanks for sharing  your skills
> > Ben
Graham R Seach - 14 Dec 2005 12:40 GMT
Ben,

Sorry, that should have been:
   Me.Underobjekt73.Form.DataEntry=True

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
---------------------------

> Thanks for the answer from wonderfull Sydney,  but it doesn't seem to
> work.
[quoted text clipped - 47 lines]
>> > Thanks for sharing  your skills
>> > Ben
Ben - 14 Dec 2005 13:05 GMT
Graham, you saved my day ! Thanks

Greetings from Sweden
Ben

Signature

Novice

> Ben,
>
[quoted text clipped - 58 lines]
> >> > Thanks for sharing  your skills
> >> > Ben
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.