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

Home Posts Topics Members FAQ

Help with formating memo fld for correct output in form

1 New Member
Hello,
I am somewhat new to Access and vba, but am trying to complete a request that has been made of me. Access version 2002 WindowsXP.

At this point these text boxes are bound to the table memo field. I have located Stephen Lebans code to limit enter of text field based on characters entered and code to limit text based upon width of a text box (this seems to be most applicable for single line text box). I am have trouble putting everything together.

The objective is: to have a single page report with in which the field size will not shrink or grow and the report page will not shrink or grow to that the specific fields on the report will appear in the same position regardless of amount data entered. The data entry must be restricted at the form level so that the report will appear correctly. The report should also appear as formatted was it was entered in the form (without lines that have wrapped from the line above).

Where I have run into problems is that when I entered text in the form and then ran the report the lines in the report are not wrapping the same as the lines in the form. Both the form and the report are formatted to Verdana 10 pt. and I have played with sizing the width of the field on the form and the report; however, a line in the form which was not wrapping in the form was wrapping in the report field. This could potentially cause the data in the report to be truncated as well messes up the needed format.

In Stephen Leban's database to limit characters the limit is based upon the number entered within the Limit sample form. Is it possible to determine what this number of characters should be through code. The len function will not account for variable character sizes in font.

Is this just too much of a word processing function and I should not expect to be able to do in Access?

I hope that I have explained my dilemma clearly. Any assistance is greatly appreciated.
Jan 23 '07 #1
3 2084
nico5038
3,080 Recognized Expert Specialist
The calculation of the length of proportional fonts is a crime.
The easy way out is to use a non-proportional font like courier and that will make the Len() function use possible.

Another workaround could be to change the form into report layour and print the form for that specific record..
Just size the form to the paper format, make the background white and use for the "Show when" property of buttons and other form features "Form only".

Nic;o).
Jan 23 '07 #2
MMcCarthy
14,534 Recognized Expert Moderator MVP
Hello,
I am somewhat new to Access and vba, but am trying to complete a request that has been made of me. Access version 2002 WindowsXP.

At this point these text boxes are bound to the table memo field. I have located Stephen Lebans code to limit enter of text field based on characters entered and code to limit text based upon width of a text box (this seems to be most applicable for single line text box). I am have trouble putting everything together.

The objective is: to have a single page report with in which the field size will not shrink or grow and the report page will not shrink or grow to that the specific fields on the report will appear in the same position regardless of amount data entered. The data entry must be restricted at the form level so that the report will appear correctly. The report should also appear as formatted was it was entered in the form (without lines that have wrapped from the line above).

Where I have run into problems is that when I entered text in the form and then ran the report the lines in the report are not wrapping the same as the lines in the form. Both the form and the report are formatted to Verdana 10 pt. and I have played with sizing the width of the field on the form and the report; however, a line in the form which was not wrapping in the form was wrapping in the report field. This could potentially cause the data in the report to be truncated as well messes up the needed format.

In Stephen Leban's database to limit characters the limit is based upon the number entered within the Limit sample form. Is it possible to determine what this number of characters should be through code. The len function will not account for variable character sizes in font.

Is this just too much of a word processing function and I should not expect to be able to do in Access?

I hope that I have explained my dilemma clearly. Any assistance is greatly appreciated.
The problem is that Access for some reason treats the character spacing in forms differently to how it treats it in reports.

The only workaround I can think of is to impose a VbLf (line feed) after a certain number of characters are entered. However, I think this would require the text to be entered to a buffer before being saved to a record. Don't think this will work with Lebans Code.

You would have to set a character limit for the field. Set a line character number limit and use code to piece it all together.

Mary
Jan 23 '07 #3
NeoPa
32,556 Recognized Expert Moderator MVP
I'm not sure, but I think the way it handles character spacing is dependant on the device driver itself (or at least the device settings/parameters). The screen and each different printer can be considered as different devices and so each may treat character spacing differently :(
Jan 23 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

9
by: hope | last post by:
Hi Access 97 I'm lost on this code please can you help ================================= Below is some simple code that will concatenate a single field's value from multiple records into a...
5
by: Bob Weisenburger | last post by:
I have a table of "memos". each record in that table has a primary key "memo ID" that is autonumber. I have another table that is "memo receipts" with each record having a "receipt id" field that...
1
by: gevayl | last post by:
Hi, Is it possible to do memo text formating in ms access 2000? I mean like underlining a portion of text in a memo field or a text field? Thank you.
0
by: robin9876 | last post by:
When openning a table or a query that has a memo field, the memo field is not displayed in the output. However if a form or report is based on the table or query the memo field is displayed. The...
11
by: wolfesimon | last post by:
I have a form where the user copies a handwritten contract into a text field "Contract1". The contract usually exeeds 255 characters. Therefore I provided "Contract2", "Contract3", and "Contract4"...
13
by: Jack B | last post by:
I'm using Access 2002 to create a database for a small opera company that my wife is involved in, and I'm more than a bit rusty because I haven't created a new Access database since about 1999. ...
2
by: sitko | last post by:
Hi, I'm in the process of converting a VB.net program into a C program so it can run on a unix like machine. I've been moving along at a nice pace, but this conversion has stumped me. I need...
0
by: daverskully | last post by:
I have two tables created and want to link two forms created from these tables so that specific fields are populated once one field is selected, but not all fields being populated, with a new record...
3
by: jambonjamasb | last post by:
Hi I have two tables: email_tbl Data_table Data table is is used to create a Form Data_form
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
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,...
0
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.