Problems with Fseek3 in X# 2.7

This forum is meant for questions and discussions about the X# language and tools
User avatar
ArneOrtlinghaus
Posts: 412
Joined: Tue Nov 10, 2015 7:48 am
Location: Italy

Problems with Fseek3 in X# 2.7

Post by ArneOrtlinghaus »

I have installed the new version. I have now problems with file reading text files.
FSeek3 returns -1 for the following two values for a file that can be opened normally.
_nFileLength := FSeek3 (_nOutfile, 0, FS_END)
_nPosFile := FSeek3 (_nOutfile, 0, FS_SET)
The command DosErrString(FError()) does report that everything was ok (according to Windows).
Shall I make a sample program?

Arne
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

Problems with Fseek3 in X# 2.7

Post by robert »

Arne,
This is a known issue.
I'll may you a link to a new XSharp.Core.DLL
You can also change the code to:
FSeek3 (_nOutfile, 0, FS_END)
_nFileLength := FTell(_nOutfile)
FSeek3 (_nOutfile, 0, FS_SET)
_nPosFile := FTell(_nOutfile)

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
User avatar
ArneOrtlinghaus
Posts: 412
Joined: Tue Nov 10, 2015 7:48 am
Location: Italy

Problems with Fseek3 in X# 2.7

Post by ArneOrtlinghaus »

This was a quick answer! I imagined a response somewhere between midnight and 3:00 am this night and not within minutes :-)
Thanks for the new dll. It solves my issue.

The cloning of VO windows in VS works very well.

Arne
markus.lorenzi@dvbern.ch
Posts: 114
Joined: Mon May 02, 2016 9:10 am
Location: Schweiz

Problems with Fseek3 in X# 2.7

Post by markus.lorenzi@dvbern.ch »

Hi Robert
could you send me this fixed dll too?
Thanks Markus
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

Problems with Fseek3 in X# 2.7

Post by robert »

Markus, Others:

https://www.xsharp.eu/itm-downloads/dow ... e.2.7a.zip

Instructions are inside the ZIP file.

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
ic2
Posts: 1858
Joined: Sun Feb 28, 2016 11:30 pm
Location: Holland

Problems with Fseek3 in X# 2.7

Post by ic2 »

Hello Robert,
robert wrote:Markus, Others:
Instructions are inside the ZIP file.
As I have a new Pc I decided to install the 2.7 X# version. There's a 2.7a where your above remark was for.

Probably the rest of the X# community is doing nothing else the whole day than "registering DLL's in the GAC" but I don't know what I have to do for that. And honestly, I don't want to know actually.

I found a Gacutil.exe in C:Program Files (x86)Microsoft SDKsWindowsv10.0AbinNETFX 4.8 Tools. But what do now?

And more important:
1 Why has the original installer not been updated with the changed DLL (it looks like the DLL in 2.7a is newer)?
2 Why is the only "explanation" - Register XSharp.Core.DLL in the GAC ?

Installing X# 2.7 now takes much more time than I was willing to spend to it.

Dick
User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

Problems with Fseek3 in X# 2.7

Post by Chris »

Hi Dick,

Easiest way is to simply copy the file directly here:

C:WindowsMicrosoft.NETassemblyGAC_MSILXSharp.Corev4.0_2.6.0.0__ed555a0467764586

Also don't forget to copy it to <XSharp>Redist and <XSharp>Assemblies
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
ic2
Posts: 1858
Joined: Sun Feb 28, 2016 11:30 pm
Location: Holland

Problems with Fseek3 in X# 2.7

Post by ic2 »

Hello Chris,

Thanks; I did copy it; remarkable fact was that there was only 1 file XSharp.Core.dll, change date last night and 740 kB, now 732 Kb.

But I still think the original setup should have been adapted. X# installation has always been very easy and trouble free and this 2.7a change definitely is not. Or a new full setup 2.7a could have been posted. Not sure how you create setups but when I do so for any product posting 2 changed DLL's with an incomplete readme.txt would take more time than recreating a setup with the necessary content.

Dick
User avatar
Chris
Posts: 4906
Joined: Thu Oct 08, 2015 7:48 am
Location: Greece

Problems with Fseek3 in X# 2.7

Post by Chris »

Hi Dick,

Oh, come on now, how much time does it take to copy one dll file in 3 folders in the disk?

The problem with creating complete installers just for such small fixes is that a new installer needs A LOT of testing, as so many things can go wrong. It's very difficult to include just this one fix, development is ongoing every day, so a lot more files are changed in our dev machines, which all be included in the installer.

And of course there's a lot of time involved in publishing the new installer, posting a "formal" message about it, writing a more detailed readme etc etc. And if we did that for all the small fixes we make and send to developers, we would end up not doing anything else all day. Possibly in the future there will be automated new installers (to use at your own risk!), but I think a small dll upload will always be the easiest and safest option.
Chris Pyrgas

XSharp Development Team
chris(at)xsharp.eu
User avatar
robert
Posts: 4520
Joined: Fri Aug 21, 2015 10:57 am
Location: Netherlands

Problems with Fseek3 in X# 2.7

Post by robert »

Dick,

Actually creating the ZIP was much faster than doing a complete new installer. To do the installer we would have to roll back all changes since the last release, except for the change in the macro compiler, recompile everything, signing all assemblies and creating the installer. Then of course testing the installer on several (virtual) machines with different OS and VS setups etc.

And really, any developer that develops for .Net should be aware of the GAC and should know how to install DLLs in the GAC. This is a MUST .

I am sure you can find plenty of videos on Youtube explaining you this.
If you want we can also spend some time on the GAC in one of our next online sessions (together with the Jit compiler and NGen).

Robert
XSharp Development Team
The Netherlands
robert@xsharp.eu
Post Reply