Thilakavathy's Q&A profile
Windows Forms Form Scaling Problem
I'm developing in VS2005 (C++/CLI) on a machine with a resolution of 1600x1200. I have a form (Form1 built with the designer) that contains several controls including GroupBoxes, TextBoxes, ListBoxes, DataGridViews and Labels. When the form is run on machines with 1024x768 or lower it will not scale. Only part of the form shows and the user cannot see all the controls nor can he expand the form to see the controls. I have tried setting the form's AutoScaleMode property to Font and to Dpi with no success. I've also tried using AutoScroll to no avail. Has anyone had a similar problem and/or can anyone recommend a solution Thanks John I did some looking in Debug. During design, the Form1's AutoSc ...Show All
.NET Development CodeDom: How to declare var & assign to indexedProp of Shared Obj
Hi, I'm doing some codedom work and am wondering what syntax I need to write in order declare a variable and assign it to a static objec'ts property so that the emitted code is in one line. I can use the codeDom to output what I need in two lines-- but that's not what i want. ie: Output I want: ConnectionStringSettings settings = ConfigurationManager.ConnectionStrings[connConfigKey]; Output I get: System.Configuration.ConnectionStringSettings settings; settings = ConfigurationManager.ConnectionStrings[connConfigKey]; The code that produces the above: private void CreateVarDeclAndAssigntoStaticStaticIndexObjProp(KeyValuePair<string, Type> var) { this._methodObject.Statements.Add(new CodeVariableDeclarationStatement ...Show All
Visual C++ Possible bug with interior_ptr<> in C++ CLI
I hope this is the correct forum for this sort of question. It is repeated on my blog in case the formatting gets in a mess. I encountered some strange behaviour when using interior_ptr in a generic function. It appears that, for the purposes of pointer arithmetic, the byte size of the template parameter is always assumed to be 4, regardless of whether it is a char or a double. This doesn't happen when interior_ptr is given a concrete type directly. The following example is a generic version of the online help example that demonstates the problem: // interior_ptr bug example // compile with: /clr generic < typename T> void ProbeFirstTwoElements( array <T>^ arr) { // create an interior pointer into the array ...Show All
Gadgets How can I find out .....
I want to develop a gadget that will show the current user name and his assigned account picture (i.e. shown in start menu). How can I do this Thank you very much for helping. I want to find the 'All User' directory.(i.e. C:\Documents and Settings\All Users\ usually). What environment variable ...Show All
Visual C++ Pesky OLE headers in returned Access Database records (C++ CLI VS2005 / OleDB)
Im using System::Data::OleDB::OleDBDataReader::GetBytes( ) to read a selected column value (raw binary data) in a selected row to a cli::array<Byte, 1> array. This works fine. The problem is Microsoft Access (2003) apparently adds an OLE header and footer to the raw binary data, and I must strip that junk out when I read it in to the array. This works for now, but is not a general solution. Is there a .NET data method on some nice object somewhere that will get rid of these OLE metadata If not, would SQL Server be a better choice The database solution needs to be freely distributable and capable of storing binary data without feeling the need to disturb it. Thanks for any advice! Hello Re: Pesky OLE ...Show All
Windows Forms Problem adding files to deployment project.
I am having problems adding text files (xml) to a deployment project. I check out the deployment project and try to add a file (from both the File System View and the Solution Explorer). I select the desired file from the Add File dialog and click Open. The Add File dialog closes and nothing happens. In the past I found when I observed this behavior I had to make sure the file I was trying to add was writable so I would check it out from the source control (I am using ClearCase) and I would be able to add the file. Now this doesn't seem to make a difference, no matter what I do, the Add File dialog closes and nothing happens. I have not seen any sort of error message anywhere obvious. I can add project outputs, but not files. Has anyone se ...Show All
Visual Basic change from vs2003 to vs2005
Hi, .Net experts, I am at the eve of go live with my first full scale dot net windows app. I developed it in vs2003. Now we are thinking about change over to vs2005, primary for its one touch deployment capability. I know there are other newer features/upgrades associated with vs2005, but for this project, they would not make too much difference. My concern is that will the change break anything. I know a lot of factors can come into place here. Here is the laundry list. And please give me your advice, thanks! Old: vs.net professional version 2003 Upgrade New: vs2005 Professional Upgrade Nature of the app: windows app, client/server with sql server 2000, up to 50 users in one physical location, d ata access layer is using Microsoft.Appli ...Show All
SQL Server Adding multiple fields together
Okay hopefully this is quick and easy. I have 3 fields (Annual Salary, Medical, Pension) and I now need to working out Cost To Company which is just adding those three together. I tried to do that in a formula but it doesn't return me anything... This is what I had. =(Sum(Fields!AnnualSalary.Value, "CoreEmployeeData")+Sum(Fields!AnnualMedicalAid.Value, "CoreEmployeeData")+Sum(Fields!AnnualPension.Value, "CoreEmployeeData")) So it should add the 3 records While you are here :), Can you tell me how I can put a currency symbol in the front of these numbers and add the thousand comma delimiter ok, What is the "CoreEmployeeData" section, I would think this is affecting ...Show All
Windows Forms WebBrowser - setting value for "type=file"
I'm using the VS 2005 control System.Windows.Forms.WebBrowser. I want to be able to set the value for a text area that indicates a file to be uploaded, where type=file HTMLInputElementClass iElement = (HTMLInputElementClass)element.DomElement; if (iElement.type.ToLower() == "file") { if (iElement.name == name) { iElement.value = text; Application.DoEvents(); ok = true; break; } } iElement.value is still null after the assignment. Help. I've seen some posts saying that this is done on purpose as a security issue. They don't want people to be able to ...Show All
SQL Server How to validate the file in SQL Server 2000
How to Validate the .txt, .xls, .mdb, .doc file in SQL SERVER 2000 If anybody knows, I would appreciate help Thanks hi, what do you mean validate. Does it mean that file exist or file is not damage please be more specific thanks joey ...Show All
Visual Basic problems with windows service
Hi , I would like to know what shall i use for my project. My project is a windows application that gets data form a site and stores it in a database.At the moment this process is done manually by the user by clicking the getdata button in the wins application. This button gets the data and stores it. Instead of this happening I would like the application to run lets say at 6 in the evening and after the service " clicks " the getdata button . I require this procces to be done automatically without user interaction. Should i used a windows service to carry this process out if so I already created a windows service but im stuck on how this service will call the application and carry out the getdata process done by the button. ...Show All
Visual Studio 2008 (Pre-release) Binding to an entire object
I am trying to bind to an entire object like so: < DataTemplate DataType = " {x:Type local:MyObject} " > < StackPanel > < Rectangle Height ="10" Width = " {Binding RelativeSource={RelativeSource AncestorType={x:Type local:MyObjectControl}, AncestorLevel=1}, Converter={StaticResource MyConverter}} " /> </ StackPanel > </ DataTemplate > When MyObjectControl is created the first time, this template is applied and my converter is called and everything is fine and dandy. However, when I change a property of MyObjectControl, this is not re-updated and my converter isn't called. Apparantly, my problem is that I have no way of saying that my entire object has ...Show All
SQL Server Anchoring textbox to a page.
Hi, In our project I have a matrix report. In that I need to anchor a textbox to the right end of the page, so that the textbox will always be at the right end of the report/page. I also need to place the textbox at the page header. (but I am also open to solution / workarounds which does not include page header!!) Thanks in advance Arun. thanks Andy. i would also like to see that in SSRS as a feature!!.. for now i will try to anchor the textbox using some expression.. mean while if anyone comeacross any other ideas please keep me posted!! thanks Arun ...Show All
SQL Server TRyign to extract Top 3 records using Partitioning
Hello, I have a table containing 3 columns Department Name, RiskScenario and Cost. I am trying to create a data extract that contains the top 3 Risk Scenarios (sorted by Cost) per Department. I tried using this sql statement in MSQuery but it doesn't work. Any ideas where I'm going wrong or if there is a simpler way to do this Select * from ( Select DepartmentName, `Risk Scenario`, Cost, row_number() OVER (PARTITION BY DepartmentName order by Cost) rn FROM 'Departmental Risks`) where rn <=3 Please help. Just can't figure this out! Meera Select * from ( Select DepartmentName, `Risk Scenario`, Cost, rank() OVER (PARTITION BY ...Show All
Visual Studio Team System Problem opening Work Item Selections in Excel
Hi, One of our users is unable to Open Work Item (Example: Bugs)Selections in Excel. This is the error he gets: ------------------------------------ "TF80012: The document cannot be opened because there is a problem with the installation of the Visual Studio 2005 Team Foundation Office integration components. Please see the Team Foundation Installation Guide for more information." Things tried: ----------------- Removed all Team Foundation software and components via Add/Remove Programs Reinstall the Team Foundation Client. (CAL license) --Still got the same error. The Office 2003 was already installed prior to Team Foundation was installed. Any help is appreciated Thanks, Staffan ...Show All
