Software Development Network Logo
  • Visual Studio
  • Visual Basic
  • Windows Forms
  • Audio and Video
  • Game Technologies
  • Microsoft ISV
  • Visual FoxPro
  • Visual C++
  • IE Development
  • Windows Vista
  • SharePoint Products
  • Visual C#
  • Smart Devicet
  • SQL Server
  • .NET Development

Software Development Network >> Margotta's Q&A profile

Margotta

Member List

Yeshia
DyngoMan
JGreever
Jan Kučera
r3n
nec4b
max-holz
Shrek.NET
Olavo
MMS2006
suryany
AndyL
user__2006
Bjørnar Sundsbø
Tom_Liu
David Sutherland
Henny
Yahya
DeadDante
HighTower
Only Title

Margotta's Q&A profile

  • Visual Studio 2008 (Pre-release) Streaming audio/video

    I want to create a server that can stream a video to a client but i have no idea where to start. Should i stream the entire file or encode it and then stream it and how can i do that with WCF Woho, it's working, thanks alot! I had to modify the code a bit becouse otherwhise i would get an ArgumentException when reading from the stream the 2nd+ time bytesread = serverStream.Read(data, pos, readBuffer); So now i have a bytebuffer that is just as big as the maxdownloadsize byte [] data = new byte [500000000]; I don't know if that's a good sollution but at least it works. ...Show All

  • Game Technologies: DirectX, XNA, XACT, etc. Orienting 3D objects along a velocity vector

    I'm working on a bullet/missile class for my 3D game and I'm struggling with trying to figure out how to construct the rotation matrix to have my mesh oriented with the direction of my velocity vector (a Vector3). It seems like it should involve two rotations (since one axis will be the up-vector) and probably a little bit of Math.atan2 magic. Can anyone help me out another thing that I've noticed from continuing to mess around with this is that setting the Y component of the velocity vector to 0 has no effect on the way the model is rotated! this is not good! i'm gonna keep tinkering, but if anyone has suggestions, i'd love to hear them. EDIT: oh but it appears that this is a latent effect of putting a - ...Show All

  • Visual Studio Express Editions help splitting text

    I need some help splitting up some text that looks like this BOS DH 34 or other ways like (3 chars) *blank space* (2 chars) *blank space* (1+ chars) the last set can be a single digits or 2 digits. thanks for the advice Like so Dim s As String = "BOS DH 34" Dim textParts As String () = s.Split( New [Char]() { " " c}) -- SvenC ...Show All

  • Visual Basic access to the path "C:\" is denied

    I am attempting to save plain text from a plain box named 'quote'. However whenever I click the save button in the savedialogbox I am returned with the message: "access to the path "C:\" is denied" Any suggestions This is in debug mode & using an admin account, changing the path seems to make no difference Private Sub saveToolStripButton_Click( ByVal sender As System.Object, ByVal e As System.EventArgs) Handles saveToolStripButton.Click Dim MySaveDialog As New SaveFileDialog MySaveDialog.Filter = "Plain Text (.txt)|*.txt" MySaveDialog.Title = "Save File" Dim result As DialogResult = MySaveDialog.ShowDialog() If Not result = Windows.Form ...Show All

  • SQL Server db_datareaders can decrypt data?

    Hi... I want to encrypt data using a symmetric key + certificate, but it appears anyone with simply "db_datareader" can view the decrypted data Is this correct Recreation steps: 1. As a System Admin, log into a SQL 2005 Database Engine. 2. Create some login that you also have access to. Ensure it does not already exist, or inherit any permissions from some existing NT-group. (From here on out, I will refer to it as the "underpriveleged user".) 3. Create a new database of any name. 4. Run the following query against the database: CREATE TABLE [dbo].[MyTable]( [MyColumn] [varbinary](50) NULL ) ON [PRIMARY] GO CREATE USER [DOMAIN\UserName] FOR LOGIN [DOMAIN\UserName] WITH DEFAULT_SCHEMA=[dbo] sp_addrolemember 'db ...Show All

  • SQL Server email with trigger inserted row

    I'm trying to create a trigger which, upon a row insert, an email is sent containing some of the inserted row information. Apparently the built-in stored procedure for email starts it's own session, so I can't use the local variables of the trigger. My solution was to create a temp table, copy the inserted row in, then refer to that from the email SP, then drop the table at the end. When I try to insert a row, it runs for a very long time, then gives an error message saying that it timed out. It was suggested I add COMMIT TRANSACTION in to force it to commit the data to the temp table. Doing this, it gives an error, saying "The transaction ended in the trigger. The batch has been aborted. Mail queued." In the table view, I'm forc ...Show All

  • Architecture How to reverse engineer a class diagram ?

    Hello, I am a beginner in modeling, hope you can help me. Three is a C++ project that I'm trying to reverse engineer a class diagram from my solution. I select the solution node in the solution explorer, and then select Project->Visio UML->Reverse Engineering. VS 2003 says it completed, Visio starts, and I can find all my classes inside the package folder .so it’s working. But after doing the drag and drop, I can not make the relationship among those classes. (Right click->show all relationships) Does the MS Visio 2003 make those relationships automatically Thanks Amir Kanan Hi Amir, Visio only recognizes inheri ...Show All

  • Game Technologies: DirectX, XNA, XACT, etc. Assign to Vector2?

    This is probably an easy question, how do I assign to a Vector2 This was my first bad guess: Game1.Players .Position = (0f,0f); but it didn't work, I know I can assign to the .X and .Y of the Vector2 but I want to do it in one simple step. Also can you do it without creating a new Vector 2 Cheers Alfons Shawn, I think that my language skills might be to my disadvantage(and my lack of experience in programming). What I meant with "2 floats" was two values of the type float, or in other words, is there a way/method to change both the X and Y component in one line /Alfons from Sweden ...Show All

  • Visual Studio 2008 (Pre-release) DataBinding ListBox.ItemTemplate = (DataTemplate)FindSource???

    I would like to DataBind the ListBox with the Existing <DataTemplate x:Key=" "> Template ok,i'm trying to DataBind the Current ItemTemplate that currently Exists in Xaml first here is the C#:: ListBox.ItemTemplate = ( DataTemplate )FindResource( ResourceKey .Equals(StackPanel.GetBindingExpression( BindingMode .OneWay, System.Xml.XPath. XPathExpression .Compile( XPath=@version )))); The Xaml DataTemplate:: < DataTemplate x:Key = " itemTemplate1 " > < StackPanel x:Name = " StackPanel1 " > < TextBlock x:Name = " TextBlock1 " Text = " {Binding Mode=OneWay, XPath=title} " /> < TextBlock x:Name = " TextBlock2 " Text = " ...Show All

  • Smart Device Development Blocking ActiveSync on Device Side

    Is it possible to block ActiveSync on Device side so that when you connect the CE Device to PC, it doesn't start ActiveSync I guess I should try to explain what I'm trying to do, to get a better picture. I'm in charge of writing an application that will download files to Smartphones, and restart the phones. This part I'm done with using RAPI. The only thing is, we want to be able to do this with 10+ phones. We imagined that those 10 phones would be plugged into a USB hub of some sort. I've gotten it to work with 3 phones because when a CE Device restarts, ActiveSync will auto detect the next phone according to the Local Area Connection x (where x is an incremental number) it creates. The only problem with ...Show All

  • Visual C++ How to trim all space character in a string?

    I want to trim all space character in a string, for example there is a string " 1000 + [101001] + [101002] ", how to get another string like this: "1000+[101001]+[101002]". Are there better method to do that thks An efficient version in C only: #include <string.h> #include <stdio.h> int main() {      char src[] = " 1000 + [101001] + [101002] " ;      char * dst = new char [strlen(src)+1]; // worst-case size allocation      char *srcpos = src, *dstpos = dst;      do      {           if ...Show All

  • Visual C++ Is there any win32 API to remove all file in a folder? I hope that one statement is ok.

    Is there any win32 API to remove all file in a folder I hope that one statement is ok. Thanks. The API documentation says that SHFileOperation can do it. I assume pFrom should be set to L"*.*\0". ...Show All

  • SQL Server MDX Sort ASC - on property that has datatype integer - result 1,103,2,203,...... ?

    Hi, i want to sort my Client dimension on its property Client-ID, for example Client Client-ID A 1 B 2 C 103 but this query: SELECT NONEMPTY(ORDER( [Clients].[Clients].[Clients], [Clients].[Clients].Properties( "Client-ID" ), ASC),{[Measures].[Sales]}) ON COLUMNS FROM Sales sorts them like text. Client Client-ID A 1 C 103 B 2 Some ideas First, you probably want BASC instead of ASC, but that is not the problem here. The problem here is that .Properties always returns string data type for b/c reasons. You can do one of the following: SELECT NONEMPTY(ORDER( [Clients].[Clients].[Clients], [Clients].[Clients].Properties( "Client-ID", TYPED ), ASC),{[Measures].[Sales]}) ...Show All

  • SQL Server Keep getting Virtual Memory errors

    Hello, I am wondering if there is a way to solve a virtual memory error We randomly get the following error when trying to run sycn over the http websync. Some clients have 512 MB running sql express, others are full instances that have 1.5 GB. The merge process could not allocate memory for an operation; your system may be running low on virtual memory. Restart the Merge Agent. Greg, The ram monger is replmerge.exe. The cpu usage is sporadic as normal. Jumps between 10% to 95% at times. Nothing stays are 100% bogging down the cd. The peak memory maxed at 699,692k vm size 1,281,524k threads ranged from 5 to 11. So it looks like the replication is just sucking all of the ram away. Is there a ...Show All

  • Visual Studio Tools for Office Error debuging Excel Smart Doc VSTO 2005

    Hi everyone!! I'm developing an Excel C# Smart Doc with VSTO 2k5, it was ok some time but recently when I tried to debug it it lauch an exception but the detail is empty, no exception, I was looking in th event viewer logs and more but nooo, it doens't reach the load event of the workbook, and something strange this project is Source Controlled by Team System, when you get the lastest version the smardoc loses the Microsoft.Office.Core reference, but trust me the COM is there, later it refresh and the reference is fine again, this was happening in another computer of the team but now this reach me, some one can help me please Are you saying that the Template file gets corrupted, have you a shared location you are developing the f ...Show All

©2008 Software Development Network