473,804 Members | 3,018 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

mysterious-connection string "disappears " from source code (bug ??

I am really confused !
- Form1 uses an openfiledialoag to get a public strfilename.
- Forms 2 and 3 both connect to the database specified in the file name.
The connection string is shown below.

Intermittently, the connection string disappears from either Form2, Form3,
or both.
When I get an error, either in debug or running a build, I go back to
inspect the source code and, sure enough, one or both connection strings have
evaporated !
Even stranger, even the comment lines surrounding the string are gone. See
below:

''************* *************** *************** *************** **********
''OleDbConnecti on1
''
Me.OleDbConnect ion1.Connection String = "Jet OLEDB:Global Partial
Bulk Ops=2;Jet OLEDB:Registry Path=;Jet OLEDB:Database L" & _
"ocking Mode=1;Data Source=" + strfilename + ";Jet OLEDB:Engine
Type=5;Provider =""Mic" & _
"rosoft.Jet.OLE DB.4.0"";Jet OLEDB:System database=;Jet
OLEDB:SFP=False ;persist sec" & _
"urity info=False;Exte nded Properties=;Mod e=Share Deny None;Jet
OLEDB:Encrypt Dat" & _
"abase=False;Je t OLEDB:Create System Database=False; Jet OLEDB:Don't
Copy Locale o" & _
"n Compact=False;J et OLEDB:Compact Without Replica Repair=False;Us er
ID=Admin;Jet" & _
" OLEDB:Global Bulk Transactions=1"
Nov 21 '05 #1
2 1323

HarryMangurian wrote:
I am really confused !
- Form1 uses an openfiledialoag to get a public strfilename.
- Forms 2 and 3 both connect to the database specified in the file name. The connection string is shown below.

Intermittently, the connection string disappears from either Form2, Form3, or both.
When I get an error, either in debug or running a build, I go back to inspect the source code and, sure enough, one or both connection strings have evaporated !


Just as a quick check, you're not editing code in Private Sub
InitializeCompo nent are you ?

--
Larry Lard
Replies to group please

Nov 21 '05 #2
No......I have now been told that this can happen if you use the wizard to
set up your connection and you subsequently modify the wizard generated
connection string.

M$ should warn about this somewhere.
Who woulda' thunk that source code can evaporate ex post wizardo !

Just as a quick check, you're not editing code in Private Sub
InitializeCompo nent are you ?

--
Larry Lard
Replies to group please

Nov 21 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
1881
by: Brendan | last post by:
There must be an easy way to do this: For classes that contain very simple data tables, I like to do something like this: class Things(Object): def __init__(self, x, y, z): #assert that x, y, and z have the same length But I can't figure out a _simple_ way to check the arguments have the
6
3229
by: Clausfor | last post by:
Hello, I have a problem with restoring variables in the setjmp/longjmp functions: K&R2 for longjmp says: "Accessible objects have the same value they had when longjmp was called, except for automatic non volatile variables of the function invoking setjmp, these will be undefined if modified after the setjmp call"
3
2504
by: ulyashka | last post by:
Hi, I'm new to access. I am trying to troubleshoot an existing form that I have and this is the problem that I'm having. When I click on the botton, I get a new window with a form in it. The top half of this form is hidden and the scrolls are automatically set to down instead of pointing up. I tried getting rid of the scrolls all together but i still get the top part of my form hidden from the view. Can anyone help me resolve this. ...
7
3558
by: Andrus | last post by:
VS2008 .net 3.5 WinForms application contains only managed code. At random places my application causes exception below. env: Vista SP1. How to fix ? Andrus.
0
9711
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9591
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 synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10343
jinu1996
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 captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10331
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 most users, this new feature is actually very convenient. If you want to control the update process,...
0
9166
agi2029
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 launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6861
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4306
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
2
3831
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3001
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.