473,665 Members | 2,774 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Issue with IDesignerSerial izationService after paste fails

We have implemented our own IDE which is based on an example from Microsoft.

We have implemented the IDesignerSerial izationService interface in our
application.

The following steps cause a problem:

a) Start the application and drag a group box control onto the form.
b) Add two labels to the form
c) Cut the group box to the clipboard
d) Add a tabcontrol
e) Paste onto the tabcontrol

An error is displayed which states “Cannot add component of type ‘GroupBox’
to container of type ‘TabControl . This error is displayed because at this
point a tab page has not been added or selected.

However the underlying Microsoft classes have actually added the labels to
the DesignerHost collection (the GroupBox has not been added) and so when I
build or save this out the two labels are added to the saved file (but are
not actually added to the forms control collection).

This means that the saved code file contains redundant controls which I
would like to remove.

Does anyone understand why the deserialization process is adding these
controls to the DesignerHost even though the paste cannot be completed?

Please note that the same error occurs in 2003/2005 Visual Studio IDE but
the controls from the failed paste do not seem to be added to the generated
code.

Does anyone know the magic required to “clear” the controls in the failed
paste operation?

Regards

--
Ian H
Nov 7 '06 #1
0 1124

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
2110
by: JP SIngh | last post by:
I am having problems inserting data into a simple table Insert into Forums (Title, PageUrl, ContractId) Values ('54249', 'test01.asp',54249) Microsoft OLE DB Provider for SQL Server error '80040e2f' Cannot insert the value NULL into column 'ForumID', table 'LegalOnline.dbo.Forums'; column does not allow nulls. INSERT fails. /sqllegal/submitcontract.asp, line 214
2
6613
by: info | last post by:
I am pasting in a recordset from access to an excel sheet via VBA successfully. Then my routine copies a range of cells and pastes them into another range, this works fine every other time it runs. Every other run of the code it fails at the line Selection.Copy with a Runtime error 91:. I then run it again and it works fine. This is really puzzling me a snippet of my code is below. Any ideas? >>>>>>>>>>>>>>>>>>>>>>
2
2813
by: Ben Rush | last post by:
Hello World, Okay, I have spent the day browsing the newsgroups and reading up on article after article concerning ViewState corruption and so forth, and I have a couple questions. We intermittantly get the following exception - EXCEPTION MESSAGE: The viewstate is invalid for this page and might be corrupted. STACK TRACE:
6
1752
by: daveyand | last post by:
Hey Guys, I've stumped. I created a function that does various things to select boxes. Namely Get All selected indexes, populate array with these values
0
2337
by: Nicholas Dreyer | last post by:
Operating System: Microsoft Windows Version 5.1 (Build 2600.xpsp_sp2_gdr.050301-1519 : Service Pack 2) Visual Basic: MIcrosoft Visual Basic 6.3 Version 9972 VBA: Retail 6.4.9972 Forms3: 11.0.6550 (comes with Excel 2003) The copy paste code below fails to copy the PrefixCharacter from cell "a1" to cell "a2" when compiled into a dll and called from VBA, yet running from a VB.NET main program the PrefixCharacter is copied, as it is...
3
2493
by: VirGin | last post by:
I am passing an object by reference to a function that is supposed to populate it with current data. Both the destination object and the source have nested std::lists, some branches of the lists might be empty. The function crashes when copying the lists, the error info is: ..dlu!std::list<HWND__ *,std::allocator<HWND__ *::clear() Line 818 + 0xf bytes C++ ..dlu!std::list<HWND__ *,std::allocator<HWND__ *> std::list<HWND__...
4
2259
by: Chris | last post by:
Hello all, Using g++ 3.3.1 on Linux ("Linux From Scratch") I have a data structure SCSIParams_t that I wish to print out, field-by-field. Rather than code a long line of the form std::cout << "fieldname = " << basepointer->fieldname << std::endl; for every field, I'd like to do it with a short macro, e.g.
0
745
by: santoshjsh | last post by:
hi everyone, i have two asp.net 2.0 projects. now i have to integrate both projects as one. the issue is "Sharing the session of one project with another project". this is a deployment issue. Note: i cannot merge the two application using code (means copy and paste the second application code to the first one)
2
5544
by: srinivembu | last post by:
Hi, I have linked libcurl library (v7.19.6) statically with my C++ application. Using curl, we upload & download files to/from the window azure storage webservice using https. The download works for smaller files with few KBs. But for files with size greater than 50 MB, the download fails with the error CURLE_PARTIAL_FILE. This issue occurs randomly ie., some times the file was downloaded successfully without issue and some times, the same...
0
8438
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, well explore What is ONU, What Is Router, ONU & Routers main usage, and What is the difference between ONU and Router. Lets take a closer look ! Part I. Meaning of...
0
8863
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, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8636
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7376
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 projectplanning, coding, testing, and deploymentwithout human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6187
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 presenter, Adolph Dupr who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5660
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 then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4186
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4356
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2765
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 we have to send another system

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.