473,396 Members | 1,990 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Background Image drawing

Aku

Hello,

In my C# app I put a background image (.jpg) via the Properties
attributes.
The image appears several times, tiled - so if you resized the dialog,
more will appear!
This is not what I wanted; I meant to get one image, and it should be
stretched to full window size and automaticallly resize along with the
form.
Can you advise me please.
Thanks.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 16 '05 #1
1 2873
Hi Aku,
if you want to draw a background image, you can override OnPaintBackground
method, and then use the
PaintEventArgs.Graphics.Draw method

You can store the image you want to draw in a private member of your class,
then pass it as a parameter to the Draw method. The image will be drawn
stretched, obviously ;)

HTH,
Mephiston
"Aku" <an*******@devdex.com> ha scritto nel messaggio
news:eJ**************@TK2MSFTNGP11.phx.gbl...

Hello,

In my C# app I put a background image (.jpg) via the Properties
attributes.
The image appears several times, tiled - so if you resized the dialog,
more will appear!
This is not what I wanted; I meant to get one image, and it should be
stretched to full window size and automaticallly resize along with the
form.
Can you advise me please.
Thanks.
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 16 '05 #2

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

Similar topics

3
by: D. Alvarado | last post by:
Hello, I have a background repeating image <table style="background-image: url('../images/KJV-BAND_SLICED_03.gif');" ... Is there any way I can specify the size of this image? OBviously, the...
8
by: Matt | last post by:
I've been searching around for a simple way to display a background image in my MDI form's client area. I want to be able to load the image from file on start up and have it resize as the MDI form...
0
by: news.sunsite.dk | last post by:
Hi all, I'm working on a windows application, thats essentially a drawing program. I'm not the original developer on it and have a few problems with the MetaDraw component. Upon creation of a...
0
by: Jesper Rou | last post by:
Hi all, I'm working on a windows application, thats essentially a drawing program. I'm not the original developer on it and have a few problems with the MetaDraw component. Upon creation of a...
16
by: stevedude | last post by:
CSS newbie again. I have a problem trying to get coffee mug images within anchor tags to center with my link text for a vertical list menu. If I use the horizontal/vertical properties of...
4
by: GArlington | last post by:
I am trying to implement an image map (in this particular case a country map) with few <area ...>s on it. The challenge is to add background image (dot) to each <areaso it will display over the...
4
by: =?Utf-8?B?UGF0cmlja1M=?= | last post by:
I'd like to be able to give a treeview in my application a nice smooth gradient as a background image, but I'm having trouble doing this. Webpages that I've seen so far seem to suggest using the...
2
by: slg | last post by:
iam looking for code snippet or a sample of drawing background image for a c# treeview control. I tried following but i could not see the tree nodes only the ellipse shows up. TIA public...
2
by: thephatp | last post by:
I'm having a problem with IE rendering correctly. I'm experimenting with using all div's in my pages now, and I'm not very familiar with the quirks of IE. I have created a sample page, and I'm...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
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...

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.