473,473 Members | 1,425 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Question: anyone know a way to get a 'CanGrow' feature to work for images in a report?

Hi all,
I am generating a report that adds one of two images (or no image at
all) depending on query results. I dont want a great big blank space
where the image goes, if NO IMAGE is returned..... Any way I can do
this? I know I cannot use 'can grow' as I do with text boxes.
any help appreciated.
andy
Nov 12 '05 #1
3 1585
Andy,
You can define the height of your ImageControl on runtime.
Put code like this is the Reports detail OnFormat event (assuming your ImageControl is in this
section)
So if there is an image present (then you will have a path or so) then
Me!ImageControl.Height=xxx 'specify in twips!
else
Me!ImageControl.Height=0
end if

--
Hope this helps
Arno R
"Andy Warner" <aw*****@worcestershire.gov.uk> schreef in bericht
news:7b**************************@posting.google.c om...
Hi all,
I am generating a report that adds one of two images (or no image at
all) depending on query results. I dont want a great big blank space
where the image goes, if NO IMAGE is returned..... Any way I can do
this? I know I cannot use 'can grow' as I do with text boxes.
any help appreciated.
andy

Nov 12 '05 #2


Thanks for the feedback.

Thats the way I was going, but VBA is new to me, and I don;t really know
how to do checking to see if the image is there bit. The control.height=
bit is ok.

If i try to do the following:

if map_flag = "true" then
Me.MapFrame.height = 3000
else
Me.MapFrame.height = 0
end if

I get an error 'cannot find map_flag'

I think I need to declare it somewhere, but how, and where?
I have text fields in the report that happily check map_flag and it
works, so I am a bit stuck. Any good online resources about this kind of
thing?

thanks for your help, its appreciated

andy


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 12 '05 #3
Andy,
You told us you were depending on query results to define if images are returned...
Then you must have a field in your query that defines this, right?
Is this a boolean (Yes/No) field or do you look for a stringvalue (the path to your image)?
(Remember: Don't store the images IN your database. Huge bloat will be the penalty for this.)
Anyhow, you will need this field in your report (maybe invisible) and then use the code.
IMHO the error you got means thet you don't have this field in your reportdesign.

I guess your field is called map_flag ?
You will need to 'tell' every page of your Report that map_flag = true or false.
If map-flag is boolean then also your code is wrong
It should read
if map_flag = true then
....

--
Hope this helps
Arno R
"Andy Warner" <aw*****@worcestershire.gov.uk> schreef in bericht
news:3f***********************@news.frii.net...


Thanks for the feedback.

Thats the way I was going, but VBA is new to me, and I don;t really know
how to do checking to see if the image is there bit. The control.height=
bit is ok.

If i try to do the following:

if map_flag = "true" then
Me.MapFrame.height = 3000
else
Me.MapFrame.height = 0
end if

I get an error 'cannot find map_flag'

I think I need to declare it somewhere, but how, and where?
I have text fields in the report that happily check map_flag and it
works, so I am a bit stuck. Any good online resources about this kind of
thing?

thanks for your help, its appreciated

andy


*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Nov 12 '05 #4

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

Similar topics

1
by: Allen | last post by:
I am trying to add an additional photo/hyperlink to the company web site (I didn't create it) without any luck. The mouseover feature 'highlights' pics by swapping them with another pic using this...
2
by: Wally | last post by:
Hi All, I'm using Stephan Lebans' nifty code for automatically resizing text fields to the size required to show (almost) all text in that field (CanGrow3, thanks Stephen!). In general this...
5
by: Erwin | last post by:
At the moment I'm using a report which contains an indicator to show if a Service group of the company isn't working well or is working perfectly. This indicator is a "*" which looks like a traffic...
7
by: e | last post by:
I've been having an extremely difficult time finding an answer to this in IE / js groups, so I thought I'd try here. I've got an aspx page that delivers loads of report data into custom-named...
2
by: Crimson* | last post by:
I've got a table with an entry type as "OLE Object" in Access 2003. In the form that the table is linked to I want to insert an image (BMP) for each record. However, when I attempt to do so the...
3
by: jige | last post by:
All textboxes across the record are set to CanGrow, in the details section of a continuous subform of a report, yet different fields grow to varying heights and messy borders. Is it possible to...
22
by: petermichaux | last post by:
Hi, I would like to display a message to Internet Explorer clients to encorage them to get Firefox. Yes they may like Internet Explorer but it is my site :) http://www.explorerdestroyer.com/...
23
by: SaraLeePerson | last post by:
Dear group, I am seeking a easy to maintain and more importantly *working* way to pre-fetch images, so the pages I develop load smoothly without seeing the images kick in flicker as they usually...
3
by: H. S. Lahman | last post by:
Responding to siddharthkhare... Ignore Topmind and frebe. They are anti-OO P/R guys. Let's not confuse things with specific 3GL syntax. At the OOA/D level the model looks like: | 1
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
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,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
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...
0
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,...
1
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...
0
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...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
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 ...

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.