CorelDRAW Community
Site
Search
User
Site
Search
User
Developer Area
Forums
Wikis
API References
Tags
More
Cancel
New
Developer Area requires membership for participation - click to join
Applications:
Corel DESIGNER
Corel PHOTO-PAINT
CorelDRAW
Versions:
Corel PHOTO-PAINT 2017
Corel PHOTO-PAINT 2018
Corel PHOTO-PAINT 2019
Corel PHOTO-PAINT 2019.2
Corel PHOTO-PAINT 2020
Corel PHOTO-PAINT 2020.1
Corel PHOTO-PAINT 2021
Corel PHOTO-PAINT 2021.5
Corel PHOTO-PAINT 2022-v24
Corel PHOTO-PAINT 2022-v24.1
Corel PHOTO-PAINT 2022-v24.2
Corel PHOTO-PAINT 2023-v24.3
Corel PHOTO-PAINT 2023-v24.5
Corel PHOTO-PAINT 2024-v25
Corel PHOTO-PAINT X7
Corel PHOTO-PAINT X7.4
Corel PHOTO-PAINT X7.6
Corel PHOTO-PAINT X8
Classes:
AIExport
Application
AppWindow
Background
BMPExport
CEPSExport
CGMExport
CGMImport
Channel
Channels
Clipboard
ClipMask
Color
ColorMask
ColorMaskColor
ColorMaskColors
Colors
ColorTable
CommandBar
CommandBarMode
CommandBarModes
CommandBars
Control
Controls
CorelScript
CorelScriptFile
CorelScriptTools
DataContext
DataSourceProxy
DockHost
DockHosts
DockItem
DockItems
Document
Documents
DropShadow
DSFImport
DXFExport
DXFImport
EMFExport
ExportFilter
Floater
Frame
Frames
FrameWindow
FrameWindows
FrameWork
GEMExport
GIFExport
Grid
Guide
Guides
HPGLExport
HPGLImport
ImageList
ImportFilter
JP2Export
JPGExport
Layer
LayerGroup
LayerGroupRange
LayerRange
Layers
Mask
ObjectLayer
Palette
Palettes
PDFVBASettings
PNGExport
PrintDocuments
Printer
PrintJob
PrintLayout
PrintOptions
PrintPages
PrintPostScript
PrintPrepress
PrintSeparations
PrintSettings
PrintTrapping
Rulers
ScreenRect
SeparationPlate
SeparationPlates
StructImportCropOptions
StructImportOptions
StructImportRasterizeOptions
StructImportResampleOptions
StructPaletteOptions
StructSaveOptions
StructWebSaveOptions
SVGExport
SystemPrinters
TGAExport
Tools
TrapLayer
TrapLayers
ViewHost
ViewHosts
ViewWindow
ViewWindows
Window
Windows
WMFExport
Workspace
Workspaces
WPGExport
WVLExport
Interfaces:
DIGlobalDocumentEvents
ICUIAutomation
ICUIControlData
ICUIDataSourceFactory
IGlobalDocument
IGlobalDocumentEvents
IImportCropHandler
IImportRasterizeHandler
IImportResampleHandler
IPaintDocumentEvents
IPrnVBAPrintDocument
IPrnVBAPrintPage
Enums:
AiVersion
BmpVersion
cdrAlignment
cdrColorType
cdrCompressionType
cdrDitherType
cdrDuotoneType
cdrFilter
cdrFittedOrientation
cdrFittedPlacement
cdrFittedQuadrant
cdrFittedVertPlacement
cdrFlipAxes
cdrHalftoneType
cdrImageMode
cdrImagePaletteType
cdrImageType
cdrImportMode
cdrLineSpacingType
cdrMergeMode
cdrPaletteID
cdrPaletteSortMethod
cdrPaletteType
cdrPatternCanvasSize
cdrPatternFillType
cdrRenderType
cdrTexturePropertyType
cdrTileOffsetType
cdrTransparencyAppliedTo
cdrTransparencyType
cdrUnit
cdrViewType
cdrWebSaveMode
cdrWindowArrangeStyle
cdrWindowState
CgmEncoding
CgmFormat
cuiBarPosition
cuiBarProtection
cuiBarType
cuiDockHostOrientation
cuiDockItemType
cuiDockOperation
cuiWindowState
DsfLinestyle
DxfBitmapType
DxfProjections
DxfScale
DxfUnits
DxfVersion
EpsBBoxType
EpsBitmapType
EpsColorProfile
EpsImageHeader
EpsObjectsColorType
EpsPSLevel
EpsSpotToColorType
EpsTIFFHeaderType
GifTransparency
HpglFillType
Jp2Progression
Jp2Subformat
pdfBitmapCompressionType
pdfColorMode
pdfColorProfile
pdfDisplayOnStart
pdfEditPermissions
pdfEncodingType
pdfEncryptionType
pdfEPSAs
pdfExportRange
pdfPrintPermissions
pdfSpotType
pdfTextExportMode
pdfVersion
pltOriginType
PngTransparency
pntAddinFilter
pntAlignType
pntBorderType
pntClipMaskMode
pntColorMaskMode
pntColorMaskType
pntCreationMode
pntDistributeType
pntDropShadowType
pntEdgeType
pntFeatherType
pntFrameBackground
pntFrameReference
pntGuideType
pntLayerType
pntLoadMode
pntMaskBrightnessModel
pntMaskMode
pntMatteType
pntMergeMode
pntSplitMode
pntToleranceMode
pntURLRegion
PrnBitmapColorMode
PrnColorMode
PrnFileMode
PrnImageTrap
PrnObjectsColorMode
PrnPageMatchingMode
PrnPageSet
PrnPaperOrientation
PrnPaperSize
PrnPDFStartup
PrnPlaceType
PrnPlateType
PrnPostScriptLevel
PrnPrintRange
PrnRegistrationStyle
PrnTrapType
SvgBmpExportType
SvgCharacterSubsetting
SvgDrawingPrecision
SvgEncoding
SvgStyling
SvgUnits
SvgVersion
TgaVersion
WiPath
WiSpeed
WpgColorMode
WpgVersion
C++/CLI
C++
C#
VB
VBA
API Documentation
>
Corel PHOTO-PAINT
>
X7.4
>
CorelScript
>
ICorelScript
CorelScript.FileNew method
Syntax:
void
FileNew
(
int
Width
,
int
Height
,
int
Type
,
int
HRes
,
int
VRes
,
VARIANT_BOOL
PartialFile
,
VARIANT_BOOL
MovieFile
,
int
NumberFrames
,
int
Left
,
int
Top
,
int
Right
,
int
Bottom
,
int
Color1
,
int
Color2
,
int
Color3
,
int
Color4
,
VARIANT_BOOL
Background
);
Parameters:
Name
Type
Description
Width
int
Specifies the width of the new image, in pixels
Height
int
Specifies the height of the new image, in pixels
Type
int
Specifies the image type:
HRes
int
Specifies the horizontal resolution of the new image, in dots per inch (dpi)
VRes
int
Specifies the vertical resolution of the new image, in dots per inch (dpi)
PartialFile
VARIANT_BOOL
Specifies whether to load a partial area of the image. A value of
True
(
-1
) loads a partial area of the image, letting you work on separate areas of the image without opening the entire file. A value of
False
(
0
) loads the whole file.
Note: If this parameter is enabled, the new file cannot be a movie file.
MovieFile
VARIANT_BOOL
Specifies whether to open the new image as a movie file. A value of
True
(
-1
) opens the image as a movie file, while a value of
False
(
0
) does not.
Note: If the image is opened as a movie file, the
PartialFile
parameter is disabled.
NumberFrames
int
Specifies the number of frames for the movie file to contain.
Note: This parameter is enabled only if the
MovieFile
parameter is enabled.
Left
int
Specifies, in pixels and relative to the origin, the x-coordinate of the upper-left corner of the image's bounding box. (This parameter applies only if the new image is a partial file.)
Top
int
Specifies, in pixels and relative to the origin, the y-coordinate of the upper-left corner of the image's bounding box. (This parameter applies only if the new image is a partial file.)
Right
int
Specifies, in pixels and relative to the origin, the x-coordinate of the lower-right corner of the image's bounding box. (This parameter applies only if the new image is a partial file.)
Bottom
int
Specifies, in pixels and relative to the origin, the y-coordinate of the lower-right corner of the image's bounding box. (This parameter applies only if the new image is a partial file.)
Color1
int
Specifies the first color component for the
Type
parameter. For example,
Red
is the first color component for RGB.
Color2
int
Specifies the second color component for the
Type
parameter. For example,
Green
is the second color component for RGB. If this parameter is not available in the color model specified, set it to
0
.
Color3
int
Specifies the third color component for the
Type
parameter. For example,
Blue
is the third color component for RGB. If this parameter is not available in the color model specified, set it to
0
.
Color4
int
Specifies the fourth color component for the
Type
parameter. For example,
Black
is the fourth color component for CMYK. If this parameter is not available in the color model specified, set it to
0
.
Background
VARIANT_BOOL
Specifies whether to include a background. A value of
True
(
-1
) includes a background, while
False
(
0
) does not.
Remarks:
The
FileNew
method defines the characteristics of a new image.
Version Information:
Corel PHOTO-PAINT:
X7.4
,
X7
,
X7.6
,
X8
,
2017
,
2018
,
2019
,
2019.2
,
2020
,
2021
,
2020.1
,
2021.5
,
2022-v24
,
2022-v24.1
,
2022-v24.2
,
2023-v24.3
,
2023-v24.5
,
2024-v25