473,657 Members | 2,515 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Image access problem

Hi,

I have a problem with image access. I load a file:

MyBitmap = New Bitmap("test.jp g")

After that the user presses the appropriate button in order to replace the
image with a new one:

MyBitmap.Save(L astPlayedGame & ".jpg",
System.Drawing. Imaging.ImageFo rmat.Jpeg)

The error message says that the the file is used by an other process??????

What should I do in order to release the file after loading the image?

Aristotelis
Jul 13 '06 #1
4 1091
"Aristoteli s Pitaridis" <pi*******@hotm ail.comschrieb:
MyBitmap.Save(L astPlayedGame & ".jpg",
System.Drawing. Imaging.ImageFo rmat.Jpeg)

The error message says that the the file is used by an other process??????
<URL:http://dotnet.mvps.org/dotnet/code/graphics/#ImageNoLock>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jul 13 '06 #2
Thank's.

It was a bit difficult for me to understund it because it was in german but
finally I made it work.

Aristotelis

? "Herfried K. Wagner [MVP]" <hi************ ***@gmx.at???a? e st? µ???µa
news:eG******** ******@TK2MSFTN GP05.phx.gbl...
>
"Aristoteli s Pitaridis" <pi*******@hotm ail.comschrieb:
>MyBitmap.Save( LastPlayedGame & ".jpg",
System.Drawing .Imaging.ImageF ormat.Jpeg)

The error message says that the the file is used by an other
process????? ?

<URL:http://dotnet.mvps.org/dotnet/code/graphics/#ImageNoLock>

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jul 13 '06 #3
"Aristoteli s Pitaridis" <pi*******@hotm ail.comschrieb:
It was a bit difficult for me to understund it because it was in german
but finally I made it work.
Great -- VB.NET is the language everybody speaks in this group :-).

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jul 13 '06 #4
I am sure about this. I do not speak very good language. My native language
is Greek.

Thanks again

? "Herfried K. Wagner [MVP]" <hi************ ***@gmx.at???a? e st? µ???µa
news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
>
"Aristoteli s Pitaridis" <pi*******@hotm ail.comschrieb:
>It was a bit difficult for me to understund it because it was in german
but finally I made it work.

Great -- VB.NET is the language everybody speaks in this group :-).

--
M S Herfried K. Wagner
M V P <URL:http://dotnet.mvps.org/>
V B <URL:http://classicvb.org/petition/>

Jul 14 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1805
by: Ohaya | last post by:
Hi, We've been having a problem with one particular page that has a button on it, and a "tall" image (top-to-bottom). The button calls some simple Javascript to print the frame in which the image is located, and what is happening in the field is that the image only gets partly printed. Only the first page gets printed, and the bottom of the image, which should get printed on a 2nd page, is not printed. Also, the bottom of the first...
1
2700
by: Veetold | last post by:
The solution you suggested works very good - thanks again. I encountered a new problem related to this topic. According to your advise I put the following line to print and format event: Me.BookCover.Picture = IIf(Me.IsCover= true, Me.BookCoverPath, "") to avoid problems when the file specified in field does not exist I add a logical field to source table: indicating physical presence of the file. Surprisingly when there is no file ...
1
1761
by: Rob Parker | last post by:
I posted this with a different subject line (in two posts - I added additional info in the second) in this newsgroup a few days ago, but haven't had a single response. Hopefully, that was because I posted at the weekend, and the experts were all having a well-earned rest and missed it first time around. I'm hoping someone here can help - I've had no joy in other avenues. Now to the problem: Using Access 2002: I have downloaded a...
1
7038
by: Jason | last post by:
For some reason, most but not all reports printing from an access application our client is using will not print any images on the reports or forms. One report will print the image and data correctly oddly enough. The image header is embedded using the Insert Image feature and not loaded into a database. I can move the image to anywhere in the report and still it will not print out. I've loaded the most recent printer drivers and...
3
4360
by: Sandi | last post by:
I have a simple problem: I have an Access database (images.mdb) that has 2 columns: one is the id if the picture (an integer) and one (column named picture) is a field of type OLE Object which contains an image (it can store jpg, bmp, gif, but I don't know what image is stored inside). I want to retrieve the picture stored in the database and identified by a given id and display it in a web page (.aspx). I write in Visual C#, but it does...
1
2890
by: Eric Keung | last post by:
Hi all, my case is I want to get an image from access database and I just know it's "OLE object" field type at access I also don't know how to insert it into access here is my code and it just can display a invalid image try dim strConn as string strConn = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & server.mappath
13
2345
by: Neo Geshel | last post by:
I have examined about 80+ different upload scripts on the 'net, both in VB and C#, and none seem to do what I need them to do. Perhaps someone here can point me somewhere that Google hasn't reached yet (I have gone all the way to page 50 on Google's results!!). Here are my requirements: • I have a DataGrid. Everything will be done from here. Everything. No exceptions. Everything will also be done in VB, without any code-behind to...
1
9498
by: Brian | last post by:
Using A2K I have an image control on a report and use code to set the image.picture to the required jpg. 3 of the jpgs resize properly but 2 do not - they display much smaller than the image control. The problem jpgs were originally created as line drawings in Word. They were then copy and pasted to Paint where they were saved as jpg files. Sizemode is set to stretch.(have tried clip and zoom but no better). I cannot find any way to...
7
10108
by: needin4mation | last post by:
Hi, I have an Access 2002 - 2003 database. I am using Access 2003. Whenever I link an image all it shows is the filename. Not the image. Other versions of Access can link the image just fine. The properties look the same whether I use XP or 2003 versions of Office. If I take an earlier version of Access and link the image, it puts the image. I can also see the image in 2003. If I link the image using 2003 it only shows the filename....
1
1569
by: ApexData | last post by:
Hello I am in the early stages of my project development, and want to make sure that I am approaching the issue of image display correctly. Access2000. I have one table and a bound single form. I would like to have one image (.bmp 100k or .jpg 30k) displayed on the form for each record. I am using an ImageFrame to display my image, and the following code to link the image to the display:
0
8413
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8842
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8617
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7352
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6176
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5642
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
2742
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
1970
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1733
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.