We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
close icon

Creating new tab page(ext) to duplicate existing page i.e. Copy

Clay sent me a way of "copying" an existing Tab page (I use tabpageext type) as per code attached. The name will be an increment of the existing tab page e.g. Page1 copied creates Page2 etc. However, I cannot get this code to work at all as the definitions are not accepted e.g. any GridTabPage mention fails as does "selectedtab". I am on Version I understand the concept but what am I missing to get it working ? Jim

5 Replies

AD Administrator Syncfusion Team April 1, 2003 02:14 PM UTC

GridTabPage is a class derived from TabPage and was defined in the GridTabPage.vb file that is part of the project you received. You will have to include this file (or more correctly, a similar file that has the exact tabpage layout that you want to clone) in your project. Then your project will know what GridTabPage is.

JJ Jim Jackson April 29, 2003 06:54 AM UTC

Thanks, Clay. Now I'm back working with it, I have another problem that I'm sure will be as simple as adding a class!! The sample code from yourself to define the current tab to be copied is: dim CurrentTab as GridTabPage = Ctype(Me.Tabcontrol1.SelectedTab, GridTabPage) I understand what that is trying to do but I am using your extended tab definitions i.e. TabControlExt1 and I cannot find "SelectedTab" in any of the control specs. What is the alternative for this one ? Thanks Jim

AD Administrator Syncfusion Team April 29, 2003 08:24 AM UTC

Jim, There should be a SelectedTab member of TabControlExt. Me.tabControlExt1.SelectedTab I checked the latest public patch code, and it is there. What version are you using?

JJ Jim Jackson April 29, 2003 08:42 AM UTC

Clay, I am using Have checked Object Browser and it shows as you suggest BUT within the program , it doesn't. In fact, I was just about to add a query to say that and why doesn't it show in the program when I saw your reply. Jim

AD Administrator Syncfusion Team April 29, 2003 01:40 PM UTC

I am not sure why but SelectedTab is marked as an advanced property. So, by default this property shows up using the C# editor, but does not show up with the VB editor. You can change this default setting under Tools|Options|Text Editors\Basic. On this tab, uncheck the Hide Advanced members checkbox.

Live Chat Icon For mobile
Up arrow icon