Support > General Discussions

Embedding into application

(1/4) > >>

Bill:
I have managed to compile ScriptBasic using MinGW on windows XP.
I ahve written a simple application and embedded the scriba.a library into the application as per instructions. However upon starting from the MinGW console The following message appears and the application refuses to start:


--- Code: ---<HTML><HEAD>
<title>Error page, syntax error</title>
</HEAD><BODY>
<H1>Error has happened in the code</H1><pre>
(0): error &H50:Internal error or the cached code is corrupt
--- End code ---


Can anyone help me as to what the problem is?

Support:
Bill,

I haven't gotten into the embedding ScriptBasic but I'll try to help. My first question is where is the HTML coming from? Is this a CGI application? Can you provide more details to what your trying to do?

John

Bill:
John,

The message comes from the scriba library - report.c to be exact. I only see this message because I started the application from a dos box. The app itself does not start. I assume that something within scriba could not be initialized.

Zulfi.Ali:
Hi,

I have finally managed to embed ScriptBasic into my VC8 application... Now, how can I redirect the output of the PRINT statements inside my script to the output window of my IDE or to another window so that I can debug my basic script?

I am guessing it has something to do with scriba_SetStdout() function but I am not sure of the windows callback function that I need to pass.

Help needed!!

Support:

--- Quote from: ScriptBasic Developer Docs ---You can call this function to define a special standard output function. This pointer should point to a function that accepts a (char, void *) arguments. Whenever the ScriptBasic program tries to send a character to the standard output it calls this function. The first parameter is the character to write, the second is the embedder pointer.

If the standard output function is not defined or the parameter is NULL the interpreter will write the normal stdout stream.

void scriba_SetStdout(pSbProgram pProgram,
                      void *fpStdoutFunction
  ){

--- End quote ---
Embedding the Interpreter

Navigation

[0] Message Index

[#] Next page

Go to full version