.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Kaviya Balasubramanian
Imran Ghani
Post New Web Links

I changed the form1 location but when im trying to return it back to the FormStartPosition.CenterScr

Posted By:      Posted Date: September 24, 2010    Points: 0   Category :Windows Application
 

private void button7_Click(object sender, EventArgs e)
        {
            if (processUnfreez == null || processUnfreez.HasExited)
            {
                this.Location = new Point(1100, 0);
                processUnfreez = System.Diagnostics.Process.Start(Application.StartupPath + @"\UnFREEz.exe");
            }
            else
            {  
            }      
        }

This is the new location : this.Location = new Point(1100, 0);

And then inside the else{}

I tried to put


View Complete Post


More Related Resource Links

How to return back to a specific page in a gridview list?

  
Hello,  I have a gridview with paging. So for instance, I'm on say the page number 10, and I open the form details on a specific record_id (link). After I update/submit the form, it returns to page number 10. But, if I go to another page, for instance page 5, and submit the form, it returns to page 10. I've tried some things, for instance history.back(), but it returns to the first page I went to, in this case page number 10 (or whatever the first page I go to). Hopefully this code helps to understand what I'm asking: <asp:GridView DataKeyNames="Referral ID" ID="gvList" runat="server" CellPadding="4"     ForeColor="#333333" GridLines="None" OnRowCommand="gvList_RowCommand"     OnRowDataBound="gvList_RowDataBound" OnRowDeleted="gvList_RowDeleted"     OnRowDeleting="gvList_RowDeleting" AllowPaging="True" PageSize="20"     AutoGenerateColumns="False" OnPageIndexChanging="gvList_PageIndexChanging"    OnRowCreated="OnRowCreated" AllowSorting="True" OnSorting="OnSort"> protected void gvList_PageIndexChanging(object sender, GridViewPageEventArgs e)        {   &nb

How to return back back to code behind file after cascading dropdown calling

  
Hi, I have a cascading dropdown. After the dropdown is populated(it is in another file)  i would like to return back to the original form where the control is placed. is there anyway of doing it

how to back from form4 to form1 ?

  
hi

in my C# program i Moves from one screen to another like this:

    Form G = new Screen1();
    G.ShowDialog();
    G.Dispose();
    G.Close();

i move from screen1 -->  screen2  --> screen3  --> screen4

when i in **screen4**  and  i want to go back to **screen1** - if i'll write `this.close()`

i'll go only to **screen3**

how to go back from **screen4  to screen1**

thank's in advance

How do i get the location of Form1 Top Right corner?

  

I mean i want to set the Form1 new Location to be on the Top Right corner.

If 0,0 is the top left corner so whats the top right corner?

I tried:

this

 

 

 

 

 

 

How do i get the location of Form1 Top Right corner?

  

I mean i want to set the Form1 new Location to be on the Top Right corner.

If 0,0 is the top left corner so whats the top right corner?

I tried:

this

 

 

<span


danieli

User profile sync - Replication of manager, physical office location and work phone number back to a

  

SharePoint 2010 user profile synchronisation successfully up and running following the super guide from Harbar (thank you!).

Setup the property for first name to replicate back into active directory and this has worked perfectly.

Now trying to configure the following functionality and getting issues.

1] Allow the users to edit the manager property and replicate back into AD

2] Allow the users to change their phone number and replicate back to active directory

3] Allow the users to edit the office location using a drop down list.

So these are the problems

1] Allow the users to edit the manager property and replicate back into AD

Have made the property editable and the users can change it.  The org chart browser works using the new values.  The profile property, however, will not allow you to set is as 'user overridable' in central admin and it never goes back into AD.  Indeed there is a warning displayed in the users my site to this effect.

2] Allow the users to change their phone number and replicate back to active directory

Have made the property editable and the users can change it.  The profile property, however, will not allow you to set is as 'user overridable' in central admin and it never goes back into AD.  Indeed there is a warning displayed in the users my site to t

Jquery UI buttons style return back to windows default button

  

Hello

i have placed my 

    <link type="text/css" href="css/smoothness/jquery-ui-1.8.5.custom.css" rel="stylesheet" />
<script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="js/jquery-ui-1.8.5.custom.min.js"></script>


<link type="text/css" href="css/smoothness/jquery-ui-1.8.5.custom.css" rel="stylesheet" />
<script type="text/javascript" src="js/jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="js/jquery-ui-1.8.5.custom.min.js"></script>


under my template.master - master page.

so i make a new page based on my master page.&nb

Post back puzzle

  

Hi, I have a website where the user makes a selection from a combo box and it then fills a couple text boxes with text based upon the selection. I'm sure as you know it could take a second for the text to appear in the text box due to the post back. I know there is no way to make it instantanious, so what I would like to do it fill the text box with somthing like "Loading Info..." so the user does not type in it while the information is loading.

If you would like to see what I mean please go to this page: www.epiclinks.com/create.aspx and mess around with the combo boxes and You'll see what I mean.

What I would like to do is have it do a post back to write "Loading Info..." and then do another post back to fill it in based upon their selection. How would I do this?

I'm up for anything, so if you have a better solution than that please let me know.

Thanks.


ListView DataPager with SQL-Statements that already return only paged data.

  

Hi,

As far as I understand the ListView-Control and the DataPager-Control, they work like this: The ListView gets its datarows from its data source, then the DataPager causes the ListView to display only a subset of those rows.

So what, when I want to use custom databinding for the ListView, that *already* gets the certain subset from SQL-Server (for better performance). Can I and how can I use the DataPager then?

Thanx, S.


Need Syntax To Make Results of LINQ Union Return Non-Generic Type

  

Hi.

I have the below SQL which works just fine:

SELECT     Message, CreateDate, AccountId, AlertTypeId
FROM       dbo.Alerts
UNION
SELECT     TOP (100) PERCENT Status, CreateDate, AccountId,
                          (SELECT     10 AS Expr1) AS AlertTypeId
FROM         dbo.StatusUpdates
WHERE AccountId = PassedInParameter
ORDER BY CreateDate DESC

I have been going about trying to convert the above into a LINQ method and am having problems with return types.
As the above SQL illustrates, I am querying two distinct LINQ tables - Alerts and StatusUpdates -
and then attempting to perform a Union on them. In order to do the union in LINQ, I have to have agreeing types. So, I
am using "var" to make the results of "alerts" and "updates" generic before the union.  

public IList GetStatusUpdatesAsAlertsByAccountId<T>(Int32 accountId)
        {
            using (WorkbookDataContext dc = _conn.GetCont

XMLHTTP.ResponseText return unexecuted code?

  

I have a simple asp with the following code.  When I access this page directly (via browser) everything works fine:  the xml object shows up fine.  When I call this page via VBA (excel), the ResponseText method of the 

XMLHTTP object returns the below code unexecuted.  Anybody knows what's going on?  thanks.





<%@ Page Language="VB" AutoEventWireup="false" CodeFile="Default.aspx.vb" Inherits="_Default" %> <% Response.Buffer = True Response.ContentType = "text/xml" Dim oDataXML As Object 'Custom Data XML passed in by caller. On Error Resume Next 'Load the XML passed into the request. oDataXML = Server.CreateObject("Microsoft.XMLDOM") oDataXML.Load(Request) Dim sResult As String sResult = "<?xml version=""1.0""?>" sResult = sResult & "<OrderProcessed>" sResult = sResult & "<Status>test</Status>" sResult = sResult & "<OrderID>111</OrderID>" sResult = sResult & "</OrderProcessed>" Response.Write(sResult) Response.End() %>



Posting data to ASMX and return Object for jQuery

  

I am using fluent NHibernate with WebForms and I am trying to build a page where I allow a user to post a status update on their profile page and I a using a .asmx WebService to post the data to the database and then returnig a StatusUpdate instance to the page to be used by jQuery. I have a couple problems.

1) First off when I return a string from the WebService(i was testing) the textbox where the user enters their status doesnt empty the contents. And since the page doesnt refresh even if I manally clear out the textbox and put in something else, it still posts the previous status to the database again. How do I fix this?

2) Secondly, when I return the StatusUpdate Object from the Webservice I cant the results to display anything. Like I sad, Im using jQuery to make an AJX call to the WebService.

Here is my code:

User Profile Page:

<p>
Status: <asp:Label ID="status" runat="server"></asp:Label><span style="font-size:.7em;"><asp:Label ID="statustime" runat="server"></asp:Label></span><br />
<textarea id="statusBox" rows="3" cols="40"></textarea><br />
<input type="button" value="Update Status" onclick="SetStatus(); return false;

Security negotiation failed because the remote party did not send back a reply in a timely manner. T

  

 


Dear All i have created one simple service

like this

namespace WcfService2
{
        public class Service1 : IService1
    {
        public string ShowEmpName(string strFirstName, string strLastName)
        {
            return strFirstName + strLastName;
        }
    }
}




after executing in .net command promt i got 2 files

service.cs & output.config


after that i create one class file like this


namespace WcfService2
{
    public class clientcs
    {

        static void Main(string[] args)
        {
            Service1Client client = new Service1Client();
            string strResult = client.ShowEmpName("Pradeep", "Deokar");

Code Cleanup: 9 Useful Tactics for Paying Back Technical Debt

  

Now that you've identified technical debt in your code base, let's turn our attention to some specific tactics that will help you pay back that debt.

David Laribee

MSDN Magazine January 2010


Code Cleanup: Using Agile Techniques to Pay Back Technical Debt

  

Every codebase contains some measure of technical debt - code that is maddeningly hard to test and maintain. We outline some ideas for identifying and dealing with the high-interest debt in your code.

David Laribee

MSDN Magazine December 2009


Windows Mobile: Use GPS And Web Maps For Location-Aware Apps

  

We show you how to build a location-aware task list application for Windows Mobile devices that uses GPS to remind you of a task when and where it's appropriate.

Christopher Mitchell

MSDN Magazine January 2009


Editor's Note: A Look Back As We Move Forward

  

Here's a look at a year's worth of coverage and changes at MSDN Magazine in response to reader requests.

Howard Dierking

MSDN Magazine January 2009


Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend