| View previous topic :: View next topic |
| Author |
Message |
Cryoma Member of the Year
Reputation: 198
Joined: 14 Jan 2009 Posts: 1819
|
Posted: Sun Dec 25, 2011 2:09 am Post subject: C#, I need to learn it |
|
|
| halp
|
|
| Back to top |
|
 |
gogodr I post too much
Reputation: 125
Joined: 19 Dec 2006 Posts: 2041
|
Posted: Sun Dec 25, 2011 2:17 am Post subject: |
|
|
| I can help you, what do you need to do?
|
|
| Back to top |
|
 |
Cryoma Member of the Year
Reputation: 198
Joined: 14 Jan 2009 Posts: 1819
|
Posted: Sun Dec 25, 2011 2:29 am Post subject: |
|
|
| I need one form that hides or shows form 2 which is entirely transparent but has an embedded swf AND that snaps to the coordinates of a window if it's open based on window name
|
|
| Back to top |
|
 |
gogodr I post too much
Reputation: 125
Joined: 19 Dec 2006 Posts: 2041
|
Posted: Sun Dec 25, 2011 2:38 am Post subject: |
|
|
on load of form 1 hide the form 2
to snap to the coodinates of a window you can use this
| Code: |
[StructLayout(LayoutKind.Sequential)]
struct RECT
{
public int left;
public int top;
public int right;
public int bottom;
}
[DllImport("user32.dll")]
public static extern IntPtr FindWindow(String sClassName, String sAppName);
[DllImport("user32.dll")]
static extern bool GetWindowRect(IntPtr hWnd, out RECT rect);
IntPtr Window = FindWindow(null, "Window Name");
RECT rect;
GetWindowRect(Window, out rect);
|
forms have subprograms inside their class Hide() and Show()
you can use
Form2.Hide();
or
Form2.Show();
|
|
| Back to top |
|
 |
Cryoma Member of the Year
Reputation: 198
Joined: 14 Jan 2009 Posts: 1819
|
Posted: Tue Dec 27, 2011 3:54 am Post subject: |
|
|
| Ok I have no idea where to put that code.
|
|
| Back to top |
|
 |
1929394839292057839194958 Grandmaster Cheater Supreme
Reputation: 130
Joined: 22 Dec 2006 Posts: 1509
|
Posted: Tue Dec 27, 2011 5:25 am Post subject: |
|
|
| Cryoma wrote: | | Ok I have no idea where to put that code. | Read a fucking tutorial or a book or something. You can't know like nothing of the language and just expect to do things instantly
|
|
| Back to top |
|
 |
Cryoma Member of the Year
Reputation: 198
Joined: 14 Jan 2009 Posts: 1819
|
Posted: Tue Dec 27, 2011 2:05 pm Post subject: |
|
|
| konr wrote: | | Cryoma wrote: | | Ok I have no idea where to put that code. | Read a fucking tutorial or a book or something. You can't know like nothing of the language and just expect to do things instantly |
Yes I can it's worked up to this point.
|
|
| Back to top |
|
 |
Cryoma Member of the Year
Reputation: 198
Joined: 14 Jan 2009 Posts: 1819
|
Posted: Tue Dec 27, 2011 2:51 pm Post subject: |
|
|
| Shrooms wrote: | give me something in return and I will do this for you.
Last time I fixed your puzzle bot under c#... |
Steam games.
:\ All I have.
|
|
| Back to top |
|
 |
|