CiNN's Q&A profile
Silverlight (formerly WPF/E) WPE/e inside a webpart
I have actually some webparts that show flash controls. I'm interested in replacing these for WPF/e controls. I have tried some things but I just couldn't make it work. Does anybody know if this is posible and how can I implement it Thanks!! Hi Matias, you could simple add the JavaScript file aghost.js and add the JavaScript line to add the control: http://channel9.msdn.com/go/wpfe/quickstarts/FileSetup-frames.html Or are you getting any error message Maybe you are missing the mime type settings. ...Show All
Visual Studio Express Editions media time calculation
Hi need the maths calculation for this: Private Sub Button1_Click( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If OpenFileDialog1.ShowDialog Then mplayer1.URL = OpenFileDialog1.FileName Timer1.Enabled = True Private Sub Timer1_Tick( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick Label1.Text = mplayer1.currentMedia.duration But It displays the length as 345.232 for example. how would I format this as 3:00 for example ok not too much luck unfortunately. I thought the DurationUnitChange event would work but not quite. Well the current idea that is present is to do as ...Show All
Windows Forms xml transform in windows forms application
I have really enjoyed using the XML control in web applications and now have a need to use xml data and an xsl stylesheet to display formatted data inside a window forms application. I don't see an XML control so I've been playing with the web browser control. Does anyone have suggestions for a good way to accomplish this Thanks, John Everything you're looking for can be found in the System.XML namespaces -- in solution explorer right mouse click to add a reference to the xml stuff and add a using (C#) or imports (vb) to your code file. ...Show All
Visual J# ToolStrips, Text Boxes and loads of trouble
ok, essentially what I'd like to do is add a rich text box to a toolstrip. I really dont have much of a clue of where to even start with this. Thanks a bunch - worked fine. Is it possible to add a UserControl to a toolbar Tried it with the following code to no avail. Workspace.Modules. Notepad notes= new Workspace.Modules. Notepad (); ToolStripControlHost host1 = new ToolStripControlHost (notes); toolStrip1.get_Items().Add(host1); toolStrip1.Refresh(); ...Show All
SQL Server Identity sequence of multi-threads insertion
Recently I'm working on a multi-thread solution based on SQL-Server, now I'm facing such a problem: Suppose I have process No.1(with multi-threads) inserting data to Table A, which has its identity column auto generated. And process No.2(also with multi-threads) retrieving data from Table A ,generate some records and insert the result into Table B. Both of these two processes are doing batch processing(batch retrieving and batch writing), and they are running parallelly. Now since process No.2 retrieve data sequencely by the identity of Table A, it found there exists missing results. This is due to that records with bigger identities are not necessarily commited earlier than those who h ...Show All
Visual C# Where are the messages going to?
hi everybody I've already successfully implemented a globally low level keyboard and mouse hook and it seems that this is all .net managed code could provide in global hooking. But after I got the message by the hook, where is this keyboard or mouse message going to the parameters and structures of hook event don't contain that information. any idea thanks in advance I'm writing program to redirect keys and hotkeys of a specific application. So after I get the keyboard messages I would like to know if the targeted application will receive them. If so, I can do something in the hook. ...Show All
Visual Basic Help! VBScript text file read/write adding garbage on Japanese windows...
I have a very basic VBScript that's launched from our WISE Installer that does a search and replace on a text file on the user's system. The script works fine on US Windows, but for some reason on Japanese Windows, it inserts hex "81 00 45 00 BF 00" before the 3rd byte at the beginning of the first line in the file. I've searched the net and seen issues regarding reading and writing binary, but nothing about text... The main code is thus: Set FileSystemObject = CreateObject("Scripting.FileSystemObject") Set WshShell = CreateObject("WScript.Shell") LocaleLCID = WshShell.RegRead("HKEY_CURRENT_USER\Control Panel\International\Locale") function UpdateVersionNumbers(sFileName, SearchText, ReplaceText) ...Show All
.NET Development Problem inserting data to SQL
well here is my code of ISERT in C# =========================================== InitializeComponent(); SqlConnection coneccion; coneccion = new SqlConnection("Data Source=sagara\\sqlexpress;" + "Trusted_Connection=yes;" + "database=Hospital; "); SqlCommand orden; string q = "INSERT INTO prueba (nombre, apellido) VALUES (@txtNOMBRE, @txtAPELLIDO)"; orden = new SqlCommand(q, coneccion); orden.Parameters.Add(new SqlParameter("@txtNOMBRE", SqlDbType.Text)); orden.Parameters["@txtNOMBRE"].Value = this.txtNOMBRE.Text; orden.Parameters.Add(new SqlParameter("txtAPELLIDO", SqlDbType.Text)); orden.Parameters["@txtAPE ...Show All
SQL Server Using Alias in update statement
Hi, I am using MsSql2005 and wondering how to create aliases inside update statements. I need this, for a table variable inside a procedure. UPDATE @TempTable SET Field1 = ( SELECT RealTable.Field2 FROM RealTable WHERE RealTable.Field1 = @TempTable.Field1) This statement doesn't work because I need to use an alias for @TempTable. How Thanx a lot You can not use a variable for the name of a table unless you use dynamic SQL. declare @TempTable varchar(50) set @TempTable = 'sometemptable' declare @sql varchar(2000) set @sql = 'UPDATE ' + @TempTable + ' SET Field1 = ( SELECT RealTable.Field2 FROM RealTable WHERE RealTable.Field1 = ' + @TempTable + '.Field1)' exec sp_execut ...Show All
Visual Basic Array.Findall Canceling
writingapplication Thanks Timothy Ng MSFT . ...Show All
Windows Forms Resizing a control problem in design mode
I have created a UserControl and a designer for it and I am having problems with the adornments drawing incorrectly when resizing the control in design mode. When resizing the control, the adornments are drawn to the original control bounds and not to the resized control bounds. If I select something else, and reselect the control, the adornments draw correctly. Here is how I am declaring the UserControl: [ Designer ( typeof ( UserControl1Designer ))] public partial class UserControl1 : UserControl { public UserControl1() { InitializeComponent(); } } Here is the designer code: class UserControl1Designer : System.Windows.Forms.Design. ControlDesigner { protected override void PostFilterProper ...Show All
Visual C# Server.mapPath
hi, everyone. I using server.mapPath to set as my dir but it could work. Anyone have idea why is it so string myDir = server.mapPath( "" ); especial this part of code.i wan to get any xml file from my folder rather than using absolute path like this @"H:\WSAT\WSAD Assignment"; becuase when i move my file i can just view it without changing my address. public static string [] getXMLFile() { string myDir = server.mapPath( "" ); string fileType = "*.xml" ; string [] files = Directory .GetFiles(myDir, fileType); return files; } ya i got it.. Thanks but i have another problem is that : Error: A field or proper ...Show All
SQL Server SSAS 2005. Supported collations.
Does SSAS supports Latin1_General_BIN2, that is new for SQL 2005 I can't select it using UI, but can set it manually (as well as many another nice things). Analysis Services re-uses library implementing SQL Server relational engine collations. All collations that are considered by relational engine windows collations (once that have not SQL_ prefix) are supported by Analysis Services. I remember trying Latin1_General_BIN and that worked pretty well. Dont know about Latin1_General_BIN2, try it. Edward. -- This posting is provided "AS IS" with no warranties, and confers no rights. ...Show All
Visual Studio Team System VssConverter - how to exclude deleted projects from migration?
Hello, We are migrating a VSS database to TFS. The original database contains several quite big deleted projects that we don't need to migrate to TFS. However, VSSConverter migrates them anyway along with normal projects. Is there an option for the tool to skip deleted projects from migration Thanks, Leonid If your database is not too big, I would recommend making a copy and purging the VSS database. That would get rid of the deleted items. If that is not practical, create a temp folder, copy (link) the reqd. files to this folder and migrate it. I'm just thinking aloude, so please ensure that deleted items are not linked as well. Hope that helps. Rahul Bhide ...Show All
Visual C++ load and time
dears i need an axample how to get time and how to load numbers from file in the disk i found this in the help but it is not printing #include <stdio.h> #include <dos.h> int main(void) { struct time t; gettime(&t); printf("The current time is: %2d:%02d:%02d.%02d\n", t.ti_hour, t.ti_min, t.ti_sec, t.ti_hund); return 0; } i replace printf by cout then the statment is printed but the time no pls help thanks the time still not printed , only " the current time is" i want to see the time, i think they are empty , what is the problem thanks ...Show All
