Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
S

sodevrom

@sodevrom
About
Posts
52
Topics
21
Shares
0
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

  • Upload Videos To YouTbe using PROXY - Gdata
    S sodevrom

    Hello guys, The developers of GData (YouTube API) don't reply, so I hope somebody from cp can help me. I am trying to upload a video to YouTube using their API with private proxy. I always get 403 forbidden error. If I removed the proxy, and upload normally, it works fine. I tested the proxy with Firefox and it uploads correctly (from their web interface... youtube.com), but in my app ... well it does not work. The proxy is valid (tested with myip.com and it tells the proxy IP). The source code of the YouTube uploader is here: http://www.sodevrom.net/TestUpload.zip Open the sln (Visual STudio 2010 C# .net) and in the form class, double click on the button and edit your username/password/developer key. After that, simply run the app and press the upload button. You will see that it fails :( If you go to DownloadYouTube.cs file and remove the proxy (simply comment the liens from the constructor) you will see that it works. What can be the problem ? How can this be solved? Hope somebody has experience with this and can help me. Thanks! Vlad

    .NET (Core and Framework) csharp help visual-studio com json

  • How to communicate with Flash from WebBrowser ... For uploader [modified]
    S sodevrom

    Hello, I am trying to make myself a simple metacafe uploader, and I am using the webbrowser to do that. Everything was working great with loggin in, navigating to upload page etc... I used the HtmlElement and setAttribute/Invoke to click and set the text fields:

    HtmlElement password = wb.Document.All["sPass"];
    assword.SetAttribute("value", this.password);

    Now I have a problem. To upload a video to metacafe, you first need to click on a flash button caleld Upload. There, a window appears to select a file, and after you press OK, the upload begins and you can enter the form information. My question is this: How can I enter the video file without seeing a popup window? Knowing that it's flash :(. Here is how the flash object looks: http://www.sodevrom.net/sample.html Above I copied only the part from the upload page that it's important to me. As you can see, a simple flash file appears. Now I want to simulate the click/enter of file without showing the file window. Any ideas on how I can do this? Thanks

    modified on Sunday, October 24, 2010 1:31 PM

    C# question csharp html adobe help

  • GWT-RPC call from c# .net (google keywords tool external) help
    S sodevrom

    Hello, I know how to use the httpwebrequest/response :) I am not really a "noob" in programming. Now I decided to take a totally different approach, and get the text that I need by using a WebBrowser control. This is the best way to go I think, because it takes care of all the problems. I have only one issue. For example to complete a field I use this: HtmlElement username = this.wb.Document.All["username"]; username.SetAttribute("value", "aaaaa"); But how do I get the entire text of the webbrowser? It seems that if I use webBrowser1.DocumentText , it does not retrieve all the HTML code (it does not return everything that is visible). I think the problem is with dynamic code (javascript) How do I get everything? Thanks, Vlad

    C# csharp html com agentic-ai debugging

  • GWT-RPC call from c# .net (google keywords tool external) help
    S sodevrom

    Hello guys, I have an app made that worked with the old Google Keywords Tool External. It worked perfectly until a few days ago when they dropped the new interface. Now I can't seem to crack this myself, and I need some help. Using opera dragonfly (helps debug http requests) I managed to see how everything looks "in the background" but I don't understand a thing now. With the old site,everything was crystal clear, but now it's not. The new website is located here:https://adwords.google.com/o/Targeting/Explorer?\_\_u=1000000000&\_\_c=1000000000&ideaRequestType=KEYWORD\_IDEAS#search.none When you want to get keyword results (enter a keyword and press enter), google makes a POST request here: https://adwords.google.com/o/Targeting/g?\_\_u=1000000000&\_\_c=1000000000 The request headers are:

    Host adwords.google.com
    User-Agent Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.11) Gecko/20101012 Firefox/3.6.11
    Accept text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8
    Accept-Language en-us,en;q=0.5
    Accept-Encoding gzip,deflate
    Accept-Charset ISO-8859-1,utf-8;q=0.7,*;q=0.7
    Keep-Alive 115
    Connection keep-alive
    Content-Type text/x-gwt-rpc; charset=utf-8
    X-GWT-Permutation BB8DF70B3A151B0F88DA836D4D8117AD
    X-GWT-Module-Base https://adwords.google.com/o/Targeting/
    Referer https://adwords.google.com/o/Targeting/Explorer?\_\_u=1000000000&\_\_c=1000000000&ideaRequestType=KEYWORD\_IDEAS
    Content-Length 1401
    Cookie PREF=ID=be4a951075eeeb11:U=58b39e637fa5af6e:TM=1278871506:LM=1278876883:S=-9tdR3vSj5IZPe5e; NID=36=j_lqfxFokemN-
    ,.,,,,,,,__utmc=229779660
    Pragma no-cache
    Cache-Control no-cache

    Now I don't understand what X-GWT-Permutation is (anx all the other x-gwt). I know it's google web toolkit ... but how the hell can I make a "call"to this website from c# .net (using httprequest) ? The post content sent is:

    6|1|69|https://adwords.google.com/o/Targeting/|807E86DA5783D73090609BC8C75E16F6|\_|invoke|3|147|18o|142|143|g|TiAction (Search.SearchInput.KEYWORD_IDEAS.RelatedToKeywordSearchParameter)|stQmQu4bHA07VgYuJlYqcKD9eRU:1287707728771|18i|14o|14a|14c|c|h|i|161|18g|ADVANCED_OPTIONS|CountryTargetSearchParameter|TiImpression|ParameterInQuery|LanguageTargetSearchParameter|DeviceTypeSearchParameter|yi|y8|178|s8|en_US|t4|zh|yr|16z|ys|IDEA_IN_ADGROUP|NEGATIVE_KEYWORDS|KEYWORD|COMPETITION|GLOBAL_MONTHLY_SEARCHES|AVERAGE_TARGETED_MONTHLY_SEARCHES|TARGETED_MONTHLY_SEARCHES|IDEA_TYPE|AD_SHARE|EXTRACTED_FROM_WEBPAGE|SEARCH_SHARE|KEYWORD_CATEGORY|NGRAM_GROUP|10b|175|b5|zw|18p|115|United

    C# csharp html com agentic-ai debugging

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Just a quick thought. The easiest way for this to work would be to "overwrite" the SystemColors . If it's possible to change the unfocused selection color form gray to blue, all my issues would have been solved...

    C# help question

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Hi, I don't think you understand exactly what I want. I simply want to view the selection in blue always (with multiple items), even if the listview has no focus. In a normal case, when the listivew loses focus, the selection turns gray, and you can't see it good.

    C# help question

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Hello, Thanks for the suggestion, I was trying to avoid this...

    C# help question

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Hello, I tried something like you said, before posting on this forum, but I don't think it's going to work. Now the problem is when selecting multiple items (by dragging). It can work only with 1 item, but if you have multiple items, and remove one item at a time from the SelectedIndices, it will call the event again and again. Don't know exactly how to explain. Thanks anyways

    C# help question

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Hello, I know this is possible because I seen it in action somewhere. I do not want to use owner draw, because I would have to implement tons of things, and I still want the list to look exactly like in windows (with the theme from windows). Still waiting for some suggestions. Thanks!

    C# help question

  • Change (or disable) selection color of listview [SOLVED partially]
    S sodevrom

    Hello guys, First, I don't want to use OwnerDraw, that is a condition I have :( . What I want is set a custom color to the selection of a listview. I want the color to be visible even if the listview is not focused. I know about the HideSelection member, but that's not what I need. I tried to overrwrite the onselectionindexchanged, and make the item.selected=false, and after that, set a custom back/fore color. This does not work because I have multiple items, and it deselects all items but one. I need one of 2 things: a)Keep selection visible (with blue color, not gray, this is the problem with HideSelection) always b)Remember selected objects, but do not show the selection at all (because if the selection is visible, than the custom back/fore color are not visible), so I can "mimic" the selection by setting a custom back/fore color to the items. Now I have been spending over 4 hours now on this stupid issue, and no luck. Anyone has a suggestion? It would help a lot. *******************solution Instead of setting the color in the on selected changed event, we can do it on mouse up. It's not perfect, but it's the best I got. The best way to do this is using a custom draw listview. Here is the code:

    List selections=new List();

    protected override void OnMouseUp(MouseEventArgs e)
    {
    selections = this.SelectedIndices.Cast().ToList(); //store selection
    this.SelectedIndices.Clear(); //clear selection

            for (int i = 0; i < this.Items.Count; i++)
            {
                if (this.selections.Contains(i))
                    this.Items\[i\].BackColor = Color.Blue; //if selected, make it blue
                else
                    this.Items\[i\].BackColor = Color.White; //if not selected, make it white
            }
            base.OnMouseUp(e);
        }
    

    modified on Monday, August 2, 2010 9:01 PM

    C# help question

  • Extending a .Net Control. Implement new functionality in event
    S sodevrom

    Hello, I just wanted to add the reply and I see your message. Anyways, I think I found the best way to do this. What I did is included this after my code (to change the color): base.OnEnabledChanged(e); So I call the "default" method from the main class. The idea came to me when you wrote base ... I don't use the base keyword to much. What do you think? It works 100%, and it's the "fastest" way to implement it. Do you think it's "safe" ? Thanks for the help! Vlad

    C# help csharp

  • Extending a .Net Control. Implement new functionality in event
    S sodevrom

    Hello, First, your code could easily be written as:

    foreach(Control c in this.Controls)
    {
    c.Enabled = this.Enabled;
    }
    base.Refresh();

    *this is just a note :) Now the problem is that it still does not work :( I tried it with this.Refresh() also but still no luck...

    C# help csharp

  • Extending a .Net Control. Implement new functionality in event
    S sodevrom

    Hello, Thanks for the suggestion but I already tried it in the past but it did not work. I used this:

    for (int i = 0; i < this.Controls.Count; i++)
    {
    this.Controls[i].Enabled = this.Enabled;
    }

    The controls are getting activated, but they are not clickable. Can you give it a shot? Vlad

    C# help csharp

  • Extending a .Net Control. Implement new functionality in event
    S sodevrom

    Hello, I want to create some custom groupboxes. What I did is created a new class called MyGroupBox that is derived from System.Windows.Forms.GroupBox . Everything is going great but I have a problem. I want to overwrite the default OnEnabledChanged event and add a new feature. What I did is this:

    protected override void OnEnabledChanged(EventArgs e)
    {
    if (this.Enabled)
    {
    this.ColorScheme = EnmColorScheme.Purple;
    }
    else
    {
    this.ColorScheme = EnmColorScheme.Green;
    }
    }

    Now what this will do is change the color of a disaled groupbox. The problem is that if I do this, the default functionality dissapers. When disabling a groupbox, all controls from the groupbox should be disabled. If I override the event, than his does not happen. What can I do to make the event behave like in the past, but also hadd my functionality (to add colors). I don't wan to implement this in every object that I created, that's why I am doing it in the main class "MyGroupBox". Any help is greatly appreciated. Thanks! Vlad

    C# help csharp

  • Time event? Real time data send
    S sodevrom

    I really tried, believe me, but I have no ideas how to do it. SImply no ideas. If I had ideas, I wouldn't have posted here :)

    C# help tutorial question

  • Time event? Real time data send
    S sodevrom

    Hello, Thanks for the reply. I don't want to be rude, but it does not help to much. 1. It's sorted chronologically 2. I am already using multimedia timer, and I don't need 1000000 millisecond precission. The time is like : hh:mm:ss,mmm (first 3 digits from milliseconds). 3. This is what I don't know how to do. As I said, I tried in a while(true) loop, and it worked perfectly, but that's not efficient. That's why I was thinking of a custom event. The windows forms timer is similar to what I want, but it's not good. The windows forms timer receives an interval and you call start. Instead of this, I would need something like SetFinalTime(time,WhatToDo). When time equals the system time, than execute the function WhatToDo . That would be my idea, but I don't know how to implement it. Believe me,I did my reading :) 4. They are close, yes, but I will figure that out on the way. First I need point 3 solved ... the event (or any other suggestion). Thanks! Vlad

    C# help tutorial question

  • Time event? Real time data send
    S sodevrom

    Hello, I have a project for school and I need it finished a in a few days. What the project does is reads data from a txt file. Each row of the txt file contains a timestamp hh:mm:ss,mmm (example: 00:05:33,141). Whenever the system time is equal to one of the records, I need to send data to a tcp client. What I did is created a thread with a while(true) in it and verified if a row contains the current time, than send the data. That is not good because it's not efficient. I would need something like a timestamp event (not using Timer). Any suggestions/code samples? I would appreciate some help here a lot. Unfortunately I am not good with writing custom events :( So for example I would need an event that will occur on a given time. Example: event(double time,DoThis) . If time is equal to timestamp, than execute function DoThis. In this way I would avoid a while(true) that will eat all processor. Also, System.Threading.Seep is not an alternative because I need this to be precise. Can someone help? Thanks!

    C# help tutorial question

  • Problem with Display Scheme (Windows font size)
    S sodevrom

    Hello, I already tried this but with no luck. I know I have to use it before the InitizializeComponent call and it's simply not working. I am making tests with Larger FOnt size in Windows 7, and both text and controls are larger. I want them to stay the same like on normal Font size scheme . Any other suggestions? Thanks

    C# help question

  • Problem with Display Scheme (Windows font size)
    S sodevrom

    Hello, I made my app for a fixed dimension, and when a person changes the Font Size (Display Scheme) from windows to Large (125% size or 150% size ...) all the text from my app is not visible anymor (because the text is to large) and also, the picture boxes are larger than the images (making the image tile over the picturebox). How can I make it so even if the Display Scheme is 150% size, my app will be visible like it is 100% size (normal size) ? I really hope someone can help. I searched all over the place but I didn't manage o find anything useful ... Thanks

    C# help question

  • Patch file (Create new file from previous file + changes)
    S sodevrom

    Hello, I already know about VNCSharp, but my problem is that I don't know how to write the server for it. That's only the client :( Any suggestions? If somebody can tell me how to "patch" the files or how can I start to write the VNC server ? Hope someone can help. Thanks

    C# csharp visual-studio sysadmin help question
  • Login

  • Don't have an account? Register

  • Login or register to search.
  • First post
    Last post
0
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups