A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » General Discussion
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

COMPILER WRONG !!!



 
 
Thread Tools Display Modes
  #11  
Old October 2nd, 2008, 04:22 PM posted to microsoft.public.access
PACALA_BA[_2_]
external usenet poster
 
Posts: 85
Default COMPILER WRONG !!!

Hi, Compile on Demand is OFF
i must allways Run in Debug mode
After Pseudo-Compile-Error, i Rebuild the line strSQL =...
(chr(34) Remove and Add)
Debug-menu : Compile-All,Save
and strSQL is then OK.

The most case is 1-3 Pseudo-Compile-Error
Some times it is Error free.
And than make MDE.
It Runs than dailly over Night (15 Hours)...Error Free !!!
see image --
http://i34.tinypic.com/71sdq8.jpg

I have NEVER seen such Errors !!!!!!
****************************
And it seems Microsoft has NO Interess about this...

"PACALA_BA" wrote:

hi, an typical unbelievable COMPILER ERROR !!!!
***********************************
Singel User/ Secure ACCES-2003 Database (MDE+MDW)
( it happens also after SaveAsText/loadAsText)
http://i34.tinypic.com/71sdq8.jpg
**************************
the conpiler DO NOT SEE some part of the line
(an public constant)
ther is an difference between WATCH and Run Variable !!!!


"PACALA_BA" wrote:

Some times happens this:
It is MS ACCESS 2003, VERY LARGE PROGRAM-DB (MDE=9MB,MDB=15MB)
There are NO BASIC ERRORS
There are COMPILE ERRORS !!!!!!!!!!!!!!!
strSQL = "select * from [" & lcTAbleNAme & "] where ...." & lcWhere & "...."
After compile, the string is SHORTEN
CNN.Execute strSQL
Debug.print =
strSQL = "select * from ["

I must Compile not ONE-times, but 2-3 Times, and then is OK.
*********************************************


----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm....public.access

  #12  
Old October 2nd, 2008, 04:46 PM posted to microsoft.public.access
PACALA_BA[_2_]
external usenet poster
 
Posts: 85
Default COMPILER WRONG !!!

I have now shorten my LONG lines of code to 1/2 Length
The Maximum size = 1024 char (says Microsoft)
But It seems that the RECOMMENDED Maximum Size is NOT 1024 char

I am also MASSIVE using the double dot ':' operator
Before January 2008 , i have NONE such Problems
May be i try to recreate my code to VERY SHORT LINES.
But it is an terible thing
if (cond1 ) then x = x+ 1:y = y+1:if (cod2) then x= x-1:y = y+2:....

and i am using ONE line Select case
Select case a:case 1: x=1:case2:x=2:case else:x=10:end select

This may be an Problem (? !)

i am Allways making the same
some Little changes in MDB ~9MB
than Saveastext/Load asText, make MDE
And it works NOT 100% Error free.
the succes rate is about 30-50 %.
When i create the OK-(NONE-CRASH)MDE,
than it works WONDERFULL.....
All Access Crashes, Reported to MICROSOFT
since January 2008 about 500 CRASHES !!
*******************************
I do NOT Know the Result of this Crashes....
This MUST say MICROSOFT....
(see.....Why shoud i report to microsoft, or NOT ?)
Bye



"PACALA_BA" wrote:

Some times happens this:
It is MS ACCESS 2003, VERY LARGE PROGRAM-DB (MDE=9MB,MDB=15MB)
There are NO BASIC ERRORS
There are COMPILE ERRORS !!!!!!!!!!!!!!!
strSQL = "select * from [" & lcTAbleNAme & "] where ...." & lcWhere & "...."
After compile, the string is SHORTEN
CNN.Execute strSQL
Debug.print =
strSQL = "select * from ["

I must Compile not ONE-times, but 2-3 Times, and then is OK.
*********************************************


----------------
This post is a suggestion for Microsoft, and Microsoft responds to the
suggestions with the most votes. To vote for this suggestion, click the "I
Agree" button in the message pane. If you do not see the button, follow this
link to open the suggestion in the Microsoft Web-based Newsreader and then
click "I Agree" in the message pane.

http://www.microsoft.com/office/comm....public.access

  #13  
Old October 2nd, 2008, 07:35 PM posted to microsoft.public.access
John W. Vinson
external usenet poster
 
Posts: 18,261
Default COMPILER WRONG !!!

On Thu, 2 Oct 2008 08:46:29 -0700, PACALA_BA
wrote:

I have now shorten my LONG lines of code to 1/2 Length
The Maximum size = 1024 char (says Microsoft)
But It seems that the RECOMMENDED Maximum Size is NOT 1024 char

I am also MASSIVE using the double dot ':' operator
Before January 2008 , i have NONE such Problems
May be i try to recreate my code to VERY SHORT LINES.
But it is an terible thing
if (cond1 ) then x = x+ 1:y = y+1:if (cod2) then x= x-1:y = y+2:....


WHY are you trying to put all the code on one line?

It's both easier to read and easier for the compiler if you do it the normal
way:

If (cond) Then
X = X + 1
Y = Y + 1
Elseif (Cond2) Then
X = x -1
Y = Y +2
End If

and i am using ONE line Select case
Select case a:case 1: x=1:case2:x=2:case else:x=10:end select


Again:

Select Case A
Case 1
X = 1
Case 2
X = 2
Case Else
X = 10
End Select

This may be an Problem (? !)

i am Allways making the same
some Little changes in MDB ~9MB
than Saveastext/Load asText, make MDE
And it works NOT 100% Error free.
the succes rate is about 30-50 %.
When i create the OK-(NONE-CRASH)MDE,
than it works WONDERFULL.....
All Access Crashes, Reported to MICROSOFT
since January 2008 about 500 CRASHES !!
*******************************
I do NOT Know the Result of this Crashes....
This MUST say MICROSOFT....
(see.....Why shoud i report to microsoft, or NOT ?)


If you're assuming that posting in this newsgroup is "reporting to Microsoft"
you should be aware that it is NOT. These newsgroups are peer support groups;
everyone who answers questions here is an unpaid volunteer. Even the
occasional posts from Microsoft employees are (as far as I know) on their own
time.

I do *not* think you have a bug.

I think you have a very individual and probably flawed programming style, for
reasons which I do not understand.

Try writing your code without multiple lines per line, and without hugely long
single lines. I honestly believe it will work better.
--

John W. Vinson [MVP]
  #14  
Old October 3rd, 2008, 02:31 PM posted to microsoft.public.access
PACALA_BA[_2_]
external usenet poster
 
Posts: 85
Default COMPILER WRONG !!!

Hi, thanks for the Answer
1.
I HAVE reported 'Access-Crashes' to Microsoft
( we are sorry for the inconvinience..., why shoud i report to microsoft)

2. why long lines ?
I have LARGE-NON-TABLES/PROGRAM DATABASE (MODULES ~5.5MB)
The code is more readable, but from 'Overview-Sight' (My opinion),
When you are interesting in Detail of Code it is Opaque/Not very good
readable.
When i am writing code,
allways it is SHORT, after DEBUG-OK, i have change it to LONG-LINE.
Ok, i can change it BACK.
I have shorten NOW my VERY-LONG-LINES, 'First' Result is , it seems more
stabil...

3.but BIG-PROBLEM is this wrong-compiler-example
http://i34.tinypic.com/71sdq8.jpg ;
that probably makes this ~300 ACCESS-CRASHES , that i HAVE REPORTED to
Microsoft.

Bye

"John W. Vinson" wrote:

On Thu, 2 Oct 2008 08:46:29 -0700, PACALA_BA
wrote:

I have now shorten my LONG lines of code to 1/2 Length
The Maximum size = 1024 char (says Microsoft)
But It seems that the RECOMMENDED Maximum Size is NOT 1024 char

I am also MASSIVE using the double dot ':' operator
Before January 2008 , i have NONE such Problems
May be i try to recreate my code to VERY SHORT LINES.
But it is an terible thing
if (cond1 ) then x = x+ 1:y = y+1:if (cod2) then x= x-1:y = y+2:....


WHY are you trying to put all the code on one line?

It's both easier to read and easier for the compiler if you do it the normal
way:

If (cond) Then
X = X + 1
Y = Y + 1
Elseif (Cond2) Then
X = x -1
Y = Y +2
End If

and i am using ONE line Select case
Select case a:case 1: x=1:case2:x=2:case else:x=10:end select


Again:

Select Case A
Case 1
X = 1
Case 2
X = 2
Case Else
X = 10
End Select

This may be an Problem (? !)

i am Allways making the same
some Little changes in MDB ~9MB
than Saveastext/Load asText, make MDE
And it works NOT 100% Error free.
the succes rate is about 30-50 %.
When i create the OK-(NONE-CRASH)MDE,
than it works WONDERFULL.....
All Access Crashes, Reported to MICROSOFT
since January 2008 about 500 CRASHES !!
*******************************
I do NOT Know the Result of this Crashes....
This MUST say MICROSOFT....
(see.....Why shoud i report to microsoft, or NOT ?)


If you're assuming that posting in this newsgroup is "reporting to Microsoft"
you should be aware that it is NOT. These newsgroups are peer support groups;
everyone who answers questions here is an unpaid volunteer. Even the
occasional posts from Microsoft employees are (as far as I know) on their own
time.

I do *not* think you have a bug.

I think you have a very individual and probably flawed programming style, for
reasons which I do not understand.

Try writing your code without multiple lines per line, and without hugely long
single lines. I honestly believe it will work better.
--

John W. Vinson [MVP]

  #15  
Old October 3rd, 2008, 05:59 PM posted to microsoft.public.access
John W. Vinson
external usenet poster
 
Posts: 18,261
Default COMPILER WRONG !!!

On Fri, 3 Oct 2008 06:31:01 -0700, PACALA_BA
wrote:

Hi, thanks for the Answer
1.
I HAVE reported 'Access-Crashes' to Microsoft
( we are sorry for the inconvinience..., why shoud i report to microsoft)

2. why long lines ?
I have LARGE-NON-TABLES/PROGRAM DATABASE (MODULES ~5.5MB)


No. You have a *TINY* database. 50MByte is getting a bit large; 1000MByte is
getting too big. 5.5MByte is a *very small database*.

The code is more readable, but from 'Overview-Sight' (My opinion),
When you are interesting in Detail of Code it is Opaque/Not very good
readable.


So scrolling horizontally across three or four screens is somehow *more*
readable?

When i am writing code,
allways it is SHORT, after DEBUG-OK, i have change it to LONG-LINE.


WHY!!!!???

Ok, i can change it BACK.
I have shorten NOW my VERY-LONG-LINES, 'First' Result is , it seems more
stabil...


Well... ok. So you've found at least one source of the problem.

3.but BIG-PROBLEM is this wrong-compiler-example
http://i34.tinypic.com/71sdq8.jpg ;


I have NO idea what that screen means.

that probably makes this ~300 ACCESS-CRASHES , that i HAVE REPORTED to
Microsoft.


What would you like me - an unpaid volunteer donating my time on this
newsgroup - to do? What result do you hope to get from posting to this
newsgroup?

--

John W. Vinson [MVP]
  #16  
Old October 3rd, 2008, 07:53 PM posted to microsoft.public.access
PACALA_BA[_2_]
external usenet poster
 
Posts: 85
Default COMPILER WRONG !!!

BIG-PROBLEM is this wrong-compiler-example
http://i34.tinypic.com/71sdq8.jpg ;

Here is the String cSQL not correctly created !!!!
The Compiler DO NOT SEE the value of gkII_cKRA_SKR !!!!!!!!!

public const gkII_cKRA_SKR = "LAB"
' cSQL = "SOME-STRING" ....the actual vlue
If (LN_FLD_SEL_CNT 255) Then
cSQL = cSQL & ",I0." & gkII_cKRA_SKR ' --- SEE NOTICE DOWN
LN_FLD_SEL_CNT = LN_FLD_SEL_CNT + 1
endif
NOTICE:
In the watches window, the line with RED arrows
cSQL = "SOME-STRING,I0." ..the WRONG-current value of cSQL
- WITHOUT public const gkII_cKRA_SKR ("LAB") ,WHY ?????
Question:
In the watches window, the line with GREEN arrows
cSQL = cSQL & ",I0." & gkII_cKRA_SKR ..the current value of CODE-LINE is
"SOME-STRING,I0.,I0.LAB"...
Here is added "LAB", that is OK...!!!!!!!!!!, but only in WATCH-WINDOW

Resume:
Why is there DIFFERENCE between Compiler and DEBUG ???
*******************************************
than the string is used for an connection
Connection.Execute cSQL
and because the string cSQL is Wrong , execution failes.....


"John W. Vinson" wrote:

On Fri, 3 Oct 2008 06:31:01 -0700, PACALA_BA
wrote:

Hi, thanks for the Answer
1.
I HAVE reported 'Access-Crashes' to Microsoft
( we are sorry for the inconvinience..., why shoud i report to microsoft)

2. why long lines ?
I have LARGE-NON-TABLES/PROGRAM DATABASE (MODULES ~5.5MB)


No. You have a *TINY* database. 50MByte is getting a bit large; 1000MByte is
getting too big. 5.5MByte is a *very small database*.

The code is more readable, but from 'Overview-Sight' (My opinion),
When you are interesting in Detail of Code it is Opaque/Not very good
readable.


So scrolling horizontally across three or four screens is somehow *more*
readable?

When i am writing code,
allways it is SHORT, after DEBUG-OK, i have change it to LONG-LINE.


WHY!!!!???

Ok, i can change it BACK.
I have shorten NOW my VERY-LONG-LINES, 'First' Result is , it seems more
stabil...


Well... ok. So you've found at least one source of the problem.

3.but BIG-PROBLEM is this wrong-compiler-example
http://i34.tinypic.com/71sdq8.jpg ;


I have NO idea what that screen means.

that probably makes this ~300 ACCESS-CRASHES , that i HAVE REPORTED to
Microsoft.


What would you like me - an unpaid volunteer donating my time on this
newsgroup - to do? What result do you hope to get from posting to this
newsgroup?

--

John W. Vinson [MVP]

  #17  
Old October 3rd, 2008, 09:50 PM posted to microsoft.public.access
David W. Fenton
external usenet poster
 
Posts: 3,373
Default COMPILER WRONG !!!

=?Utf-8?B?UEFDQUxBX0JB?= wrote
in :

BIG-PROBLEM is this wrong-compiler-example
http://i34.tinypic.com/71sdq8.jpg ;


We have not idea what that screenshot means. If you want help,
you're going to have to explain it.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
  #18  
Old October 3rd, 2008, 10:48 PM posted to microsoft.public.access
John W. Vinson
external usenet poster
 
Posts: 18,261
Default COMPILER WRONG !!!

On Thu, 2 Oct 2008 08:22:14 -0700, PACALA_BA
wrote:

Hi, Compile on Demand is OFF
i must allways Run in Debug mode
After Pseudo-Compile-Error, i Rebuild the line strSQL =...
(chr(34) Remove and Add)
Debug-menu : Compile-All,Save
and strSQL is then OK.

The most case is 1-3 Pseudo-Compile-Error
Some times it is Error free.
And than make MDE.
It Runs than dailly over Night (15 Hours)...Error Free !!!
see image --
http://i34.tinypic.com/71sdq8.jpg


OK... so when you export your VBA code to a text file, that text file exeeds
5MByte? Yes, that is awfully big.

It LOOKS like you are either somehow trying to construct VBA labels from
variables - which I would not have thought possible - or you're treating the :
character as a statement delimiter. It isn't; the statement delimiter is a
semicolon ;. The colon (double dot) operator : delimits a statement label from
the statement. This is perhaps why you're getting the undefined label error.

Could you describe briefly what real-life problem this database is intended to
solve, and what role your awfully big VBA routine plays in this purpose?

--

John W. Vinson [MVP]
  #19  
Old October 4th, 2008, 01:13 AM posted to microsoft.public.access
Clif McIrvin[_2_]
external usenet poster
 
Posts: 629
Default COMPILER WRONG !!!

"John W. Vinson" wrote in message
...
On Thu, 2 Oct 2008 08:22:14 -0700, PACALA_BA
wrote:

snip
It LOOKS like you are either somehow trying to construct VBA labels
from
variables - which I would not have thought possible - or you're
treating the :
character as a statement delimiter. It isn't; the statement delimiter
is a
semicolon ;. The colon (double dot) operator : delimits a statement
label from
the statement. This is perhaps why you're getting the undefined label
error.


Whoa, John, you lost me there! the full colon has always been a line
continuation character in MS Basic from the very early days, hasn't it?

Quoting from the installed VBA help file on the If ... Then ... Else
statement:
Note With the single-line form, it is possible to have multiple
statements executed as the result of an If...Then decision. All
statements must be on the same line and separated by colons, as in the
following statement:

If A 10 Then A = A + 1 : B = B + A : C = C + B

--end quote--

I didn't attempt to study Pacala's code; if he has a line with a
non-blank in column 1 and no spaces before the full colon, yes, the
compiler would attempt to make that token into a label.

--
Clif
Could you describe briefly what real-life problem this database is
intended to
solve, and what role your awfully big VBA routine plays in this
purpose?

--

John W. Vinson [MVP]




--
Clif
Still learning Access 2003




  #20  
Old October 4th, 2008, 04:50 AM posted to microsoft.public.access
John W. Vinson
external usenet poster
 
Posts: 18,261
Default COMPILER WRONG !!!

On Fri, 3 Oct 2008 19:13:36 -0500, "Clif McIrvin"
wrote:

Whoa, John, you lost me there! the full colon has always been a line
continuation character in MS Basic from the very early days, hasn't it?


My apologies to you and to PACALA_BA. You're quite right of course.
--

John W. Vinson [MVP]
 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 05:46 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.