Amir.S's Q&A profile
Software Development for Windows Vista Problem with (SDK Samples)DynamicUpdateFromWorkflowSample
Hi everyone, i study the SDK Samples "DynamicUpdateFromWorkflowSample" but the dynamic update workflow not work correctly. the code. Thanks Mr.Constantin Mihai. No i not using non-RTM version, and i not have mixed environment. no i using the sample of sdk that installed with product, when extract the sample and run the project will not work correctly .....................i have the same result when re configure steps and run again. can you tell me another solution plz. ...Show All
.NET Development Why Tables.Rows.Count is 0 even though rows are displayed in DataGrid
1. I have a webforms application. 2. I am checking the number of rows is higher than 0 if (DataSet1.Tables(0).Rows.Count() > 0) 3. The value is always 0 even though I have retrieved rows from this DataTable into my DataGrid. Any Ideas Please help.. This occurs in Web-Forms Applications. I thought you only have to fill in the DataSet once. And then be able to use the data contained in it on any future call. But the data is reset when a Post Back occurs. So I am filling up the dataset again in the Page_Load(). Making sure it is not within a "If Not (Page.IsPostBack)" statement. If anybody knows of a better method(where I would only call the DB once) please let me know. ...Show All
Windows Forms how to print chart
hi i want to print chart. iam using mschart control. so that i used the following code. Clipboard.Clear() mchart1.EditCopy() Dim chartcapture As Bitmap Dim iData As IDataObject iData=Clipboard.GetDataObject If iData.GetDataPresent(DataFormats.Bitmap) Then chartcapture = CType(iData, Bitmap) End If e.Graphics.DrawImage(chartcapture, 8, 80) i just copy the chart into clipboard and then convert it into bitmap and then i printed that bitmap. This is working in vs.net 2003 but it is not working in vs.net 2005 one fatal error is coming. The error is The runtime has encountered a fatal error. The address of the error was at 0x7a005c3d, on thread 0x988. The error code is 0xc0000005. This error may be a bug in the CLR or in the unsafe or no ...Show All
Visual C# Enums of chars, strings...?
Why isnt possible to create enums of chars, strings As far as I saw I can only create integer Enums...then I had to work this around by putting a subclass to function as a container of types... Any ideas on this You can only create char and interger enum public enum CharEnum { a = 'a' , b = 'b' , c = 'c' } public enum IntEnum { one = 1, two = 2, three = 3 } public enum MixEnum { one = 1, two = 2, three = 3, a = 'a' , b = 'b' , c = 'c' , } ...Show All
.NET Development Video
How I can play video in my programes with c# What libriries I will need you can use the WMP SDK which is available from: http://www.microsoft.com/windows/windowsmedia/forpros/platform/sdk.aspx Then simply read the SDK manual, overall it is simple to implement. Just drag and drop the component on the form then in your code, access it using its properties and methods. To start playing a file, i believe its something like... this.theMediaPlayerComponent.URL = someFile; ...Show All
SQL Server How we add date to backup file
HI, here is our backup command and i like to add date in the backup file name. So daily it add date to the backup file name. Can any one let me know how I can do that. C:\BAK\acct_backup_%date .bak BACKUP DATABASE [acct] TO DISK = N'C:\BAK\acct_backup.bak' WITH NOFORMAT, INIT, NAME = N'acct-Full Database Backup', SKIP, NOREWIND, NOUNLOAD, STATS = 10 GO This should do. declare @f sysname set @f=N'C:\BAK\acct_backup_'+convert(nvarchar,getdate(),112)+N'.bak' BACKUP DATABASE [acct] TO DISK =@f WITH NOFORMAT, INIT, NAME = N'acct-Full Database Backup', SKIP, NOREWIND, NOUNLOAD, STATS = 10 GO ...Show All
Smart Device Development Logical NOT (!) operator broken? What's happening?
Does anyone have any idea why the logical not operator might not be working in Visual Studio 2005 compiling for ARMv4 Consider the following code. int test = -1; int test2 = !test; TCHAR temp[256]; wsprintf(temp, _T( "%d" ), test2); if (!test) ::MessageBox(NULL, _T( "Not!" ), _T( "Result" ), MB_OK); else ::MessageBox(NULL, temp, _T( "Result" ), MB_OK); The correct result is a messagebox which says "Not!", right Instead I get a messagebox saying "0" - that's wrong! Can anyone else duplicate this What could possibly be causing it >int test = -1 >if (!test) (Why can't I [enter] and get a single-space LF ) You still have to wa ...Show All
SQL Server Error while trying to get predictions from relational DB
I am trying to get predictions and insert them into a DB table. Following is the code I am using , but I am getting an error saying ' An error occurred while preparing the query , Pl. help. begin declare @v_query varchar(5000); declare @full_query varchar(5000); declare @v_dbquery varchar (200); set @v_dbquery = char(39)+'SELECT [ProspectAlternateKey], [FirstName], [LastName], [MaritalStatus], [Gender], [YearlyIncome], [TotalChildren], [NumberChildrenAtHome], [HouseOwnerFlag], [NumberCarsOwned] FROM [dbo].[ProspectiveBuyer]'+char(39); set @v_query = 'SELECT [TM_Cluster].[Bike Buyer], t.[ProspectAlternateKey], PredictProbability([TM_Cluster].[Bike Buyer]) From [TM_Cluster] P ...Show All
Software Development for Windows Vista Writing Resource Managers for System.Transactions to MTS/DTC and XA
We are trying to write a durable resource manager that works with System.Transactions. I need to use mts/dtc talking to xa where the actual database is on a remote system. I have read all of "Implementing a Resource Manager" and everything else I could find but could not figure out how to couple the .NET resource manager with xa. We have working distributed transaction code for OLEDB and ODBC using mts/dtc and xa. I really need sample code and/or hints about writing such a resource manager like this. When you say "couple the .NET resource manager with xa" what is the scenario you are trying to hit Are you referring to setting up a 1Pipe/2Pipe connection to an XA enabled Resource Manager using a System.Tra ...Show All
Game Technologies: DirectX, XNA, XACT, etc. 3d model arrays and array positions
Hi everyone i've been messing around lately again trying to create myself a FPS engine and i'm working on making a level right now...so i'm using a plane thats been scaled up and i have made it into a array: Model[] planearray = new Model[10]; thats my code for it..i'm not sure if that will make 10 planes but i cant find out since they would all have the same location and rotation..so i want to know how i can have it so each plane has a different location.Can somebody help please Thanks xna3der xna3der wrote: That makes perfect sense!Thanks when i get a minute here i will try it out..again thanks! Now i have another question..will i have to have each one drawn separately or can i have them all dra ...Show All
Visual C++ Looping through struct/class data members
Hi, I'm hunting for some elegant way to loop through all the members of a class (or struct), without having to name them specifically. I have several very large structs, and I want to read in their values (say from a text file) using some kind of loop. Is there a way to dynamically find out 1) how many members a struct/class has and 2) their names I thought the starting point might be something like a pointer to a specific data member in a class (I'll have to make classes out of my structs): class clsMyClass { int i; float f; clsUserType c; } clsMyClass objMyClass; int clsMyClass::*ptrMyClass; ptrMyClass = &clsMyClass::i; (objMyClass.*ptrMyClass).i = 20; What I want, however, is to be able to make ptrMyClass someho ...Show All
Windows Forms I know there's an easy answer to this one...
I have a SQL database connection in my project, and I only need to insert a value into one of the tables. I have created a stored procedure in my database to do this, and I am seeing my "QueriesTableAdapter" with that stored procedure when I edit the dataset. I have one simple form. In my code, I need to call that stored procedure, so I know that I need to somehow add the "Queriestableadapter" control to my project. The "Queriestableadapter" control is not showing up in my toolbox to be able to add it to the form (and, therefore, reference it). I have done this in other projects, but I can't remember how I was able to get it to show up. Help! Thanks! Edit your datasource ...Show All
Visual Studio 2008 (Pre-release) What is the status of Windows Presentation Foundation Everywhere (WPF/E)?
Hi, I'm interested in Windows Presentation Foundation Everywhere (WPF/E) as a possible alternative to Adobe Flex development. All the information and blogs that I can find are from back in March to May, e.g. http://blogs.msdn.com/mharsh/ Has anything happened since then What tools do I need to develop in WPF/E Where do I get the browser plug-ins (miniturized CLR for IE, Firefox, and Mac) Thanks, Mark WPF/e is on a different shipping schedule. My original impression is that RTM for WPF/e was at least 6 months after RTM of .NET 3.0. Of course, no one is saying anything. WPF/e is basically an entirely different beast than the full WPF. ...Show All
Visual C++ Missing icons on MDI child windows
Having written code to create MDI master and child windows using Win32 API, I have discovered that when using the application under the Windows XP theme, icons assigned to the MDI child only appear when the child is maximized. When the child is minimized or normalized, a white space appears where the icon should be. The icon is assigned using - SetClassLong(widgets[1].hwnd, GCL_HICON, (LONG)geeicon); The icons appear using the same code using Windows 2000 and Windows XP, classic theme. Also if you start the application using classic theme and then change to XP theme the icons stay attached to the child windows. It is only if you start the appication in Windows XP theme that the icons are missing. Any ideas ...Show All
Visual Basic Shut Down PC
Is there a way to shut down a PC using the framenetwork I tried the "shutdown /s" command but the shell doesn't work on my PC. Thanks. That's what is probably is, .net won'd detect it unless you use .net statements. Even is you use shutdown.exe it doesn't find the file. ...Show All
