WangJiping's Q&A profile
Game Technologies: DirectX, XNA, XACT, etc. how to set xbox 360 resolution?
Hello guys! I'm deploying my game to xbox 360. The deploy is perfect, but my game aways presented on 800x600 screen. Graphics.PreferredBackBufferWidth value is 800 Graphics.PreferredBackBufferHeight is 600 Graphics.GraphicsDevice.DisplayMode.Width is 1360 Graphics.GraphicsDevice.DisplayMode.Height is 768 how can I to set the resolution My monitor is an AOC 19" widescreen... Thanks! Hello shinji i just joined the xna membersclub and i am triyng to get trow the tutorials and i have a couple questions can you add me to your friends list and help me out My gamertag is Persian Lion,thanx ...Show All
.NET Development Transferring Image File Using Sockets
Hi all, I have an Scenario where i have to send an Image (max size of 40KB) from the Windows Mobile 5.0 to an webserver. Currently iam using an Web Service to transfer the file as Byte array. But the problem iam facing right now is tat the Transfer takes a long time and transaction fails frequently. I heard tat there is an option using Socket where you will be able to send data much faster. Anyone know how to use Socket to send the image from the Mobile to the server. Pl. give your valuable inputs on this issue. Thanks in Advance Regards Biju S Melayil If you have to use sockets, need performance then it can be done in Windows Application. Hosting a Listner means that run the server application on a c ...Show All
SQL Server Advanced Lookup in a Data Flow
Here is the deal - I have a flat file with 2 fields: ProdNum FeatureCodes 1 A01, B22, F09 2 C13,C24,E05,G02,G09,J07,J09,M03,M17 3 J07,M01,M17,N02,N11,N13,X15 The I have Excel file like: Code Description A01 Handicap features B22 Smoke-Free F09 Tinted Windows C13 Picnic Area C24 Extra Storage J07 Tile Flooring M01 Central Airconditioning The result in a database needs to be like: ProdNum Features 1 Handicap features, Smoke-Free, Tinted Windows 2 Picnic Area, Extra Storage, ..... 3 Tile Flooring, Central Airconditioning, ..... How can I do this in a data flow - any ideas Thnx for the idea - however, there are 665 features codes - so pivoting / unpivoting ...Show All
SharePoint Products and Technologies Capacity Planning Sharepoint 2007 DBs
As a DBA, I am trying to do some capacity planning for sharepoint 2007 dbs. We will have a large site of 2+TB and I am trying to get an idea of what sizes to expect once the DBs grow to full size. The database types are Content (multiple), Sharedcontent, Search, SharedSearch, AdminContent, and Config. Can anyone offer any advice. Any advice on what type of activity to expect from each of these databases would also be appreciated. Thanks! dba72, There are no hard and fast rules on this and you will need to work with the SharePoint administrators to ensure your site collection content databases are managable. These two posts by Joel Oleson provide a good start point. http://blogs.msdn.com/joelo/archive/2007/01/31/tips-on-si ...Show All
Visual C# Datagrid - unbound
VS 2005 std. Using an unbound datagridview that has 5 columns, when columns 1,2 or 3 change I want to show the total for columns 1+2+3 in column 4. Column 5 is a tickbox, how can you tell if its ticked or not. Thanks in advance. the previous code assumed that the columns ValueType is int,decimal,decimal and decimal you can change your column ValueType to make the previous code work Or Change it as the following if (e.ColumnIndex == 1 || e.ColumnIndex == 2 || e.ColumnIndex == 3) { int colOne = int .Parse(dgvInvoiceItems.Rows[e.RowIndex].Cells[1].Value.ToString()); decimal ColeTwo = decimal .Parse(dgvInvoiceItems.Rows[e.RowIndex].Cells[2].Value.ToString()); decima ...Show All
Windows Forms Is there any way to use my own usercontrol as RootComponent of DesignSurface?
As I know, Form, UserControl and Component can be used as RootComponent of DesignSurface. but, I'd like to make a new custom usercontrol and adjust it as RootComponent. MSDN said 'have to implement IRootDesigner'. but, it's difficult to find sample. How can i get some sample ps. I'll add below functions into new custom usercontrol. 1. allow special control to be child. 2. arrange child controls automatically 3. etc.. Thank you. I found a solution. I made my custom control's Designer inherit 'System.Windows.Forms.Design.DocumentDesigner' as IRootDesigner. thanks and regards sangmin ...Show All
SQL Server Bulk insert into an IDENTITY column
I have this table in my SQL2005 DB CREATE TABLE StringTable ( StringID int, LanguageID int, Category smallint, String nvarchar(max) ) I also have an Excel spread sheet that contains the above columns. I can insert the rows from the spreadsheet into the table using the sql client class SqlBulkCopy. No problems so far. However, I have now changed the above table so that the StringID column is an IDENTITY column. I haven't changed the spreadsheet at all. I still want to insert the same values as before. So I now do this (in code using a SqlCommand object): SET IDENTITY_INSERT StringTable ON <...do the bulk copy as before...> SET IDENTITY_INSERT StringTable OFF Theoretically a sound plan I think so... excep ...Show All
Windows Live Developer Forums WLM Addin: error 8013150a when i load my addin
Hello, I'd like to program an addin that will display a little window (winform) with few controls (buttons and text edits). Is it possible What is the simpliest solution to make this I'm using C# with visual2005. Thank you. R.P. Try this, shows options dialog with few controls. The form appears when you click in settings button or you type !menu in a conversation window. You talk about that === Edited by David_ES @ 12 Oct 2006 11:15 AM UTC=== public class ClassLibrary1 : IMessengerAddIn { private MessengerClient messenger; private Button aButton, aButton1; private ListBox list; private TextBox texto, texto1; public Microsoft.Messenger.MessengerClient messenger2 = new Microsoft.Messenger.Messen ...Show All
SQL Server Copying a project. How?
We recently migrated to SQL2005 and have moved all OLAP databases to the new server. I need to create new OLAP databases. In SQL2000, just a copy would do it, but I am having problem in 2005. I tried to script the database as 'create' or even created an empty one and try to change it by 'alter' from a valid DB, but no luck (XMLA file was modified to have the new names). Any pointers, suggestion would be appreciated. I know how to change the DataSource and DataView later, just need to know how to copy one!!!! Also please let me know what tool is used (Management Studio, Visual Studio, etc...) Thanks in advance! There is a special project in BIDS where you can reverse engineer a SSAS 2005 database. If yo ...Show All
Game Technologies: DirectX, XNA, XACT, etc. How to format gameTime, or float.
This is probably an easy question. I want to split a float into whole integers and the first 2 numbers after the "," and pass it into 2 different int's. example: 987,645 int a should be 987 int b should be 64 And where can I find a list of all .ToString format options (ToString("F0") Cheers Alfons The float data type doesn't actually contain an commas, you will have to format them yourself. However, you could convert the float to a string and the parse the string out into different integers: float f = 123456f; string t = f.ToString("000###"); int i1 = Convert.ToInt32(t.Substring(0, 3)); int i2 = Convert.ToInt32(t.Substring(3, 3)); The format string passed into ToString will ensure t ...Show All
Audio and Video Development A question about numerical virtual key code
Hi ALL In the spec, there is only ten digits "0" --- "9"( VK_0 --- VK_9), but I want to define a virtuak key for a number larger than "9" for eaxmplae "23" Consider this case, there are several buttons defined in the markup, and we need use Left/right/down/up key to select certain button and then press OK for trigging the related event. The easier way is define accessKey property for each button, however, there are just ten digits defined in the Spec. is there any way to combine them to compose a number larger than 10 thanks Are you looking to create a listener for the user simulatenously pressing the 2 and 3 keys Or are you looking for the virtual k ...Show All
.NET Development Socket Send - Multiprocessor Data Corruption
I have an application that sends out large packets over a tcp socket. If smaller packets are sent, the packets reach their destination without corruption. However, the tail end of larger packets are corrupted. If I run the application on a single processor machine, the large packets are not corrupted. This problem only seems to happen on multiprocessor machines. I print out the packet before and after the send, and the packet seems to be correct in both cases. What about the Socket.Sent (c#) could be causing the data corruption The application is single threaded. I am using our proprietary protocol over TCP/IP which contains the packet length in the header. The packet received is equal to the size of the p ...Show All
Visual Studio Cannot Open .sln (Solution File)
I installed Microsoft Visual Studio 2005 Version 8.0.50727.42 (RTM.050727-4200). Other information: Microsoft .NET Framework Version 2.0.50727 Installed into: Windows Server 2003, Standard Edition, Service Pack 1 Steps to duplicate the error: 1. Click Start\All Programs\Microsoft Visual Studio 2005\Microsoft Visual Studio 2005 2. Click File\Open\Project/Solution 3. At the Open Project dialogue box, navigate to the location of *.sln file, select *.sln file, click open. I get this error: The application for project 'C:\vbnet03sbs\chap01\MusicTrivia\MusicTrivia.vbproj' is not installed. Make sure the application for the project type (.vbproj) is installed. ------------------------------------------------------------ ...Show All
Visual C++ Compile-time class generation causes C++ Compiler to Crash
Consider this example: template <int N> struct Factorial { enum { value = N * Factorial<N - 1>::value }; }; template <> struct Factorial<0> { enum { value = 1 }; }; void foo() { int x = Factorial<4>::value; } It compiles and runs fine. But if you remove the code in bold, the C++ compiler crashes (probably because of a stack overflow). I tried looking for a support link in order to report this but found none. P.S.: code sample taken from http://en.wikipedia.org/wiki/Template_metaprogramming I once tried a depth of 1,000,000. Obviously the compiler crashed... http:// ...Show All
Visual Studio Express Editions How to register msmapi32.dll ?
hello, while registering msmapi32.dll using regsvr32.exe , i get the following error. since my app is not able to sent mail, i tried to register it, but fails. I tried to find the processes using it, but its only the system and explorer that uses it. pls suggest. --------------------------- RegSvr32 --------------------------- C:\Program Files\Common Files\System\MSMAPI\1033\msmapi32.dll was loaded, but the DllRegisterServer entry point was not found. DllRegisterServer may not be exported, or a corrupt version of C:\Program Files\Common Files\System\MSMAPI\1033\msmapi32.dll may be in memory. Consider using PView to detect and remove it. --------------------------- OK --------------------------- regards Kirann ...Show All
