Solved

C# Winform errors

Posted on 2014-04-08
2
298 Views
Last Modified: 2014-04-22
An object reference is required for the nonstatic field, method, or  property 'Script.CustShipForm'


An object reference is required for the nonstatic field, method, or property 'Script.csm'

Please advise a fix to the above errors with 'Script'.
0
Comment
Question by:thuhue
2 Comments
 
LVL 74

Assisted Solution

by:käµfm³d 👽
käµfm³d   👽 earned 250 total points
Comment Utility
Please show the line that is in error.

More than likely, you are trying to call a method using the class name instead of an instance variable name.
0
 
LVL 29

Accepted Solution

by:
anarki_jimbel earned 250 total points
Comment Utility
Yes, it would be interesting to see code.

Usually one can see this error when calling a non static property or method  from a static method.
In this case it's necessary to either make the called property/method static, or make a calling method non-static and create an instance of a class.
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

Recently while returning home from work my wife (another .NET developer) was murmuring something. On further poking she said that she has been assigned a task where she has to serialize and deserialize objects and she is afraid of serialization. Wha…
Today I had a very interesting conundrum that had to get solved quickly. Needless to say, it wasn't resolved quickly because when we needed it we were very rushed, but as soon as the conference call was over and I took a step back I saw the correct …
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now