xsharp.eu • Some warnings and error - Page 8
Page 8 of 9

Some warnings and error

Posted: Tue Oct 17, 2017 6:22 pm
by Karl-Heinz
Hi Horst,

33 DBSERVER: Data type error

(very) strange ... at least in VO such an error is thrown e.g. when you open an cdx that doesn´t belong to a dbf !

Are you sure, that when you open "useronline.dbf" with a tool like "dbmax" that "useronline.cdx" is opened without an error ?

if the are no sensitive data involved, please post the dbf and cdx.

regards
Karl-Heinz

Some warnings and error

Posted: Tue Oct 17, 2017 7:06 pm
by wriedmann
Hi Horst,

was is the index expression of this order bag (if there are more orders, please show us them all)?

To me it seems like a incompatibility of the order expression with the application.

If you create a small console application, you can open the DBF and search?

Wolfgang

Some warnings and error

Posted: Wed Oct 18, 2017 1:47 pm
by Horst
Thanks for trying to help

As i wrote before it works when i call the cgi from the command prompt but not with the IIS as the caller. So i think its a IIS problem and i cant transform my VO CGI into a .NET CGI.

Later i will try to built a IIS Extension.

Horst

Some warnings and error

Posted: Wed Oct 18, 2017 2:17 pm
by wriedmann
Hi Horst,

unfortunately I'm not a IIS fan - I rather prefer Apache.

And I'm very short on time so I cannot do my own tests with IIS.
Personally I would try to add the Vulcan runtime assemblies as fixed references to your CGI executable and force their loading, maybe calling any Assembly.Load...() static method.

I think that the CGI exe fails to load the Vulcan Macrocompiler at runtime when called from IIS.
The big difference between a VO (Win32) executable and a .NET executable is that the VO executable searches the path for DLLs to load, whereas the .NET executable searches them only in the current directory or in the GAC. And the IIS seems to move the CGI executable somewhere, and load it from there for security reasons.

Wolfgang

Some warnings and error

Posted: Wed Oct 18, 2017 2:48 pm
by Chris
Good point from Wolfgang! Horst, please try loading the macto compiler manually, before you use any dbfs as below:

LOCAL lLoaded AS LOGIC
lLoaded := System.Reflection.Assembly.LoadFile("<path to file>VulcanMacroCompiler.dll") != NULL

Also print the value of lLoaded somewhere does it retunr tru or false when using it throus IIS?

Chris

Some warnings and error

Posted: Wed Oct 18, 2017 4:15 pm
by Horst
Hi Chris

I tried your example. My Logfile say's the DLL is loaded. but the the output is still not sorted. :-(

Horst

Some warnings and error

Posted: Wed Oct 18, 2017 4:18 pm
by Horst
I tried the example form a IIS forum calling the CGI over a CMD file. And then the CGI runs normal like the VO CGI. Finding the DLL in the workdir and also no problem with the index.

into the file is

@echo off
%~dp0logout.exe

What is this -> %~dp0 <- meaning ?

Horst

Some warnings and error

Posted: Wed Oct 18, 2017 4:48 pm
by wriedmann

Some warnings and error

Posted: Thu Oct 19, 2017 4:19 pm
by Horst
:-)

Ja too lazy, no i was not thinking on that ;-)

So the CMD open something like a sandbox and the EXE is executed.

mmmmm is it possible to use X# with ASP.NET instead of C# as language ?

Horst

Some warnings and error

Posted: Thu Feb 06, 2020 5:33 pm
by Horst
Hi
I am back again after XSharp doesnt need Vulcan RT and can use DBF its time for me to use it.
Here, years ago i posted some error and was very happy to found the answers again, because i start again to export my VO App.

But some code is not from me and i dont know how to handle it. This Logic _Cast i dont know how to change.
Does it mean like -> if empty (c) ??

IF(!LOGIC(_CAST, c))
RETURN(c)
ENDIF
// Function
FUNC UnEscape(c AS STRING) AS STRING PASCAL
LOCAL pb AS BYTE PTR
LOCAL i,j AS DWORD
LOCAL l AS DWORD

IF(!LOGIC(_CAST, c))
RETURN(c)
ENDIF

c := StrTran(c, "+", " ")

pb := String2Psz (c)
l := SLen(c)
i := j := 1

WHILE(LOGIC(_CAST, l))

IF pb = 0x25
pb[j] := BYTE(_CAST, _ToDigit(pb+i)*16 + _ToDigit(pb+(i+1)))
j++
i+=3
l -= 2
ELSE
pb[j] := pb
i++
j++
ENDIF
l--
ENDDO

pb[j] := 0
c := Left(c, SLen(String2Psz(c)))

RETURN c

Horst