473,574 Members | 18,327 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Form not opening completely

209 New Member
I now have a very tricky problem. I have a form in my Access application which sometimes - perhaps once every 5 to 10 times, though it is not consistent - does not open completely. Specifically, when opened it displays the header section and a skeletal version of the footer section (i.e. text boxes but no data), but the detail section is completely blank. As far as I know this is the only one of the 70+ forms and subforms in the application which behaves in this way.

The form is normally opened by the statement DoCmd.OpenForm strArgument, acNormal, , , acFormAdd in a switchboard event procedure. In the form's property sheet the default view on opening is Single Form, and Allow Form View is set.
Debug.Print statements in the various event procedures of the form opening sequence (Open - Load - Resize - Activate - Current) (which contain no other code than the debug.print statements) show that when the form opens incompletely the Open, Load, Resize and Activate events occur, but not the Current event. After the Activate event the form is displayed with a blank Detail section.

Compact and Repair, Decompile and recompile don't help. It's doesn't appear to be data-related because I have had it occur with three different users' back end data files.

Sounds like either a tricky hardware problem or a timing issue, right? But it's not hardware, because it has occurred repeatedly on two different computers (mine and the user's) in different locations running different compiled and uncompiled versions of the DBMS. I have also caused long pauses in each of the above-mentioned event procedures (by inserting MsgBox statements there), and it didn't make any difference. Neither did Google turn up anything helpful.

I don't expect anybody to be able to solve this with such scanty information, but can anyone suggest any further way I might be able to tackle the problem or get further information? Or has anyone seen any similar behaviour?
Dec 31 '21 #1
6 9674
32,564 Recognized Expert Moderator MVP
Hi again Petrol.

This sounds very much like it may be that hardest of problems to diagnose - a corruption.

If it's not too difficult then re-create it from scratch. If it really is then try saving it to a text file and reloading it. Here's an example of what that might look like :
Expand|Select|Wrap|Line Numbers
  1. Call SaveAsText(acForm, "MyFormName", "C:\TempFolder\FormName.Txt")
  2. Call LoadFromText(acForm, "MyFormName", "C:\TempFolder\FormName.Txt")
Dec 31 '21 #2
209 New Member
Hmm, yes. I suspected I might have to recreate the form. I guess I can simply copy the controls one by one from the existing form to a new one.
Thank you again, Ade.
Dec 31 '21 #3
32,564 Recognized Expert Moderator MVP
Do them one at a time and check that it still works between each.

Alternatively, the SaveAsText() & LoadFromText() approach may be quicker & should work. Worth a try first before going through the far more long-winded approach ;-)
Dec 31 '21 #4
1,275 Recognized Expert Top Contributor
What is the record source? Are you sure there is data available when this is happening? It sounds to me like the form is fine but there are no records found in the recordsource. Is the form sensitive to the status of the data such that the timing of events may present you with moments when there is no data present?
Dec 31 '21 #5
209 New Member
Thanks, Jim, no, the record source is good and stable - it is the main members list and has thousands of entries - and in any case the form is opened to add new members. It opens correctly most times but only partially now and then, so I think that as NeoPa implies it's just one of those funny little Access glitches. I'll rebuild the form as NeoPa suggests, but thanks for your suggestions too.
I must admit I hadn't thought of doing it through SaveAsText() and LoadFromText().
Dec 31 '21 #6
32,564 Recognized Expert Moderator MVP
That was just something another MVP came up with very recently for someone else so I suggested it here. It seems a quicker way of recreating just the fundamentals of such an object. Glad to hear it worked for you :-)
Dec 31 '21 #7

Sign in to post your reply or Sign up for a free account.

Similar topics

by: RC | last post by:
1) Open Visual Studio .Net 2003 2) Create new project Visual C # (Windows application) 3) Close Visual Studio .Net 2003 4) Compile from command line "devenv.exe /rebuild Debug /project Sample Sample.sln" 5) Open Visual Studio .Net 2003 6) Open Form1 --> Error on document loading If delete the hidden File .\obj\Debug\Sample.projdata I...
by: MS | last post by:
Just a general question here re VBA. Can anyone explain the differences between "!" and "." when refering to a control? eg Me!TxtBox and Me.TxtBox. What is difference between "+" and "&" when working with strings. eg MyStr = "I have " & MyNumber & " apples." and MyStr = "I have " + MyNumber + " apples."
by: Emily Jones | last post by:
Very strange one this. Application written in Access 2000. Runs in 2003 at client's site, 2000 on my development system. FE/BE system. The app's startup form sets a few options, opens the switchboard, then closes. Each of the buttons on the Switchboard opens a form (or report). The Switchboard stays open in the background. One is a...
by: kevcar40 | last post by:
hi is it possible to stop a form opening if the result of the query is null? eg select a company name from a combobox if the name is not in the table (ie the query returns null) can i stop the form opening thanks
by: garyusenet | last post by:
I have a login form, which i have made by simply modifying the standard wizard created form from Visual C# express - when I chose a windows application. I have two buttons on my login form. The first is OK, The second is cancel. For cancel i have the event set to application.exit
by: str1ker | last post by:
Hi, I'm sorry that this question is really noobish, but I've looked in the help file, I've just tried using help from the intelisense, but I have no idea as to how I can open another form. In Visual C#, I've created a program, that'll be for taking joystick axis information, and manipulate it, and I've already got that working, but I have a...
by: Presto731 | last post by:
I have a paremeter query set up that asks you to enter a value to open it. I want the form attached to that query to ask for the same info when you open it. It does that when you click on the form from the database window. All well and good! However my problem lies when I try to open the form from a switchboard, it just simply opens the form...
by: questionit | last post by:
I am trying to open Sub Form using the command below, but i am getting error. Please confirm if i can open sub form using this command: Call DoCmd.OpenForm("Forms!!", acNormal, , , , acWindowNormal)
by: jimatqsi | last post by:
I'm modifying an existing system, working in Access 2003. I recently made a new form with a couple of labels and check boxes. It opens when I click a button on the sales order entry screen. It has been okay, I've been tweaking it, adding some code to control how the checkboxes behave, adding a query to calculate the customer's over/under credit...
by: ganeshvkl | last post by:
hi, My project is VB.net with Sql server 2000. i store image in database now the database size is around 400 MB. when i Click the form (image i have stored & Retrieved), it takes around 3 minutes to show the form , whereas other forms are working fine. ? Thanx in Adv Ganesh.
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.