Saving Pictures on a Hard Drive

The 1C:Enterprise developers forum

#1
People who like this:0Yes/0No
Active user
Rating: 3
Joined: Jul 20, 2011
Company:

Saving pictures on a hard drive, creating directories by Goods catalog items descriptions and saving related pictures in those directories.
To create a directory I use CreateDirectory() function, but how to save a picture in that directory?

 
#2
People who like this:0Yes/0No
Active user
Rating: 3
Joined: Sep 16, 2011
Company: individual

First you need to get a picture from the ValueStorage:
<ValueStorageAttribute>.Get()
Next see the Syntax Assistant for the Picture object Write() method:
Picture.Write
Syntax:
Write(<FileName>)
Parameters:
<FileName> (required)
Type: String.
The full file name of the picture to be saved. If no directory name is specified, the picture will be saved in the directory of executable program files.
Description:
You can use it to write a picture to a file with a specified name.
Availability:
Thin client, web-client, server, thick client, external connection.
Example:
Picture.Write("C:\My Documents\My Pictures\home.bmp");

 
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)
Be the first to know tips & tricks on business application development!

A confirmation e-mail has been sent to the e-mail address you provided .

Click the link in the e-mail to confirm and activate the subscription.