New topic: 

confused about class

<http://forums.realsoftware.com/viewtopic.php?t=34235>

         Page 1 of 1
   [ 1 post ]                 Previous topic | Next topic          Author  
Message        JohnWheeler          Post subject: confused about classPosted: 
Fri Jun 11, 2010 1:24 pm                         
Joined: Mon Apr 19, 2010 12:58 pm
Posts: 33                Hi,

I am having difficulty understanding the use of the container control class and 
not being able to access its properties and methods.

Probably because I still not sure about classes in general, reading the user 
guide and LR just confuse me even more.

I started a  new project, added a container control, added a few controls, 
button as so on, the added a menu item for Print in Window1, added the 
following code to print the contents of the container, then discovered none of 
the methods or properties exist, hence spending since yesterday trying to 
figure out why, what am I missing not the code section but the concept of the 
relationship between the window and the container control.

Code:  Dim g as Graphics
  
  Dim pict as Picture = New Picture(ContainerControl1.Width, 
ContainerControl.Height, 32)
  
  Dim page as PrinterSetup
  
  ContainerControl1.DrawInto pict.Graphics, 0, 0
  
  
  page = New PrinterSetup
  If page.pageSetupDialog then
  g = OpenPrinterDialog(page)
  
  
  if g <> nil then
  g.DrawPicture pict, 0, 0, g.width, g.height, 0, 0, pict.width, pict.height
  end if
  end if
  Return True

Regards

John   
                             Top            Display posts from previous: All 
posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost 
timeSubject AscendingDescending          Page 1 of 1
   [ 1 post ]      
-- 
Over 1500 classes with 29000 functions in one REALbasic plug-in collection. 
The Monkeybread Software Realbasic Plugin v9.3. 
http://www.monkeybreadsoftware.de/realbasic/plugins.shtml

[email protected]

Reply via email to