|
sekhar.k wrote: I am inserting through looping the both the tables and adding values into third table.
That should work. But a better technique is to use a join in your SQL query to start with.
|
|
|
|
|
Is there a common key column between these two tables?
|
|
|
|
|
Thanks for your response.
There is no common key or relation ship between them.
Both queries are from different tables.
|
|
|
|
|
Then joining them may not make any meaning since the order of rows returned by SQL Server is not guaranteed. If you still want to proceed, add an IDENTITY column to both tables and use those columns to join the tables.
|
|
|
|
|
I cannot seem to get this working correctly. I did get it to work once but after I compiled it again it stopped. I am using the code from Scratchpad/Signature Capture as BMP on Pocket PC[^].
The strange thing is when I save it, it saves just a white background with no writing. It will let you draw on the screen but it doesn't save what you are drawing. I have posted to that article with no reply as of it but I just cannot seem to figure out why it would be doing this?
It is kind of difficult for me since it isn't using the System.Drawing framework from the latest version.
I have coded it exactly like he has it:
private string AppPath = Path.GetDirectoryName(Assembly.GetExecutingAssembly().GetName().CodeBase);
private Signature cSignature;
public Sig()
{
InitializeComponent();
cSignature = new Signature();
cSignature.Location = pnlSig.Location;
cSignature.Size = pnlSig.Size;
this.Controls.Add(cSignature);
}
private void Sig_Load(object sender, EventArgs e)
{
cSignature.SetPenColor(Color.Black);
if (File.Exists(Path.Combine(AppPath, "CapturedSignature1.bmp")))
{
DialogResult result = MessageBox.Show("There is a signature that exist.\nWould you like to open it?", "Open?", MessageBoxButtons.YesNo, MessageBoxIcon.Question, MessageBoxDefaultButton.Button1);
if (result == DialogResult.Yes)
{
cSignature.LoadImage(Path.Combine(AppPath, "CapturedSignature1.bmp"));
}
}
}
private void menuItem1_Click(object sender, EventArgs e)
{
Cursor.Current = Cursors.WaitCursor;
cSignature.Save(Path.Combine(AppPath, "CapturedSignature1.bmp"));
Cursor.Current = Cursors.Default;
}
Does anyone else have possibly another idea or another class I could use?
|
|
|
|
|
I actually had to copy the programmers designer code of the form and use it to make it work... weird...
|
|
|
|
|
Can any one Help,
I am trying to do following step dynamically using UIAutomation
in c# 3.0
1)Open Outlook
2)Open Inbox
3)Select first unread email.
4)Open the first unread email.
5)If there are attachements, download the attachements.
Select next unread email and do the same as above.
I have tried below code.I Can open the outlook Express.But I can't read mail.
using System;
using System.Collections.Generic;
using System.Text;
using System.Threading;
using System.Windows.Automation;
using System.Diagnostics;
namespace ConsoleApplicationUI
{
public class ReadMail
{
static void Main(string[] args)
{
ProcessStartInfo psInfo = new ProcessStartInfo(@"C:\Program Files\Outlook Express\msimn.exe");
Process prov = Process.Start(psInfo);
Thread.Sleep(5000);
AutomationElement Inboxstart = null;
PropertyCondition Inboxconds = new PropertyCondition(AutomationElement.NameProperty, "Inbox");
Inboxstart = AutomationElement.RootElement.FindFirst(TreeScope.Descendants, Inboxconds);
if (Inboxstart != null)
{
InvokePattern InboxstartInvoke = (InvokePattern)Inboxstart.GetCurrentPattern(InvokePattern.Pattern);
InboxstartInvoke.Invoke();
}
Console.Read();
}
}
}
Thanks,
Bruze
|
|
|
|
|
Good day folks,
I am searching for a specific website, it displays some useful information for me, however, the information is too much and they are not presenting them in a convenient way. Basically the search result is displayed in a grid type control (most likely gridview), I need to click each page number to see all the content if it is not on first page.
So I am wondering if I can do something to save my time? I want to write a httpwebrequest to retrieve the search result and save to local for analysis, that way I need to know how can I let my program to automatically "click" on the page number and get the result on that clicked page.
Can anyone point out some direction for me?
Thank you very much in advance. Any hint is greatly appreciated, currently this is very inconvenient and is costing me too much time every day
|
|
|
|
|
hi, you need to know the parameters send by the page 3 click than you can redirect using the new http request for page 3
i think that would be one way
|
|
|
|
|
Thanks for replying, you know what? actually none of the page number has a unique URL link, so there is no way for you to simply re-create those links for the httpwebrequest. I think those are bunch of doPostBack event for mock up in the httpwebrequest, if possible.
|
|
|
|
|
Good morning all.
I am attempting to set the cursor in a textbox for a user where they can continue to type. In this case I am adding http:// on the textbox enter event.
I would like the curson to 'wait' at the end of the / instead of the https:// being highlighted. If the user doesn't click after the / they will type over the http://.
I have seen some complicated code on the web to simulate a mouse click, but I would prefer a more simpler method.
Any suggestions?
Thank you, WHEELS
|
|
|
|
|
hi,
for you continue typing use "textBox1.SelectionStart = textBox1.Text.Length" if the Text of the textbox is only http:// or https://
if something is written behind the last / you need to search the position of the last / ....
You can set the cursor of the whole textbox to a wait cursor but only at a position you need to programm it your self, that would be a little tricky..
greetz
|
|
|
|
|
Hi rootjumper.
The textBox1.SelectionStart = textBox1.Text.Length is exactly what I was looking for.
Thank you, WHEELS
|
|
|
|
|
HI,
I have developed the windows form with edit controls and static controls which at design time seems ok.
But when I compile the project and run the form and the controls on it shrinks.
I tried adding the Resize event and settings the FormBorderStyle to FixedSingle through which the form seize seems ok but the controls on it still shrinks.
Any kind of help is appreciated
-Regards
"A winner is not one who never fails...but the one who never quits"
|
|
|
|
|
Ganesh_T wrote: But when I compile the project and run the form and the controls on it shrinks.
Are you running it on a different machine?
|
|
|
|
|
running on Windows 2003 server
IDE is VS2008
"A winner is not one who never fails...but the one who never quits"
|
|
|
|
|
i mean that could be a bug what IDE you use ?
i got the same behaviour a couple time ago.. i think i solved it with a reinstallation of the IDE
hope i could help
|
|
|
|
|
I am using visual studio 2008 and runnin on windows 2003 server machine
"A winner is not one who never fails...but the one who never quits"
|
|
|
|
|
i got a check box column in my datagrid.
how should i code to fire check event
|
|
|
|
|
If you are placing your check box in a datatemplate, you could use something like -
<DataTemplate>
<CheckBox Checked="CheckBox_Checked"/>
</DataTemplate>
The check box checked event will then handle check box click.
A click event is also available.
|
|
|
|
|
Hi all,
Some background information:
I have a method A that calls another method B. In method B an asynchronous TCP/IP read occurs: this.tcpClient.GetStream().BeginRead(byteReadBuffer, 0, byteReadBuffer.Length, new AsyncCallback(ProcessReadBuffer), tcpClient.GetStream()); on result method ProcessReadBuffer
So my question:
How can I wait for the asynchronous ProcessReadBuffer method to complete in method B. Reason being that I require some results from ProcessReadBuffer method in method A?
Many thanks in advance.
Kind regards,
The only programmers that are better C# programmers, are those who look like this -> |
Programm3r
My Blog: ^_^
|
|
|
|
|
Why not just call it synchronously then?
Regards,
Rob Philpott.
|
|
|
|
|
|
Try storing the result in an IAsyncResult variable and then call AsyncWaitHandle.WaitOne() on that object.
|
|
|
|
|
Hi,
Thanks for the response.
I did try doing that, but I noticed that the WaitOne() returns immediately with a true result and only then after it goes into the method.
Kind regards,
The only programmers that are better C# programmers, are those who look like this -> |
Programm3r
My Blog: ^_^
|
|
|
|