readme55555's Q&A profile
Visual Basic Passing arrays from vb .NET to ActiveX control (*.ocx)
I have an application written in Visual Basic 6 that uses an ActiveX control written in Visual C++ 6. I'm moving the visual basic 6 application to visual basic .NET (2003). The problem is when I try to pass an array from the visual basic code as a parameter of a function of the control. In Visual Basic 6 the code is something like this: Dim dummy(10) as Long '... 'some code '... myActiveXControl.myFunction(dummy(0)) myFunction expects a reference of the first element of an array of Integers. Passing the first element of the array works fine in visual basic 6. But if I try the above code in vb .NET, changing the definition of the array for this one (type Long in vb 6 is Integer in vb .NET) : Dim dummy(10) as Integer ...Show All
Smart Device Development XMLSerializer: sibling elements order - normal in .Net Framework but random in .netCF!
Hi, all I have used the same classes, and the same serialization code to run a test program writing out an XML document from a data object. It turned out that for an element which has multiple child elements, the order of the child elements remained the same in Framework 2.0 as defined in the class, but it was random in CF2.0! It isn't alphabetic nor anything I can tell but a random order... This is annoying because then the document generated in CF2.0 wouldn't pass the same schema, based on which the classes' code was actually generated. Is the problem a bug -bonnie Bonnie, Despite .NET's tendency to preserve the order of XmlElement's, unless you explicitly set the XmlElementAttribute.Order pr ...Show All
Architecture Observer pattern
Hi all, I'm trying to use the observer pattern on updatng GUI controls. I have some controls (TextBoxes, Buttons)... I don't know how to link the Update method to the control. Is it possible to do that without inheret from the control and implement a new control includes the Update method. I have the IObserver (IGUI in my case) and ConcreteObserver (Control in my case) Any suggestions. Please help. Regards... Hi wasimf, I read your post but seems it lacks of details. I mean, imagine if I ask you "to go to the park, do I have to turn into left or into right " (which park where are you caming through where are you coming from those answers matter) In your ...Show All
.NET Development Does 'promary key' make a table faster?
Hello, I'm wondering if I always should have a primary key in each table, even if I don't use it Thanks The primary key ensures that there's at least one field which ALWAYS contains a unique value for each record. This is essential if you're doing relational queries against the table. I can't think of any compelling reason not to use one. ...Show All
Visual Basic Err.LastDllError Equivalent in VB.NET
Hi, I'm working on a conversion project: I would like to know If there is any .NET equivalent for the below statements: 1) Err.Raise (...) - I'm thinking of using throw statement. 2) Err.LastDllError Thanks... Kannan Online wrote: 1) Err.Raise (...) - I'm thinking of using throw statement. 2) Err.LastDllError 1. Yes, use Throw 2. System.Runtime.InteropServices.Marshal.GetLastWin32Error ...Show All
Windows Forms Copy files using custom actions in Setup Project
I have a project to deploy but there is a file (non code), that will need to be copied to a directory on the install machine, that is not the application directory (app dir). To make maters worse, this directory will be different on every machine. So I can not use the File system editor. My thinking was to use a custom action on the Install_AfterInstall event. This action would look in the application directory where that app had just been installed and copy this file to a specific dir on the users machine. The problem is this dir could be anywhere on the users machine. The good news is the dir will always be named the same. How do I get the app dir name so I can copy this file at the end of the setup process Will the file exist on t ...Show All
.NET Development questions about Automatically Generating Commands (DbCommandBuilder )
from http://msdn2.microsoft.com/en-us/library/tf579hcz.aspx When the SelectCommand property is dynamically specified at run time, such as through a query tool that takes a textual command from the user, you may not be able to specify the appropriate InsertCommand , UpdateCommand , or DeleteCommand at design time. If your DataTable maps to or is generated from a single database table , you can take advantage of the DbCommandBuilder object to automatically generate the DeleteCommand , InsertCommand , and UpdateCommand of the DbDataAdapter . I'm confused that if my selectcommand involves more than one table, these commands can not be generated automatically, is this true so during actual development, probabably our sel ...Show All
SQL Server Problem while exporting OLAP data to Excel
Hello all, I have Analysis Services installed on one machine (dedicated server) . Other machnines have OLAP application installed (Pivot Table is used). When client machine tries to export olap data to excel , it takes a long time to load and sometimes it hangs. Is it related to analysis server settings Regards, Deepti Deepti, can your provide some more information What version of Excel are you using What version of Analysis Services Are you trying to export an Office Web Component Pivot connected to Olap data to Excel If so, what version is the Office Web Component Pivot ...Show All
SQL Server Help for Dynamic Grouping!!
Hello to everyone. I face a problem for gouping. I want to make dynamic grouping in report. Dynammic Grouping means, I want to provide a parameter named Group By with mutivalues. I can't hide this parameter so that user can select any one value from this dropdown and when he is click View Report, takes that value and group table rows as per parameter selection. So i want to ask if it is possible to change <groupexpression> in XML code of report dynamically as per selection. <Grouping Name="table1_CODE"> <GroupExpressions> <GroupExpression>=Fields!CODE.Value</GroupExpression> </GroupExpressions> </Grouping> This is default grouping, when i select a value from Gro ...Show All
Visual Basic open a form with only systray icon
Hello, how do i open a form so the form does not show and only an icon appears in systray I know how to make the icon but everytime I do this the form appears. I want to make the form only appear when I right click on the icon and say "appear". Thanks! Hi, I have the same problem that u have.Can you please tell me the procedure u followed. First of all my Problem is : I have only one form but im using sc_minimize if I set showintaskbar to false it wont work.But i dont want to display my application in takbar.I want to display in systray. Than you. ...Show All
Windows Forms ClickOnce file share icon?
This is probably a really basic (maybe stupid) question, but I have done several searches and haven't found an answer Here's one version of the documentation I'm referring to: Install from the Web or a Network Share Using this strategy, your application is deployed to a Web server or a network file share. When an end user wants to install the application, he or she clicks an icon on a Web page or double-clicks an icon on the file share. The application is then downloaded, installed, and started on the end user's computer. Items are added to the Start menu and the Add/Remove Programs group in the Control Panel . Where is the icon they are referring to in the statement: double-clicks an icon on the file share When I pub ...Show All
Visual C++ Problem with Visual C++ after upgrading VS2005 with SP1
My team develops software with Visual C++ on Visual Studio 2005. When we upgraded from Visual Studio 6, we discovered that for the executable to run a computer that does not have VS8 installed on, the new C redistributables had to be installed. We went through the installation, and indeed the executable created with VS8 worked. We had some of the developers' compilers upgraded from VS8 to VS8 SP1, and suddenly the problem occured again - executable created with VS8 sans SP1 works on the destination machine, while executable created from same sources with VS8 SP1 will not. Anyone ran into this problem Any know solution Thanks, Tzal. We had a similar scenario in past for one of our project dev. ...Show All
Windows Forms Help removing indicator/pointer in row header of datagridview
Hi. Just wondering if anyone know how to hide or make the indicator (pointer or triangle symbol) disappear This is the one that shows on the row header then you scrolling thru the rows in a datagridview. That is without hiding the row header all together. I any idea Regards, JB.. Hi. It still works that same. I am thinking, maybe it has something to do with my RowPostPaint event. Below is the code in that event. using ( SolidBrush b = new SolidBrush (dataGridView.RowHeadersDefaultCellStyle.ForeColor)) { e.Graphics.DrawString((e.RowIndex + 1).ToString(), e.InheritedRowStyle.Font, Brushes .Black, new PointF (e.RowBounds.X + 5, e.RowBounds.Y + ...Show All
Visual Studio Team System TFS SP1 Installation Failure
The build component seems to install without error, but the first component fails every time. I can fix our installation afterward by reinstalling the KB that's required before installing SP1, and fixing whatever changes the install made to the Domain accounts uses for the application pools and services. But it would be nice if we could actually get SP1 to install without error. I'm thoroughly disappointed with the low quality of this install fall so far. I've seen alpha software work better. Anyhow, I've got this log file with a ton of information and lots of errors. Rather than posting it here (because it's simply huge), is there someone I can send it to who can help We'd really like to get this installed if possible. I hear thi ...Show All
Visual C++ How to execute a program within an NT service
Hi, I am looking for a syntax that allows my NT service to execute an external program (ie: "c:\abc.exe" ) and viewable to the users. I'd tried with system( "c:\abc.exe" ), it launches the program.. but it's running in the background as well... so I can only see it in Windows Task Manager. Thank you. Louis For win32 programming issues & APIs, please use the newsgroups at http://msdn.microsoft.com/newsgroups OTP Thanks, Ayman Shoukry VC++ Team ...Show All
