Basic4ppc - Windows Mobile Development  

Go Back   Basic4ppc - Windows Mobile Development > Main Category > Questions & Help Needed
Home Register FAQ Members List Search Today's Posts Mark Forums Read

Questions & Help Needed Post any question regarding Basic4ppc.


TabControl "addControl" problem.


Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 04-19-2008, 01:29 PM
Junior Member
 
Join Date: Dec 2007
Posts: 27
Default TabControl "addControl" problem.

I am having a problem locating a Table on to a Tab Control.

I am creating the TabControl using addObject and also a Listview table the same way. The Table is originally created on the main form (form1), but when I try to add (transfer) the Listview (table) control on to the TabControl I get an error message.

(At this stage, this is all on the desktop only).

Sample code and error message attached.

As usual, it will be something simple.....any takers?

Burd.
Attached Images
File Type: jpg error message.jpg (32.5 KB, 13 views)
Attached Files
File Type: sbp TabTest.sbp (1,022 Bytes, 8 views)
Reply With Quote
  #2 (permalink)  
Old 04-19-2008, 02:27 PM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 1,896
Awards Showcase
Beta Tester Forum Contributer 
Total Awards: 2
Default

As ListView is a library object you would need a control reference rather than a name string to use with AddControl.

ViewTable.AddControl(ViewTasks.ControlRef,0,20,20)

You need to do this with any control from the ControlsEx library.

e.g
AddObject("PBar", "ProgressBar")
PBar.new1("Form1",0,0,100,10)
ViewTable.AddControl(PBar.ControlRef,0,40,40)


Unfortunately Listview doesn't seem to have a ControlRef property that exposes the underlying Listview control so I am afraid you can't use it on a Tab
Reply With Quote
  #3 (permalink)  
Old 04-19-2008, 02:47 PM
Filippo's Avatar
Basic4ppc Veteran
 
Join Date: May 2007
Location: Schwäb. Gmünd, Germany
Posts: 319
Awards Showcase
Beta Tester 
Total Awards: 1
Default

Hello burd27,

i think it works so.


Ciao,
Filippo
Attached Files
File Type: sbp TabTest.sbp (1.2 KB, 31 views)
__________________
PPC: MDA Pro, 2GB SD
PPC: HTC Touch Diamond, 4GB
______________________
Reply With Quote
  #4 (permalink)  
Old 04-19-2008, 04:24 PM
agraham's Avatar
Basic4ppc Expert
 
Join Date: Jul 2007
Location: Cheshire, UK
Posts: 1,896
Awards Showcase
Beta Tester Forum Contributer 
Total Awards: 2
Default

Quote:
Originally Posted by Filippo View Post
i think it works so.
Good work-around Filippo - I wouldn't have thought of that.
Reply With Quote
  #5 (permalink)  
Old 04-20-2008, 09:42 AM
Junior Member
 
Join Date: Dec 2007
Posts: 27
Default

Thanks guys.

What a beauty!! Nicely done. Works great.

Much apprecited...yet again.

Cheers,
Burd
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
SetUpBuilder Problem - "Build Cabs first" dhillinmkewi Questions & Help Needed 4 11-29-2008 11:57 PM
Problem with "Task.StartDate" in Outlook.dll JOTHA Bug Reports 9 09-19-2008 03:19 PM
"AddEvent" and "buttonUp/buttonDown" Byak@ Questions & Help Needed 12 09-10-2008 04:04 PM
Problem with Serial. ("before loop" error) jesb4ppc Questions & Help Needed 3 02-15-2008 06:41 PM
calling the device's "Programs" or "settings" screens HarleyM Questions & Help Needed 0 12-05-2007 03:59 AM


All times are GMT. The time now is 02:13 PM.


Powered by vBulletin® Version 3.6.12
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.1.0