Christian Sparre's Q&A profile
Windows Forms Changing window size dynamically
Hi! I have a question about a window form in visual c++: I have an application which takes as parameters two integers, the width and the hight of a form to be created; moreover, the form contains a panel, which has to be resized too, to fit the hight and the width of that form. The problem is that even using commands like: this->Size = System::Drawing::Size(width,height); this->panel1->Size = System::Drawing::Size(width,height); (located in the constructor, after InitializeComponent() command) the window still has the same dimensions as shown in the visual c++ design window (I mean "form1.h[Design]"). Perhaps there is some option to be set Or maybe something to be changed in the toolbox Thank you! ...Show All
Game Technologies: DirectX, XNA, XACT, etc. Scaling my Skybox
Hi guys i hope you can help me with my simple problem. I use the following code to draw my skybox: public void Draw() { Matrix[] transforms = new Matrix[myMesh.Bones.Count]; myMesh.CopyAbsoluteBoneTransformsTo(transforms); foreach (ModelMesh mesh in myMesh.Meshes) { foreach (BasicEffect effect in mesh.Effects) { effect.EnableDefaultLighting(); effect.View = View; effect.Projection = Projection; effect.World = mesh.ParentBone.Transform * Matrix.CreateTranslation(Position); } mesh.Draw(); } } Whats my problem My problem is that my skybox is too small. So how can I scale my skybox or in common how c ...Show All
SQL Server Scheduling the SSIS Package to run after every 2 mins
How can i plan the execution of a package For example, i want to execute the package every 2 minutes for all the time. I do not want to use SQL Server Agent to do this. I want the package to self contained to do it. Thanks Rohit I don't use SQL Agent either, but SSIS packages are not designed to be run like Windows services or Unix daemons. For one, there still is a memory leak in 64 bit (perhaps fixed in the forthcoming SP2) that forced me to write a script to restart the SSIS service whenever the msdtssrvr.exe's process working set size became too large. As for scheduling ,there are probably thousands of ways to do that. One that comes immediately to mind is schtasks.exe, which is a replacement ...Show All
Visual C++ Reading XML File and storing into a 3 dimensional CString Array Variable
Hi, In MFC, I have to read a XML File which is having a size of 2 MB. The contents of the XML Files has to be stored into a 3 dimensional CString array variable. The process is very slow. How I can speed up this. In the place of CString array, if I am using a struct data type will it be faster If so how I can use that struct data type. ================Suresh < xml version="1.0" standalone="yes" > <PO> <O> <N>33 BN. PAC</N> <P>110001</P> <C>b8af4de3-a66d-4a68-8d44-90a3577f5c6d</C> </O> </PO> Hi, The above XML, where the <O></O> will be repeating. I declared a 3 dimensional array, in the first dimension, ...Show All
Windows Forms How can I install my program files into "C:/Program Files/"?
How can I install my program files into "C:/Program Files/" wizkid1 wrote: How can I install my program files into "C:/Program Files/" Are you creating setup of your program If yes, there are some options to select the Program File of Target Machine in "File System(Setup) Panel". - Right Click on "File Sytem of Target Machine" Note Ob: The Program File Folder will be shown in Content Menu. Enviroment variable for Programfile is "%PROGRAMFILES%". ...Show All
Visual C# define a property which accepts a parameter
Hello! What's the C# syntax to define a property which accepts parameters. The VB syntax whould be: Public ReadOnly Property Item(ByVal index As Integer) As Object Get Return CType(Me.List.Item(index), MemberDataValidationError) End Get End Property As already Mattias write you, for that you need to use indexer. By default every collection type has indexer of type int. But if you need to access the class property, by providing property name, then create indexer of string type: [IndexerName("Item")] public object this[string name] { get { switch(name) { case "FirstName": return FirstName; //where FirstName is example of property name of the class on which indexer belon ...Show All
SQL Server Simple Workgroup (Like Access) use of SQL Express ??
Hi all, In the past if we wanted to provide an application with simple (multi-user) database facilities, we would use an Access mdb database which we could basically xcopy deploy to the client. Share the folder across the network and apart from the limitations of mdb databases it would work !!! With all the advancements in databases ! we have moved on to SQL Express - touted as the thing to use and the replacement for MSDE and MDB databases. But hang on a minute !! It doesn't work like that ! You can't deploy Express like we used to with MDB databases - the default Express database doesn't allow multi-access and if you can't xcopy deploy the Express database. The 'user Instance' thing is useless - basically every user gets their own ...Show All
Windows Forms RichTextBox - ZoomFactor problem
Hi, Here is the code: this .richTextBox1.Rtf = @"{\rtf1\ansi\ansicpg1251\deff0\deflang1049{\fonttbl{\f0\fswiss\fcharset0 Arial;}} {\*\generator Msftedit 5.41.21.2506;}\viewkind4\uc1\pard\lang1033\f0\fs20 test\par }" ; this .richTextBox1.ZoomFactor = 5.0f; ---------------------- The first time I run this code, ZoomFactor gets set to 5.0. Great. Now, I run the code second time and ZoomFactor goes back to 1.0! This code was working fine under .NET 1.1. Now, I moved the project to .NET 2.0 and it stopped working. The documentation suggests that a non-true-type font may cause this problem. But, it is the true-type font indeed. To make sure, I wrote a small test application. Just one form with a "T ...Show All
Visual Studio Team System Feature Request: Filegroups
Hey there, I would like the ability to put objects (tables, indexes, etc) into separate filegroups. I tried manually specifying the filegroup in the create statement, but the objects are still being created in the primary filegroup in the build script. Thanks! This is a known limitation right now, which are addressing as soon as we have the database project properties in place in the project organization, so you can specify which FileGroups you want for your database. After that you can assign objects against them. -GertD "DataDude" Development Manager ...Show All
SQL Server I need help with a SQL Query
I know that there's a lot of you out there that are really good at Sql Queries. Hopefully, one of you will have pity on me and clue me in. I am working with a Visual Studio 2005.net VB application accessing SQLServer 2005 and SQLServer Express databases. I am using a sql query with ado.net data adapter to return data to a grid bound to the data adapter. My problem is that there is data in the SQL table stored as Bigint data types, that I need to divide by another integer and return as a double precision number. For example, part of the Sql Statement looks like: " InvStock.QuantitySold / NumPeriods AS 'AvgUnitsSold', " It works except for the fact that it returns an integer and truncates the decimal points. Is th ...Show All
SQL Server Sql 2k5 INSTALLED ON THE SERVER
Hi All, My program is written in VB.NET and the DB is SQL 2005 Ex Ed. I have installed both, the SQL SERVER 2005 and my program on the SERVER. But when I try to run my program I get the following error mssg: The application attempted to perform an operation not allowed by the security policy. The operation required the SecurityExceptio. To grant this application the required permission please contact your Systems administrator, or use the Microsoft .Net security policy administration tool. If you click continue...... Request for the permission of type System.Data.SqlClient.SqlClientPermission. System Data, Version = 1.0.5000.0 = neutral. PublicKey Token = b77a5c561934e089 failed. My Systems administrator says I have got full control of the ...Show All
SQL Server Cannot continue past Source File Error...
I have an SSIS package where I have directed the error output to a Flat File Destination. The issue is that there are some bad entried in a set of log files, where the source file reads on more delimited column than there are actual columns. (As in there are 26 column headers, and one row will have 27 commas, or delimiters.) I am trying to redirect the row output to put the bad rows into a Flat File for debugging purposes. Although, the package is not able to continue past the error. As soon as it hits the bad row, it fails despite the error output. Any ideas Thanks for the reply! I believe I have isolated the issue to a particular value in th ...Show All
SQL Server Two attributes in one dimension: One on row axis / One on column - how to hide empty values (ShowEmptyVals of PivotTable = true)
Hi dear MS Developer and users of this forum, i have one little question (AS2005): I've created a dimension "Clients", it has two dimension attributes: "Clients" and "Industry line". Now I have in my fact table this entries: ---------------------------------------------- Client Sales Amount A 100 $ B 200 $ C 300 $ ----------------------------------------------- Dimension table "Clients" Client Industry line A 1 B 2 C NULL ----------------------------------------------- Name Columns of Attribute "Industry line" are taken from this table: Ind_line Name 1 Cosmetics ...Show All
Game Technologies: DirectX, XNA, XACT, etc. DirectX 10-Vista
I owe a computer with W. XP.I'm going to upgrade it to Vista.My question is if directX 10 needs only Vista to run.My system is fueled by ATI radeon x1600 pro.Do I have to change it or just have Vista No adapter that is currently sold is compatible with Direct3D 10. Even the newest one will not be upgradeable with a new driver. Direct3D 10 adapter should be available later this year. ...Show All
SQL Server PAGE_VERIFY setting CHECKSUM - how to detect?
Does anyone know how to detect the CHECKSUM setting of the PAGE_VERIFY database option (2005 only) BOL (ALTER DATABASE) includes the following statement: ...Show All
