FoxPro table didn't open in X# FoxPro Console
FoxPro table didn't open in X# FoxPro Console
Karl-Heinz,
Can you show the code ?
Are you specifying the dialect when compiling or are you changing the dialect in the runtime state (which gets set by the compiler).
Robert
Can you show the code ?
Are you specifying the dialect when compiling or are you changing the dialect in the runtime state (which gets set by the compiler).
Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
The Netherlands
robert@xsharp.eu
FoxPro table didn't open in X# FoxPro Console
Cecil, please include the new files.
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
FoxPro table didn't open in X# FoxPro Console
Cecil,
I think this was a problem in 2.0.8
In my current version 2.10 (which will be released asap) I am running this:
And the result is
Robert
I think this was a problem in 2.0.8
In my current version 2.10 (which will be released asap) I am running this:
Code: Select all
RddSetDefault("DBFVFP")
DbUseArea(FALSE,,"C:TestAddress.dbf")
LOCAL i AS INT
FOR i := 1 TO OrderCount()
? i, OrdKey(i), OrdFor(i)
NEXT
DbCLoseArea()
RETURN
Code: Select all
1 DELETED()
2 id
3 lastupdate
4 RECNO()
5 UPPER(city)+UPPER(lastname)
6 country
7 UPPER(emailaddr)
8 UPPER(contact)
9 hphn
10 UPPER(lastname)+UPPER(firstname)
11 UPPER(title)
12 UPPER(website)
13 wphn
14 UPPER(firstname)
15 UPPER(state)+UPPER(city)
XSharp Development Team
The Netherlands
robert@xsharp.eu
The Netherlands
robert@xsharp.eu
- cecilchamp
- Posts: 49
- Joined: Wed Jun 12, 2019 1:44 pm
FoxPro table didn't open in X# FoxPro Console
Here is the current code:
I didn't add any records to the zipped file's table this time. I also removed the ID index TAG.
I didn't add any records to the zipped file's table this time. I also removed the ID index TAG.
Code: Select all
USING System
USING System.Collections.Generic
USING System.Linq
USING System.Text
#command SET DEFAULT TO <path> => SetDefault(<path>)
FUNCTION Start() AS VOID STRICT
LOCAL i AS INT
SET DEFAULT TO "C:addrdata"
SELECT 0
USE Address
SCAN for LastName = "Champenois"
? LastName, FirstName, City, Country
ENDSCAN
WAIT
*? RddSetDefault()
*WAIT
SELECT Address
USE
RETURN
- Attachments
-
- Address.zip
- (1.27 KiB) Downloaded 68 times
FoxPro table didn't open in X# FoxPro Console
Thanks, as Robert says this one works fine here, so it must be a problem fixed in the previous weeks. It shuld work for you as well as soon as the new build is released.
But the (previous) version of the index with "ID" in it still does not work, so it is a bug. Will log this, thanks for your help with testing and finding this!
But the (previous) version of the index with "ID" in it still does not work, so it is a bug. Will log this, thanks for your help with testing and finding this!
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
- cecilchamp
- Posts: 49
- Joined: Wed Jun 12, 2019 1:44 pm
FoxPro table didn't open in X# FoxPro Console
No problem. I hope ultimately that the testing helps to find any issues that need to be resolved.
FoxPro table didn't open in X# FoxPro Console
Absolutely!cecilchamp wrote:No problem. I hope ultimately that the testing helps to find any issues that need to be resolved.
Chris Pyrgas
XSharp Development Team
chris(at)xsharp.eu
XSharp Development Team
chris(at)xsharp.eu
-
- Posts: 774
- Joined: Wed May 17, 2017 8:50 am
- Location: Germany
FoxPro table didn't open in X# FoxPro Console
i select a dialect, compile and run the code. Each time <xbase++> is selected RddSetdefault() returns "DBFNTX", while the other 3 dialects show "DBFVFP"robert wrote:Karl-Heinz,
Can you show the code ?
Are you specifying the dialect when compiling or are you changing the dialect in the runtime state (which gets set by the compiler).
Robert
Code: Select all
FUNCTION Start( ) AS VOID
? RddSetDefault()
RETURN
Karl-Heinz
FoxPro table didn't open in X# FoxPro Console
Karl-Heinz,
This is because in the Xbase++ dialect the entry point is called main(). If you change the function name from Start to Main() then it will work as expected.
If you add the following to the code you will also see that the dialect is not properly set if you compile for Xbase++ and name the entry point Start:
? Runtimestate.Dialect:ToString()
The compiler does create the $AppInit() code but does not call that at startup.
If you call the entry point main, then the compiler will generate a start function and will call the $AppInit() code there and will call main from within this start function.
I will see if I can fix that in one of the next builds.
Robert
This is because in the Xbase++ dialect the entry point is called main(). If you change the function name from Start to Main() then it will work as expected.
If you add the following to the code you will also see that the dialect is not properly set if you compile for Xbase++ and name the entry point Start:
? Runtimestate.Dialect:ToString()
The compiler does create the $AppInit() code but does not call that at startup.
If you call the entry point main, then the compiler will generate a start function and will call the $AppInit() code there and will call main from within this start function.
I will see if I can fix that in one of the next builds.
Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
The Netherlands
robert@xsharp.eu
- cecilchamp
- Posts: 49
- Joined: Wed Jun 12, 2019 1:44 pm
FoxPro table didn't open in X# FoxPro Console
Code: Select all
USING System
USING System.Collections.Generic
USING System.Linq
USING System.Text
#command SET DEFAULT TO <path> => SetDefault(<path>)
*#command SET DEFAULT TO <(path)> => SetDefault(<(path)>)
FUNCTION Start() AS VOID STRICT
LOCAL i AS INT
SET DEFAULT TO C:addrdata
SELECT 0
USE names
SCAN for LastName = "Champenois"
? LastName, FirstName
ENDSCAN
WAIT
SELECT Names
USE
RETURN