Hot Solutions

Tags:WPF, Entity Framework, code first, DbContext, MVVM, c#

Can anybody direct me to a really simple example of how i can set up a DbContext using EntityFramework 4.2/4.3 and code first, such that I can bind a WPF control to the data using the MVVM pattern and have the control update when new entities are...

Tags:Visual studio, Microsoft

My question is how to get my system to a state to reinstall VS 2010 .
Recently I installed the beta version of VS 11 along side VS 2010 and SQl server 2012(yes i had 2012 sql server running and working prior to installation of VS 11) after using...

Tags:sencha touch, WCF, REST

I'm building an application using sencha touch 1.1 in the client side and WCF REST services in the server side. I'm facing some problems when the sencha sore syncs data, the parameter sent to update method is always null. This is the c#...

Hi Experts,

I have a web application build in VS 2010.

One web pages has a combobox filled with vessel names and a Subgurim google maps control. After the check boxes of vessels are toggled an event fires a server side function which plots...

I'm looking for Online quiz tests for C#, ASP.NET, SQL.

Please do refer me some excellent sources that had helped you as earlier.

Thanks.

Tags:.net, Visual Studio, Visual Basic, C#, JSON, DataTable

Hello,

I am using Visual Studio 2010, Visual C#, .NET framework 4.0.

I have app in IIS. All my methods looks something like this:


        [OperationContract]
        [WebGet(ResponseFormat = WebMessageFormat.Json)]
        public...

Tags:VBA, VB.Net, Excel 2007/10

Hello Experts,

I have color information taken from VB.Net ColorDialog and saved in  SQL table as ARGB integer values.

For example:
Black = -16777216
White = -1
Red = -65536
Blue= -16776961

In VB.Net application, I can apply color as...

Tags:Crystal Reports, ASP.Net, VB.Net

I am trying to create a static report in my ASP.Net website. The purpose of this report is to receive data from a page's controls and then convert to PDF and present it to the user for printing/saving.
I have never before worked with crystal...

Hi,

Is there a way i can associate javascript key events (like keypress/keydown) to a Filter Input TextBox in RadGrid.??

I want to avoid Users from entering certain special chars using "keyboard or Copy paste " into the Filter input text...

Hi,

I hope that someone is able to help. I have created a simple application that opens a crystal report using the crystal report viewer. The environment is windows server 2003 x64 bit.

I receive the following error below:

See the end of...

Tags:C# XML Linq

How do I get the employee list from below XML

<?xml version="1.0" encoding="utf-8"?>
<Employee>
  <Some_XML_1 />
  <Some_XML_2 />
  <EmployeeList>
    <id>1</id>
    <name>abc</name>
  </EmployeeList>
  <EmployeeList>
    <id>2</id>
...

In my Controller Action, I added a FormCollection as an input param. And inside the Controller Action I am able to expand the "AllKeys" list of strings and see each field submitted.

BUT, I can not find the values entered by the user. I know...

Tags:C#, asp.net, FindControl

My code compiles.
However the referenced control is null.

Button MyControl = (Button)this.FindControl("cmdC1Clip");
MyControl.BorderColor = System.Drawing.Color.Red;

BorderColor property cannot be set because MyControl is null.
...

Tags:windows phone, selectionchanged

When I 'hard code' the ListItems inside the ListBox I am able to access the Tag property during a SelectionChanged. But when I bind the ListBox.ItemSource I am unable to access the Tag Property.

First, I do this:
 
 

Then, I try this:
 ...

Tags:sql, TFS, visual studio 2010

Hi,

do you know if TFS 2010 work against SQL SERVER 2012?

Thanks,

Tags:web, service, .net, c#, wpf, slow response

Hi all,

I am having an issue with connecting to a remote web service from a .NET application built using WPF. We can connect successfully and we receive the required information back, however it takes a long time, approx 30-60 seconds to get...

Tags:JScript runtime error, MVC 3

I'm working on a new website using ASP.NET MVC 3 and JQuery. I actually started with the HTML 5 Mobile ready website template that's available on NuGet.

I trying to use JQuery.sparkliine.js library to do some charting. When I run it in Visual...

I have been told that I can use the free dll itextsharp to convert an excel workbook to pdf.  Does anyone know where I can see a sample to do this?  I don't want to have to build the pdf on the fly by reading the xlsx file and doing a lot of...

We currently are using Excel to create line graphs of data.  We want to be able to have the data points on the graph to have optional labels.  In our case if the datapoint has an exceptional circumstance we want to have put a note in a columnn...

Tags:Inno, InnoSetup, installation, .net, c#, registry

Hi,

I have one .Net desktop application (app1) and one third party visualization application(app2).
app1 loads app2 using registry information of where app2's exe is.
If app2 is not running before app1 calls app2's function, app1 crashes.
...

Tags:DLL, CreateObject, Visual Studio, .NET

Through Guru.com, I had a developer create a DLL for me to include in a Visual Studio Windows Service project.  To test out his DLL, this developer included an EXE that would register the DLL on the system and he included the following code...

Tags:visual studio, vb.net, stdcall, __stdcall

I have been asked to write a DLL that exports functions through __stdcall.  I'd really like to do this using Visual Basic.NET (2010 currently) as that is my preferred programming environment.

I've spent quite a long time searching for samples...

I received the error in the title.  Can someone help me troubleshoot?

The server was unable to process the request due to an internal error.  For more information about the error, either turn on IncludeExceptionDetailInFaults (either from...

Tags:asp.net, .net 1.1, microsoft visual studio, IIS 7

Hello experts,
I recently got a new computer that is now running windows 7 and IIS 7.  All my asp.net 1.1 web applications ran fine with IIS 6.0, but now i get this error when i try to browse any of my webpages.  

HTTP Error 404.17 - Not...

Tags:datetimepicker

I'm trying to include the Microsoft datetimepicker control into a Visual FoxPro form.
I need to be able to include a checkbox into the control, for those occasions when there won't be a date.

I can get the ActiveX control onto the form.
...

I installed Crytal XI R2 to use with .Net 2005.  How do I expose the AxCrystalActivexReportViewer Control in the toolbox?  The viewer that is currently exposed is CrystalDecisions.Windows.Forms.CrystalReportViewer version 11.5.3700.0.

Tags:SQL Server, unicode

I have a SQL Server database (2000-2008) that is used as a back-end to a VB.Net 2005 Windows application. It currently uses varchar and text data types that will need converted to unicode. I understand the nvarchar and ntext part of this...

Tags:Crystal Reports

I am having a problem using an apostrophe within a totext.

ToText({Command.FirstDayOfWeek}, "MMMM 'yy")

I am getting the following error; "Bad date-time format string. Details: errorKind Error in File RunningReport...

Tags:Sql server 2008R2, stored Proc, variables, select

I am trying to set a variable in my stored procedure to a RND number and I keep getting errors whnever I check it.  When i run the statements outside a stored proc, everything returns correctly.  Something is wrong in my text somewhere.

Here...

Tags:visual studio 2010, crystal report

Hi,

I am using visual studio 2010, and i needed crystal reports so i installed crystal reports from the SAP link and below is the link that i used to install.

SAP Crystal Reports Link

And I installed,
SAP Crystal Reports, version for...

Tags:ASP.NET, MVC 3, C#

I have the following in my model.

[DisplayFormat(DataFormatString = "{0.0}")]
public double Rating { get; set; }

I have the following in my view
@Html.DisplayFor(modelItem => item.Rating)

This is not working for me. I get an error on...

Tags:WPF, BitmapImage

Using DecodePixelHeight, I can change the size of the image.

But I only want to limit the height of the image to a certain value.
e.g.
The maximum height I want to insert is 48 pixels.
If an inserted image has a resolution of 64x64, then...

I am migrating my Visual Studio dev environment to a new PC and getting an error when building a solution:

Could not load file or assembly <file> or one of its dependencies

The dll is there, in a right path. I don't see any warnings about...

Hi,
         I  have to implement cryptography in two technologies(php & dotnet).I followed the
below link

http://sanity-free.org/131/triple_des_between_php_and_csharp.html

i have to encrypt by php and decrypt by c# reversal too.

Now...

Tags:.NET, Turbo Tax

Windows XP SP3 Running in a VMware Player virtual machine on Ubuntu 10.04.

Several versions of .NET installed: (according to Add or Remove Programs)
2.0 Service Pack 2
3.0 Service Pack 2
3.5 SP1
4 Client Profile
4 Extended

Problem...

Tags:C#, .net, linq, lambda expression

Hello experts,
I have a string like
string str = "A=1&B=2&C=5=6&D=7=8&E=9";

Dictionary<string, string> dict = str.Split('&').Select(x => x.Split('=')).ToDictionary(x => x(0), x => x(1));
using above Linq I get the output as

A = 1
B = 2...

Hi

I am using asp.net ajax asynchronous file upload inside the tab container. The code is

 

when I upload the file I am getting this error - "htmlfile: Can't move focus to the control because it is invisible, not enabled, or of a type...

Tags:vb.net, visual studio net 2008, .net

Hello experts,
I am using visual studio 2008, to print out a label.  I am replacing a spread sheet that is currently printing the label.  The problem is, in the print properties of the spread sheet, it is set to center on page horizontally.  How...

Hi ,

I need to create a function in VB.net that emulate 100% the  old VB6 "Val" function.

I have a project in VB.net that use more then 100/200 calls to this function.

I need to remove all the old vb6 functions calls.

I have created...

Tags:CAML, SPQuery, SahrePoint 2007

Hi, I am writing a code to retrieving files from SharePoint library based on properties value using CAML query, below is the code:...

Tags:aspx, iis, iis7

IIS 7 redirects all aspx pages to include unwanted characters.

This:
http://example.com/hello.aspx

Is redirected to a URL like this:
http://example.com/(S(ugjb5sjiramvqm453xdtrtr2))/hello.aspx

How can I prevent this?  Search engines...

I am trying to encrypt a web.config file using the following command i am getting the error like below:

aspnet_regiis.exe -pef "connection
Strings" "D:\Password Encryption\DPAPITestWeb\DPAPITestWeb\" prov "DataProtection...

1. I am extracting a zip file in a folder. I want to read all the extracted file names from that folder in a script task (string[] file_names = Directory.GetFiles(@"c:\MyDir\", "*.pdf");)).
2. Now, I want to write the array file_names in an...

Tags:vb.net aspx

I am programming in Visual Studio 2008 using vb.net.

I have a web program that contains pages with many fields.  I have the following code that converts enter to tab, but only works in i.e.  This app must also work in Mozilla Firefox and...

Tags:VB.Net, ASP.Net, IIS

We have a .Net web application. Due to many reasons, I created a Public Class in App_Code folder. It has, among others:
 
Apparently, everything worked fine. A couple pages set this value, which can then be accessed in another couple pages. But...

Hello,

I am using the following regular expression to validate email addresses.

<asp:regularexpressionvalidator id="REEmail" runat="server" ControlToValidate="txtEmail" Display="Dynamic"...

Tags:VB.NET, FindWindowEx

So I have spent some time researching FindWindow and the link and I have a slight problem. When I attempt to reference an object I am hitting the first one. The code I am using is:

 

I need to find the specific instance of an incData. I...

Tags:VB.NET

On login to my website, I create a session variable. I'm trying to find out if there's a way to remove that session variable if the user leaves the web site (ie they close that browser tab or just type in a different url).

After doing some...

Hi,

I have written a simple .NET c# application that downloads the source code of a HTML web page and reads the stream line by line.

The HTML contains many links like this:
 

I need to extract the link address (eg:...

Does the {} syntax denote bind variables ?

_queryString = String.Format("select * from table m " +
                               "WHERE m.col IN " +
                                    "('{0}',  '{1}' )"  +
                                ...

Tags:Visual Studio 2010, C#, SQL Server 2010

OK, so I'm pretty new to C# development, and I have an issue that I am just not understanding.

I have a SQL Server 2005 compatible DB with a series of tables. The ones that matter are the Users, Compatibility, and Suppliers tables. There is...

This is my code.I am first generating textbox and dropdownlist as per my requriement by looping though dictonary.. and binding the datalist like this.


   DataView dv = new DataView(tempDataTable);
                   ...

Tags:file, pointer, input, output, data file

I'm writing a few sample C programs from my class book. This particular one is on page 175, from the book entitled "C Programming for Scientists and Engineers". I've already created the two files and put them in the same directory as the...

Tags:C#, .Net

Hey,

I have a single DLL ("Debug.dll"). What i want from this is for ANY of my applications to be able to reference that DLL and call the WriteLine() function but that output to be outputed to the same stream.

Can you make some kind of...

OK I would like CTRL-A (on keyboard) to select all the text in my textBox1. Right now CTRL-A does nothing, even though my cursor is in the textBox1.

Tags:WCF, Rest, C#, VB.NET

Hello,

I am working on a simple WCF Rest Service, that will be used by iPhone to upload images to a database.

The problem I am getting is with the Stream parameter when I run the service in visual studio, which opens up a web page,...

Tags:Regular Expressions, C#

I have an Office Smart Tag that uses a regular expression to match phone numbers that are in North American format. I have a user in Germany that would like me to update the smart tag to recognize German phone numbers.

The user has given me...

Tags:.Net 4.0; Visual Studio 2010;

I'm trying to convert my project from .Net 3.5 to .Net 4.0;  My project built just fine in .Net 3.5.  But after converting to .Net 4.0, I get the following compile error:

The type or namespace name 'DataSetExtensions' does not exist in the...

Tags:windows c# printer status

I know that there has been much written about how to access a printer's current status/error state via WMI. Having written the code to do this I've seen the limitation of it myself (i.e. getting 'unknown' states when I can see the printer is...

Tags:c#

what is the best way to insert data into an xml document already exists ?

Tags:.Net, DB2, C#

Hi,

We have a executedataset method where we pass store procedure name, store proc input parameters as dbparams

Executedataset(storeprocedure name, dbparam).

But while trying to execute the store procedure which has a dynamic query in...

Tags:ASP.NET, VB.NET, VS2010

Any examples or suggestions on how to access/display the client side web cam on a aspx page using vb.net and click a button to save the image would be helpful.

What are the scenarios in which a project should preferably be made in Java as opposed to .Net?
In other words are there any limitations in .Net in terms of performance, Functionality, etc that is not an issue in Java?

This SQL which has been in place for over 8 months when run on MySQL throughthe MySQL ODBC driver under .net is sometimes taking up to 36 seconds to return the result and as a result my .net application is timing out.  I know that is the...

Tags:Crystal Report VB.Net

I'm having a problem with regards to Crystal Reports in VB 2010. I am developing a Windows Application and I want to display in crystal report a result from my sql query without the need of connecting it to database through Database Expert --- I...

Tags:.NET, Reporting, Microsoft Report Viewer

I am just starting to use the Microsoft Report Viewer and Im having a little issue that hopefully someone can help with. When I pull up a page with a report viewer on it the report viewer spans the width of the page that it is configured to but...

Hello,

I am using the code below to load my combobox. How do I modify it for the combobox to only display the first four rows?

  Dim CCF As New DataSet
            CCF.ReadXml(Server.MapPath("~/App_Data/CCF.xml"))
           ...

Tags:Windows Forms

Hi there,

I have been searching high and low for a solution to what seems like a standard layout for a navigation pane. I have managed to obtain outlook 'accordion' style navigation panes from around the net.

The one I am currently using...

What is connection string for Oracle RDBMS? Should I  continue to use ADO.NET?

Background: My C#.NET application is using ADO.NET (SQLConnection, SqlCommand, SqlDataReader classes) to select data from Microsoft SQL Server database tables. The...

Tags:Silverlight

I am using Silverlight 4 and SharePoint and want to fill an ObservableCollection from a returned dataset from SharePoint. I have the query and connection to SharePoint done. In my example my List is called _getList and my ListCollectionItems is...

Tags:Crystal Report

I declared a column in SQL table to varchar and the parameter in Crystal Report (asp) to Date.
Parameter1 is called DateFrom (Date)
Parameter 2 is called DateTo (Date)
I also created a formula in the Record:
...

Tags:asp.net, .net, vb.net, c#

Hello

This is driving me a bit nuts, I can't see any reason why this isn't working.

I'm trying to change the cssClass of a div inside a repeater control using the code below:

 

This is being done in the ItemDatabound Method and works...

I'm reading a text file and I want to look for specific sets of text between two distinct lines.
For this example, the first line will be the first instance that reads "Pressureandleaktests" and the last line will be the next read instance...

Tags:VBA; Windows API Call; Excel

Hello Experts,

I'm looking for a VBA code that would let me open any directory on the file system, loop through all the files that meet certain criteria (eg. *.doc) and then list some of their metadata in an Excel sheet. Something along the...

Tags:asp.net, c#, asp, .net, aspx

I am pretty new to formatting controls in aspx pages.  I am trying to create a page that displays a set of controls, one of which is a ListBox.  I would like the ListBox to fill the available width and height of the screen without scrolling from...

Hi I've tried several things and all of them are still giving me the time as well as the date.  I need a UK date only and tried:

string dateN = String.Format("{0:d/M/yyyy}", catchDate);

This STILL gives me time.  What do I need to do to...

Whats wrong in my following syntax ?

string javascript = "<script type='text/jscript'> " +
"$(document).ready(function () { " +
"$('" + "#" + this.ClientID + "').datepicker('" +
"'{ showOn: '" + "button" +"',buttonImage: '"
+...

Tags:ASP.NET, VB.NET, Membership

I'm trying to put an app on the web and I'm having some trouble with the login control.  Everytime I try to log in I get this error:  Your login attempt was not successful. Please try again.

I've gone through this entire site: ...

Tags:C#

Hi All,

I have a interface with a Siemens PBL.
The methods that is exposed to me to read from the PBL takes 7 parameters.
And I am not sure how to declare the parameters and types for the parameters.

Please have a look at the attached...

Tags:.net, C#, Silverlight, MVVM, MVC, VB

See below the following code snippet is not working as expected.  On a validation error the recource file does not appear to be recognized.  The solution is a Silverlight App using an mvvm pattern using ria services and entity framework.



...

Tags:NET WebClient Remoting HTTP McAfee Web Gateway

I have a .NET program that downloads files from a server using an HttpWebRequest object. In a particular client's network, once in a while the result of the download is not the file contents but an HTML page that contains this text:

 '... If...

Hi there, I would like to know how to click submit button on the HTML form in a webbrowser control.

HTML FORM:

 

PS: I have no access to the page, so I cannot change the source code, it has to work with the one above.

Thanks

Tags:ASP.NET, MVC 3, C#

Hi,

Disclaimer: I'm new to ASP.net MVC

I'm currently trying to convert a few websites from Web Forms over to the MVC 3 design.  I having some trouble trying to figure out where I should stick my layout (master page) logic.

I have a...

Hi there,

How to bind data to combobox?

Thanks!!!

Do the "Login" controls in the Visual Studio Toolbox provide both client-side and server-side validation, or do they just provide server-side validation.

In other words, do I have to add my own client-side validation?

Tags:ajax, slideshow extender, asp.net

Hello I added a slideshow in my aspx.net site.
Following this example.

http://www.dotnetcurry.com/ShowArticle.aspx?ID=287
and I have some issues that I need to solve and some  questions
I would like to ask if I need to make it with a...

Tags:C#, .NET

In a console app, I am prompting a user to enter a number between 1 and 3.

I can verify that the user is entering an integer with the following code:

 

How can I ALSO verify that they are entering a number between 1 and 3, preferably in...

Tags:HWID

How to read the hardware id (motherboard) in vb.net?

I have users who change their Start+ControlPanel+Display+Settings - from
1024x768 -to- 1280x1024 -to- 1680x1050 etc, etc, etc ... Why? Don't ask, it's a long story with a lot of screaming and pounding of fists on table tops (smile).

I have a...

I'm starting a development project and would like to know:  How to name my variables, data fields, modules, etc.

What are the most sensible ways to name objects, etc.

Surely someone has a clear answer.

Hi ,

I need a way to swap 2 cells on datagridview with drag and drop.

The problem is the drag and drop work only beween 2 objects and I have only one object.

Is possible do it ?

Thank you !

Tags:VS 2008 C# eMail Sample

I am trying to finish a program by adding the emailing attachments when the program finishes. I have taken the code below from the Microsoft sample code site.

----- if (answer.StartsWith("c") && mailSent == false) ---- On this line I am...

Tags:ASP.Net, .Net, C#, ASP

I need to store information across multiple pages and I was wondering what the difference is between "Viewstate" and "Session" in ASP.Net?

When is it preferable to use one or the other, and what are their similarities?

Also, what type of...

Hello,

i new to c# and programming i have to create something like this:



users user01  = new users("bob", "Piet");   //if no date given it should be set to 2012
users user02  = new users("Roels", "Lut",2003);
users user03  = new...

Tags:Microsoft Windows 2008

Where can download Wercon for Windows 2008?

What is this? Utility that should be downloaded? Or maybe Windows feature or component?

Tags:C# -- datagridview filter / search ?

Does anyone have examples on how
to something like the following ?
 1. user does search
 2. below displays
 3. user clicks "CTRL + F" (or something)
 4. user enters "travels" and clicks "Enter"
 5. system automatically highlights all lines...

I've to append a row to a file every time a scanner read a barcode. I'm thinking to use a StreamWriter object with append option set to True. The rows appended are modified by another application (called AppA). I'm confused about this:...

Tags:Visual Basic, .Net, browser automation

I'm getting an 'Object reference not set to an instance of an object' error that I can't interpret.  Here's the code:

 

I'm getting the error on the 'theElementCollection = WebBrowser1.Document.GetElementsByTagName("select")' statement. ...

Tags:XmLWriter, Serialization

Hello everybody, im trying to serialize a class and everything works as expected, however, the empty string properties are being serialized like this:

<Element />

and i need it to be like this:

<Element></Element>

I saw that using the...

Tags:WM 6.5, SQL CE, .NET Compact Framework

It´s possible to connect my htc hd2 with WM6.5 with USB cable and use my computer network connection to send and receive data to and from my SQL Server database instead of Wi-Fi of the device ?

Loading Advertisement...

Top .NET Programming Experts

  1. CodeCruiser

    588,856

    Sage

    6,000 points yesterday

    Profile
    Rank: Genius
  2. kaufmed

    377,702

    Wizard

    10 points yesterday

    Profile
    Rank: Genius
  3. BuggyCoder

    268,007

    Guru

    1,600 points yesterday

    Profile
    Rank: Sage
  4. TheLearnedOne

    232,552

    Guru

    4,900 points yesterday

    Profile
    Rank: Savant
  5. Idle_Mind

    193,005

    Guru

    0 points yesterday

    Profile
    Rank: Savant
  6. JamesBurger

    156,812

    Guru

    2,000 points yesterday

    Profile
    Rank: Sage
  7. wdosanjos

    124,308

    Master

    2,000 points yesterday

    Profile
    Rank: Genius
  8. Dhaest

    115,720

    Master

    0 points yesterday

    Profile
    Rank: Genius
  9. sedgwick

    112,918

    Master

    1,600 points yesterday

    Profile
    Rank: Genius
  10. nepaluz

    101,325

    Master

    0 points yesterday

    Profile
    Rank: Sage
  11. MlandaT

    95,921

    Master

    2,100 points yesterday

    Profile
    Rank: Genius
  12. navneethegde

    74,442

    Master

    0 points yesterday

    Profile
    Rank: Wizard
  13. Masteraco

    70,367

    Master

    0 points yesterday

    Profile
    Rank: Wizard
  14. binaryevo

    70,365

    Master

    0 points yesterday

    Profile
    Rank: Guru
  15. ambience

    69,104

    Master

    0 points yesterday

    Profile
    Rank: Sage
  16. emoreau

    68,230

    Master

    0 points yesterday

    Profile
    Rank: Genius
  17. PaulHews

    49,486

    0 points yesterday

    Profile
    Rank: Genius
  18. AndyAinscow

    45,290

    0 points yesterday

    Profile
    Rank: Genius
  19. Chinmay_Patel

    43,411

    0 points yesterday

    Profile
    Rank: Genius
  20. ged325

    41,700

    2,600 points yesterday

    Profile
    Rank: Genius
  21. RolandDeschain

    41,317

    0 points yesterday

    Profile
    Rank: Sage
  22. nishantcomp2512

    39,486

    0 points yesterday

    Profile
    Rank: Wizard
  23. tommyBoy

    36,550

    0 points yesterday

    Profile
    Rank: Genius
  24. mroonal

    35,000

    0 points yesterday

    Profile
    Rank: Sage
  25. santhimurthyd

    34,650

    0 points yesterday

    Profile
    Rank: Wizard

Hall Of Fame