Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Page size

Status
Not open for further replies.

hoofit

Technical User
Nov 20, 2005
343
US
One of my forms has several pages the size of which I would like to manipulate. Seems that I'm able to set the size and position of the form but not the pages themselves. I can capture the on load event of the form but not the page. I tried an on click event of the page without success. Any thoughts?

Thank you,

hoof
 
Yes, why the error? Could you assist
 
Access has two types of modules

Standard
Class
Custom Class
Form Class
Report Class

Standard modules are used to group shared procedures and functions that can be used throughout the application/group .

Class modules are used to create and define the properties and procedures of an object. The form and report class modules are a special case tied to a displayable object.

You have to put the class code in a custom CLASS module. In the VBE you have to select "insert" - "class Module". Paste the class code. Then change the name of the CLASS module to "FittedTab". As I said, if you put this in a STANDARD module it will not work. If the CLASS module is not named FittedTab it will not work.

Also you did not follow what I showed. You need to declare the object reference (fT) at the top of the form module not inside the load event
Code:
option compare database
Option explicit
'declare here outside the event
Public fT As FittedTab

Private Sub Form_Load()
  Set fT = New FittedTab
  fT.InitFittedTab Me.tbCtlOne
  ...
  'other code
End Sub
my control is named tbCtlOne on my form. If you use a different name then change this line
fT.InitFittedTab Me.YourNameHere
 
I've created the class module correctly and dropped in the code and compiled. Now I'm working on the other part
 
OK, everything's compiled with no errors. How is the re-sizing handled. I've tried re-positioning controls in design view and manually re-sizing a page.
 
Are you saying it is working, and you want to know how it works? Could you restate the question a little clearer?
 
The code compiled with no errors. The tab control was named correctly. Do the pages on the tab control automatically size to 'best fit' based on the space that the various controls take up, or, is there some other intervention I need to do. Currently, I see no change in the size of the pages. The question thus would be, what else do I need to do and what is it that I am not doing / missing.

Thank you kindly :]
 
This would be a lot easier if you post your database. Try something like 4shared.com.
 
MajP,
While I appreciate your suggestion, I'm not posting my db just as I'm sure you would not yours. If I get time, I will try to isolate my issue and post a sample. I was able to download your sample but still do not see what I'm looking for. Appreciate your time, interest and input.

hoof
 
I'm not posting my db just as I'm sure you would not yours.
I post db's all the time. I have probably posted several hundred on this site.
 
but still do not see what I'm looking for
You do not see the difference? This is what I see when I change pages
IMG
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top