|
If you go with .NET, I suggest checking out SlimDX[^] instead of using Managed DirectX (MDX). AFAIK, MDX is not officially supported on Vista or 7, and doesn't provide access to DX 11 (not sure on DX 10). SlimDX, however, is still in active development, and includes DX 11 support. I haven't found a whole lot of sample code for it, but most MDX code samples can be easily converted to SlimDX (the API is pretty similar).
Dybs
The shout of progress is not "Eureka!" it's "Strange... that's not what i expected". - peterchen
|
|
|
|
|
I have a matrix of checkboxes and I would like to get the id on which the mouse is over. I set the onMouseOver handler programmatically by the following C# code in the Page_Load procedure:
checkBoxObject.Atributes.Add("onMouseOver","mouseOverHandler(this)");
The client's MouseOverHandler function (JavaScript) is:
Function mouseOverHandler(this)
{
alert(document.getElementById(me.id))
}
When I move the mouse over a checkbox I get an empty alert box. It seems that the function "mouseOverHandler " does not get the firing checkbox in the argument"me".
The same code works correctly when I change the triggering event from "onMouseOver" to "onClick".
1. Why does it work with "onClick" and dose not work with "onMouseOver"
2. How can I make it to work with "onMouseOver"
Thank you
Hezi
|
|
|
|
|
I've tested it and it works.
function mouseOverHandler(element)
{
alert(element.id);
}
protected void Page_Load(object sender, EventArgs e)
{
CheckBox1.Attributes.Add("onMouseOver", "mouseOverHandler(" + CheckBox1.ClientID + ");");
}
|
|
|
|
|
You have a Bug/Typo.
hezi wrote: Function mouseOverHandler(this)
{
alert(document.getElementById(me.id))
}
The function should read:
alert(document.getElementById(this.id));
The 'me' keyword is from VBScript.
However, as the other poster showed in his example, it would be better to use a different word for the parameter as the word 'this' has special meaning in JavaScript.
Alternately, don't pass the parameter, and just use the 'this' keyword. It will be the object which fired the event. e.g.
Function mouseOverHandler()
{
alert(document.getElementById(this.id))
}
|
|
|
|
|
I need a program in PHP which can extract the hidden biders from ebay.I will have to insert the item number and the program must show me all bidders of the auction and their emails.
Also the same program must extract the registered contact information for any specified bidder specially the email address
I will pay for this
If someone can help please contact me at totos_back@yahoo.com
Thanks
|
|
|
|
|
dream on
MVP 2010 - are they mad?
|
|
|
|
|
How many forums have you wasted your time on!
And as has been mentioned, there are good reasons for hidden bidders on EBay. It is so that idiots like you don't go nicking their email addresses and selling them to spammer lists!
|
|
|
|
|
Bidders are hidden for a reason and there is no way to find out who they are, let alone their email addresses. Learn how ebay works before you start making ridiculous requirements for an app.
|
|
|
|
|
totolcm wrote: extract the hidden biders
That is why they are hidden so people like you don't see them
|
|
|
|
|
Hi,
I wonder if anyone can help me with the error I am getting when I try and run my application in VB 2008.
"Form1.vb cannot be modified at this time"
I have tried Tools/Option/Build and Run/ Don't save any changes. I have re-installed etc but with no success.
When I put say a button on the form the first time, it works. If I add another say button then that is when I get the problem. Basically adding anything to a form gets the error.
When I save my app then run, it works but I do not want to save before I run.
Thanks in advance
|
|
|
|
|
Isn't this the same question that you've already asked on the Visual Basic forum?
|
|
|
|
|
Yes.
I thought maybe someone who does not use VB would not look at VB message board.
|
|
|
|
|
And since your question pertains to VB, how is posting the question in a non-VB forum for people who don't use VB going to help find an answer?
I know the language. I've read a book. - _Madmatt
|
|
|
|
|
He got the wrong question as well as the wrong forum.
This question is about the Visual Studio IDE and not specific to any language, although it says VB 2008 in the subject. It is a typo, or a mis-comprehension.
So, I think this is the correct forum. It should not be in the VB forum.
|
|
|
|
|
You cannot add buttons or make any edits in the designer while the application is running.
You can however make changes in code.
Add your buttons, then run it is the only way.
PS. This is a limitation of the IDE, not language specific.
Or, as I should say, being able to edit-and-continue in the code at all is a feature not a limitation.
|
|
|
|
|
Hi,
The application was not running or looked as it had stopped. Is there anything that indicates that the app is still running? I did press the stop button. I can make a change to the form designer then go into the code and run no problem from there. It is a strange one that was driving me nuts but properly I am doing something wrong.
|
|
|
|
|
I have made a registration form after filling the form and submitting sometimes it inserts record in data base and sometimes it says file not found (error 404).why is this happening.... Plz help?
site url http://www.enefinder.com/registration.aspx
My code
try
{
int flg = 0;
SqlConnection cn = new SqlConnection("Data Source=server name;Initial Catalog=enefinde_memb;Persist Security Info=True;User ID=user name;Password=password");
String sql = "select * from regmember where email='" + txtEmail.Text + "'";
cn.Open();
SqlCommand cmd = new SqlCommand(sql, cn);
SqlDataReader dr = cmd.ExecuteReader();
if (dr.Read())
{
Response.Write("User name already exist Please Try Another One");
flg = 0;
}
else
{
flg = 1;
}
dr.Close();
if (flg == 1)
{
sql = "insert into regmember(enename,email,password,keyquestion,answer,address,city,state,country,perphone,mobile,cname,activity,yearofstarting,noofemp,location,website,phone)values('" + txtFname.Text + " " + txtMname.Text + " " + txtLname.Text + "','" + txtEmail.Text + "','" + txtPass.Text + "','" + ddlQuestion.Text + "','" + txtAns.Text + "','" + txtAdd.Text + "','" + txtCity.Text + "','" + txtState.Text + "','" + ddlCountry.Text + "','" + txtPerphone.Text + "','" + txtMob.Text + "','" + txtCname.Text + "','" + ddlAct.Text + "','" + txtStart.Text + "','" + ddlNoemp.Text + "','" + ddlCcountry.Text + " " + txtCstate.Text + " " + txtCcity.Text + "','" + txtWebsite.Text + "','" + txtPhone.Text + "' )";
cmd.CommandText = sql;
cmd.Connection = cn;
int i = cmd.ExecuteNonQuery();
if (i > 0)
Response.Write("Record Inserted");
//Response.Redirect("registration.aspx");
else
Response.Write("Not Inserted");
}
cn.Close();
}
catch (Exception ex)
{
Response.Write(ex.Message);
}
}
}
|
|
|
|
|
guess0985 wrote: sometimes it inserts record in data base and sometimes it says file not found (error 404).why is this happening.... Plz help?
The 404 indicates that the webserver is the origin, not the database-server. Can you copy the exception and post it here?
You might also want to consider replacing the concatenated SQL-string with a parameterized version to prevent abuse via SQL injection[^].
I are Troll
|
|
|
|
|
Hi,
I am wondering if anyone coul help. I need use the paint event of a control to retun an image of that control.
I dont even know where to start.
Regards,
Martin
|
|
|
|
|
Martin Beukes wrote: I need use the paint event of a control to retun an image of that control.
I don't think so.
Either you want some special painting to occur in a Control, then you have to implement a Paint handler (this[^] would show the essentials), or you want a bitmap from an existing Control, then you would use Control.DrawToBitmap() which works fine for simple Controls, and needs quite some help for some Controls, such as RichTextBox (DrawToBitmap probably does call Paint itself, but that is not really relevant).
|
|
|
|
|
Hi Luc,
It is almost af if you can read minds. It is a richtextbox that i need an image of. There is no Control.DrawToBitmap() on the control and i have looked pretty much everywhere. I came accross this article [Here] which gave me the idea but none of the execution.
If you know of any way to get an image of a RichTextBox without using a screen capture, it would be much appreciated.
|
|
|
|
|
Just to make sure, here are my assumptions:
you have a RichTextBox, you did not add any explicit Paint or OnPaint method, it shows OK on the screen, but now you want to capture it to a bitmap without scraping the screen? if so I have that covered in C#. Is that OK?
BTW: why do you want a bitmap? and do you need printing?
modified on Monday, January 11, 2010 6:09 PM
|
|
|
|
|
Ok,
I have 2 RTB with diffent contents
I need to print these two RTBs contents on a single page
My plan is to use the GDI to an image of each RTB and then cmbine and print them.
Now the problem. more tha half my users will be on those godaweful netbooks with a screen resolution of 1024x6 <lol> and an A4 page and the my two RTBs is 1045x718 plus margins. So the problem is that i need to capture the whole control and not just what is onscreen.
|
|
|
|
|
I see. That is typical for the more complex controls: they hold a lot of data, not all of it visible at once, and you want to print more or all of it. You can try and solve that through DrawToBitmap (when available and functional), however that isn't very easy to do it right; it might be easier to skip the image and print directly.
I have an RTB derivative that offers both: Print (not tested) and DrawToBitmap (tested and OK). It is C# code. Is that OK?
|
|
|
|
|
awesome. thanks. would help a ton
|
|
|
|