Jump to content
Xtreme .Net Talk

fguihen

Avatar/Signature
  • Posts

    251
  • Joined

  • Last visited

Everything posted by fguihen

  1. I want to capture and be able to modify ( brighten, color, contrast) video from a webcam in C#. I know there are a few ways to do this, however im not sure which is the best. Would i be better going with DirectShow, or with some avicap32.dll or some other method? Has anyone any expirience on this?
  2. not sure if this is an SQL issue or a development issue, but as im using c# and visual studio so il place this here for now. I wrote a small app to script out jobs from sql server. it worked fine, and then , without any changes it stopped working. I got the error: Could not load type 'Microsoft.SqlServer.Managment.Smo.AgentJobBaseCollection' from assembly 'Microsoft.SqlServer.Smo, Version=9.0.242.0, Culture=neutral, publicKeyToken=89845dcd8080cc91'. I checked the version of the Microosft.SqlServer.Managment.Smo Dll installed in sql server installation dir, and its version 9.00.1399.00, so i try to update the gac . The version in the gac is 9.0.242.0. I cannot delete it via the gac MMC plugin as it tells me it is required by another app. I cannot delete it via GacUtil for the same reason. I went to the windows directory to the assemblies folder and tried deleteing it there, but also could not as it is required by another application. How do i delete the old version from the gac and install the new version? I was going to try editing the registry, but when i searched for that specific assembly "Microsoft.Sqlserver.Managment.Smo, i find thousands of entries, and i am not editing each one. that would take me days. Any help would be greatly appriciated.
  3. i have a string, and it has to become a filename. the problem is it contains backslashes in many places. ive tried using the string.replace method to replace the \ with blank spaces but it doesnt work. its the same story with doubble quote charachters (the " charachter).what am i doing wrong?
  4. so on vista, when i use stream writer to create a file anywhere i specify on my pc. apparently though, i am not authroized to do so. i believe this is a security "feature" in vista, as i can create files if i specify my home directory ( in C:\users\username). does anyone know a way around this?
  5. You know the way when you open an explorer window in windows, and you can sort by basically any attributes the files you are viewing have, well, are all those attributes programmed into windows, or does it just look at the files and know what attributes it can display? On the attributes themselves, is there a standard way that attributes are stored in a file? i know they are at the end, but are there a set of charachters that denotes the start of the attributes section of the file?
  6. I have many many rows added to a datagrid. there is a checkbox in the first column of each row. i need to be able to extract the data for each checked row, and also count all the checked rows. does anyone know how to do this. i added the check box in the column properties of the datagrid in the visual studio designer, in case that matters.
  7. Ive done a small tutorial online and created what i think is a checkbox that can be used on a toolstrip. the problem is i dont know how to add it to the tool strip. can anybody advise where to add this, and what code to use to add it. my ToolStripCheckBox code is shown below: class ToolStripCheckBox:System.Windows.Forms.ToolStripControlHost { public ToolStripCheckBox() :base (new System.Windows.Forms.CheckBox()) { } public CheckBox ToolStripCheckBoxControl { get { return Control as CheckBox; } } //expose checkbox.enabled as property public bool ToolStripCheckBoxEnabled { get { return ToolStripCheckBoxControl.Enabled; } set { ToolStripCheckBoxControl.Enabled = value; } } protected override void OnSubscribeControlEvents(Control c) { // Call the base method so the basic events are unsubscribed. base.OnSubscribeControlEvents(c); CheckBox ToolStripCheckBoxControl = (CheckBox)c; // Remove the event. ToolStripCheckBoxControl.CheckedChanged += new EventHandler(CheckedChanged); } protected override void OnUnsubscribeControlEvents(Control c) { // Call the base method so the basic events are unsubscribed. base.OnUnsubscribeControlEvents(c); CheckBox ToolStripCheckBoxControl = (CheckBox)c; // Remove the event. ToolStripCheckBoxControl.CheckedChanged -= new EventHandler(CheckedChanged); } public event EventHandler CheckedChanged; private void OnCheckChanged(object sender, DateRangeEventArgs e) { if (CheckedChanged != null) { CheckedChanged(this, e); } } }
  8. i need to debug a class librerary project. i go to the debug menu, and click on attach to process, i attach it to the sqlsvr process, as its a clr sproc i want to debug. any break points i create just give me the error "the breakpoint will not currently be hit. no symbols have been loaded for this document." i have tried restarting my sql service, tried reopening my project but no luck. has anyone got any ideas here?
  9. cool enough. just looks a bit messy. thought there might be a "sexy" way to do it!
  10. im writing an app that scripts a database out to a directory. the user can select to only script tables, or permissions, or sprocs, or all. i dont wana have code like: if(scripttables == true) { //script tables } if(scriptSprocs == true) { //script sprocs } if(scriptPermissions == true)....... that could go on forever, depending on how many groups of things you want to script. can delegates be used or something that looks a little better?
  11. In smo im trying to script each table out to a file. I can script each table to an array as shown: Table[] tables = new Table[db.Tables.Count]; db.Tables.CopyTo(tables, 0); SqlSmoObject[] smoObj = new SqlSmoObject[tables.Length]; Array.Copy(tables, smoObj, tables.Length); Scripter scripter = new Scripter(s); StringCollection scriptsList = scripter.Script(smoObj); string[] scripts = new string[scriptsList.Count]; scriptsList.CopyTo(scripts, 0); i expected each array of the scripts array to have a table creation script, but no. element 0 of the array contains the text: SET ANSI_NULLS OFF element 1 of the array contains the text: SET QUOTED_IDENTIFIER ON element 3 of the array contains the text: CREATE TABLE [dbo].[_EXRATE02EuroZoneCurrencyRate]( [CurrencyCode] [char](3) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL, [FixedExchangeRateAmt] [float] NOT NULL ) ON [PRIMARY] this continues throughout the array. how am i supposed to find the end of one script and the beginning of another? will SET ANSI_NULLS OFF be at the beginning of each table script, if so i can create a new script each time i find that line.
  12. i want to create a simple site using passport, just cause i have time to spare. as far as i know i wont be charged for this while using a dev account. i have a few questions though. when regestering for a passport account for my site with microsoft, it asks for domain, and DNS. now, as im debugging and dev'ing using VS 2006, the domain is simply localhost, so should i give them the name of my machine? what do i give them for dns?
  13. i want to hash a users password and store the hashed value on a database. i want to know where to perform the conversion to hashed value? should it be in jscript on the page, or in c# code on the server? if its done in c# code on the server, the raw password is sent to the server first, and i imagine this is not as secure as doing it on the machine and then saving the hashed password. what have you implemented in relation to this?
  14. the article on from fourGuysFromRolla was exactly what i was looking for. thanks
  15. is there an event in asp.net 1.1 thats triggered when a request for the page is recieved? i want to take info from this request ( browser type , location ) and what not.
  16. i have found tons of tutorials to make simple login pages in asp.net but none outline the process, saying what happens. its usually a jumble of code. can someone say step by step what hapens, like , whats checked first , the config file or the database ? i just need a simple step 1, step 2....not looking for code or anything. thanks all
  17. perfect !!! exactly what i was looking for. couldnt get my head around this bit. thanks ! :)
  18. i have a client connecting to a server. they exchange mesages fine the first time, but i dont know how to keep the server listening for a client indefinately. anyone give any pointers on this?
  19. i want to improve my programming ( or get back to my programming after a bit of an occupational detour). i want to create a simple 2 player game, like pong, where there is constant action (in this case, the ball moving).i want to be able to play this between two computers, linked by a server. my aim is to write the server to allow the two pc's to play the game and the client to be on each pc. how do i link the 2 client apps, and keep the ball in the same place on the screen in each client? does it involve constant sending of data? would i be better to go through the server or just use the server to link the two clients? has anyone any examples i may look at or tutorials? thanks all
  20. its on a intranet, so it wouldnt be in a search engine.there is always a default page, id say the page name could be guessed, but its not very likely. theres no way someone can "scan" an IIS Box to see what pages it has on it? i wouldnt think so, but i cant be sure. regardless the pages in question are being moved completely
  21. i have a page or two on a server that interact with a database. they have been disconnected from the main site, so anyone using the site is unaware of the pages. is there a way that someone could, with or without knowing the pages are there, scan the server or check the server for any pages that are not attached to the main site?
  22. i want to write a chat client and server , just to keep my programming skills somewhere near ok, since i dont do any c# at work at present.i have a few questions: what is the best method: Remoting or web services or something i havnt thought of? how do i test on just one machine, i can run the server, but the clients ,if i run two of them on my machine will both have the same ip address?
  23. if i want to stop the iis service, what command does it? i am using "net stop iisadmin" at the moment, but im not sure if thats totally stopping iis. how do i make sure iis is completely stopped?
  24. i can create the plugins when i implement one interface, but when the class that is a plugin implements two interfaces or an interface and an abstract class i get an error on this line objDll is an Assembly foreach( Type OT in objDll.GetTypes()) { the error just says "unable to load one or more of the requested types. retrieve the Loaders Exception Property for more information. any ideas??
  25. found a solution. the Attribute and the class implementing the attribute were in the same namespace. once i put the attribute into a different namespace all worked. cant for the life of me think why it would have to be in a different namespace. could this be a bug?? if anyone can come up with an explination for why this is the case it would be great.
×
×
  • Create New...