Error in the function: DC_Scrn2ImageFile
- Eugene Lutsenko
- Posts: 1649
- Joined: Sat Feb 04, 2012 2:23 am
- Location: Russia, Southern federal district, city of Krasnodar
- Contact:
Error in the function: DC_Scrn2ImageFile
Perhaps I somehow not appeal to her. But what exactly should be done to use this feature? Previously, it worked fine, but I used XbpPresSpace()
- Attachments
-
- err1.jpg (110.49 KiB) Viewed 8439 times
Re: Error in the function: DC_Scrn2ImageFile
You must pass an Xbase++ parts object as the first parameter.
This is usually the dialog object or the drawingarea of the dialog object.
Example:
It appears that I never documented DC_Scrn2ImageFile().
I will correct this in build 264.
This is usually the dialog object or the drawingarea of the dialog object.
Example:
Code: Select all
@ 10,10 DCSAY 'Hello World'
DCREAD GUI EVAL {|o| DC_Scrn2ImageFile(o:drawingArea,'MyScreen.Jpg',XBPBMP_FORMAT_JPG)}
I will correct this in build 264.
The eXpress train is coming - and it has more cars.
- Eugene Lutsenko
- Posts: 1649
- Joined: Sat Feb 04, 2012 2:23 am
- Location: Russia, Southern federal district, city of Krasnodar
- Contact:
Re: Error in the function: DC_Scrn2ImageFile
Hey, Roger!
In this embodiment, the function creates a new empty window, which successfully writes to a file.
And if the window is already open, and it has created the image, how to write it?
The strange thing is that I can say stumbled on Pustomiti place, ie where I did not expect. The fact that this function I used successfully many times before without any problems. What a great thank you. Function call was about:
In this embodiment, the function creates a new empty window, which successfully writes to a file.
And if the window is already open, and it has created the image, how to write it?
The strange thing is that I can say stumbled on Pustomiti place, ie where I did not expect. The fact that this function I used successfully many times before without any problems. What a great thank you. Function call was about:
Code: Select all
DIRCHANGE(M_PathAppl+"\ParetoGrOpSc\") // Перейти в папку ParetoGrOpSc
cFileName = "ParetoGrOpSc-"+UPPER(Ar_Model[mNumMod])+".bmp"
ERASE(cFileName)
DC_Scrn2ImageFile( oStatic, cFileName )
DIRCHANGE(M_PathAppl) // Перейти в папку текущего приложения
Re: Error in the function: DC_Scrn2ImageFile
You are getting an error because oStatic is not an object.
I suggest adding a debug command to see if I am correct about this.
I suggest adding a debug command to see if I am correct about this.
Code: Select all
DIRCHANGE(M_PathAppl+"\ParetoGrOpSc\") // Перейти в папку ParetoGrOpSc
cFileName = "ParetoGrOpSc-"+UPPER(Ar_Model[mNumMod])+".bmp"
ERASE(cFileName)
WTF oStatic PAUSE <<<<<<<<<<<<<<<<<<<<<<<<
DC_Scrn2ImageFile( oStatic, cFileName )
The eXpress train is coming - and it has more cars.
- Eugene Lutsenko
- Posts: 1649
- Joined: Sat Feb 04, 2012 2:23 am
- Location: Russia, Southern federal district, city of Krasnodar
- Contact:
Re: Error in the function: DC_Scrn2ImageFile
INSERT command. There is a message:
- Attachments
-
- err.jpg (167.83 KiB) Viewed 8405 times
Re: Error in the function: DC_Scrn2ImageFile
I am correct. oStatic is a logical .F., not an object.
You need to look at what you are passing to the function.
You need to look at what you are passing to the function.
The eXpress train is coming - and it has more cars.
- Eugene Lutsenko
- Posts: 1649
- Joined: Sat Feb 04, 2012 2:23 am
- Location: Russia, Southern federal district, city of Krasnodar
- Contact:
Re: Error in the function: DC_Scrn2ImageFile
I looked at as a graphical object is created in your example:
DREAD GUI FIT TITLE '4.8. Geokognitivnaya subsystem "Eidos" 'OPTIONS GetOptions; EVAL {|| GraTest (oStatic1)} SETAPPWINDOW
It uses a variable: oStatic1. I used it in DC_Scrn2ImageFile (oStatic1, cFileName) and it worked! Many thanks for the tip where and what to look for.
DREAD GUI FIT TITLE '4.8. Geokognitivnaya subsystem "Eidos" 'OPTIONS GetOptions; EVAL {|| GraTest (oStatic1)} SETAPPWINDOW
It uses a variable: oStatic1. I used it in DC_Scrn2ImageFile (oStatic1, cFileName) and it worked! Many thanks for the tip where and what to look for.