|
Why not just use the WebBrowser control in the toolbox??
|
|
|
|
|
i want to get the id of the controls in html page
main reason i am looking for is to record the actions and events on the browser and replay it.
with regards
Balagurunathan.B
|
|
|
|
|
Hi,
I've seen some programs use wide images which have like 3 images inside and on run-time only a third on the image is shown in a picture-box and on mouse-over a different third of the image is shown and on-click a different third of the image is shown. does anyone know how to do that or there any built class for such things?
Thanks
|
|
|
|
|
You handle this like any mouse over, you handle the events for enter and leave and you change the picture as the mouse position changes, in code. Writing a control to encapsulate this would be very easy, if you need to do it in a lot of places.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
any example for how to divide the image?
|
|
|
|
|
Probably the most logical thing to do is not divide the image, just write a control that draws different portions of the image in it's paint event, based on the mouse position.
Or you can just create bitmaps of the correct size and draw the parts of teh iamge into them.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Thanks for the reply, but that is what i mean.
do you have eny example for how to draw different portions of the image on the control?
|
|
|
|
|
Source = Image.FromFile("c\test")
Dim imag As New Bitmap(width, height) 'size of the portions you want
Dim rc As New Rectangle(x, y, width, height) 'location from where to take the portions
Dim gr As Graphics = Graphics.FromImage(imag) 'graphics to do the extraction
gr.DrawImage(Source, 0, 0, rc, GraphicsUnit.Pixel) 'the extraction from the source image
Dim ResultImg as Bitmap = new Bitmap(imag) ' the resulting image
It would not be too diffucult to base this process around mouse actions. width would be one third of the images total width, height would be the height of the image. The source image does not have to be from a file, it just was in my original app.
|
|
|
|
|
Some one beat me to the answer. I'd recommend you both buy a good book to give you access to this sort of information, and learn how to negotiate google and the MSDN site, because you're always going to want to be finding out how APIs work, it's good to be able to find that info for yourself.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
I am working on a project where I am showing data In datagrid by binding this with datatable.I am using a listview as well.Now what I want is that if user select single or multiple rows from the grid and click on add button then the selected rows should be added In the listview.
For single row this can be done but don't know how to do for multiple rows.
Any idea how to solve this?
Thanks in advance
|
|
|
|
|
hi ,
use following statement
for i as integer =0 to datagridview1.SelectedRows.count-1
'your code appear here
next
Rupesh Kumar Swami
Software Engineer,
Integrated Solution,
Bikaner (India)
My Company
|
|
|
|
|
Thanks for the reply but I am using datagrid not datagridview and there is no selectedrows property for datagrid in vb.net 2003.
|
|
|
|
|
What condition should appear in the for..next loop to get the selected rows?
I tried the following
Dim I as Integer
for i = 0 to datagridview1.SelectedRows.count-1
what code should appear here to get the selected rows.
next
|
|
|
|
|
Problem in Vb.net useing crystel report Load report to fail
i am getting error load report to fail in vb.net windows form project here i pest exception details please help me
System.Exception was unhandled
Message="Load report failed."
Source="CrystalDecisions.CrystalReports.Engine"
StackTrace:
at CrystalDecisions.ReportAppServer.ReportClientDocumentWrapper.EnsureDocumentIsOpened()
at CrystalDecisions.CrystalReports.Engine.ReportDocument.Load(String filename, OpenReportMethod openMethod, Int16 parentJob)
at CrystalDecisions.CrystalReports.Engine.ReportClass.Load(String reportName, OpenReportMethod openMethod, Int16 parentJob)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.EnsureLoadReport()
at CrystalDecisions.CrystalReports.Engine.ReportDocument.SetDataSourceInternal(Object val, Type type)
at CrystalDecisions.CrystalReports.Engine.ReportDocument.SetDataSource(DataSet dataSet)
at ACCOUNT.crview.crview_Load(Object sender, EventArgs e) in D:\D.NET\ACCOUNT\ACCOUNT\crview.vb:line 6
at System.Windows.Forms.Form.OnLoad(EventArgs e)
at System.Windows.Forms.Form.OnCreateControl()
at System.Windows.Forms.Control.CreateControl(Boolean fIgnoreVisible)
at System.Windows.Forms.Control.CreateControl()
at System.Windows.Forms.Control.WmShowWindow(Message& m)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ContainerControl.WndProc(Message& m)
at System.Windows.Forms.Form.WmShowWindow(Message& m)
at System.Windows.Forms.Form.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
at System.Windows.Forms.SafeNativeMethods.ShowWindow(HandleRef hWnd, Int32 nCmdShow)
at System.Windows.Forms.Control.SetVisibleCore(Boolean value)
at System.Windows.Forms.Form.SetVisibleCore(Boolean value)
at System.Windows.Forms.Control.Show()
at ACCOUNT.MainMenu.CashToolStripMenuItem_Click(Object sender, EventArgs e) in D:\D.NET\ACCOUNT\ACCOUNT\MainMenu.vb:line 121
at System.Windows.Forms.ToolStripItem.RaiseEvent(Object key, EventArgs e)
at System.Windows.Forms.ToolStripMenuItem.OnClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleClick(EventArgs e)
at System.Windows.Forms.ToolStripItem.HandleMouseUp(MouseEventArgs e)
at System.Windows.Forms.ToolStripItem.FireEventInteractive(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStripItem.FireEvent(EventArgs e, ToolStripItemEventType met)
at System.Windows.Forms.ToolStrip.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.ToolStripDropDown.OnMouseUp(MouseEventArgs mea)
at System.Windows.Forms.Control.WmMouseUp(Message& m, MouseButtons button, Int32 clicks)
at System.Windows.Forms.Control.WndProc(Message& m)
at System.Windows.Forms.ScrollableControl.WndProc(Message& m)
at System.Windows.Forms.ToolStrip.WndProc(Message& m)
at System.Windows.Forms.ToolStripDropDown.WndProc(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
at System.Windows.Forms.NativeWindow.DebuggableCallback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)
at System.Windows.Forms.UnsafeNativeMethods.DispatchMessageW(MSG& msg)
at System.Windows.Forms.Application.ComponentManager.System.Windows.Forms.UnsafeNativeMethods.IMsoComponentManager.FPushMessageLoop(Int32 dwComponentID, Int32 reason, Int32 pvLoopData)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoopInner(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.ThreadContext.RunMessageLoop(Int32 reason, ApplicationContext context)
at System.Windows.Forms.Application.Run(ApplicationContext context)
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.OnRun()
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.DoApplicationModel()
at Microsoft.VisualBasic.ApplicationServices.WindowsFormsApplicationBase.Run(String[] commandLine)
at ACCOUNT.My.MyApplication.Main(String[] Args) in 17d14f5c-a337-4978-8281-53493378c1071.vb:line 81
at System.AppDomain.nExecuteAssembly(Assembly assembly, String[] args)
at System.Runtime.Hosting.ManifestRunner.Run(Boolean checkAptModel)
at System.Runtime.Hosting.ManifestRunner.ExecuteAsAssembly()
at System.Runtime.Hosting.ApplicationActivator.CreateInstance(ActivationContext activationContext, String[] activationCustomData)
at System.Runtime.Hosting.ApplicationActivator.CreateInstance(ActivationContext activationContext)
at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssemblyDebugInZone()
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.runTryCode(Object userData)
at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()
|
|
|
|
|
Jigneshjpatel wrote: at ACCOUNT.crview.crview_Load(Object sender, EventArgs e) in D:\D.NET\ACCOUNT\ACCOUNT\crview.vb:line 6
What's in crview.vb on line 6? Put a break point before it and step through the code to see what's causing the error (look in local variables for clues).
Pete Soheil
DigiOz Multimedia
http://www.digioz.com
|
|
|
|
|
hi all,
can sql is suppport by all os specially mac and linux.
And give me idea about which database is supported by all os (mac/linux/windows).
help me please......
Thank You in advance
Senthil.S
Senthil S
Software Engineer
|
|
|
|
|
SQL is supported everywhere. SQL Server is another matter. MySQL may be supported on Max and Linux, it seems like a products created by the same sort of hippys as Linux.
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
thanks,
wat about mac os?
wheather it support mysql??
Senthil S
Software Engineer
|
|
|
|
|
Senthil S wrote: wat about mac os?
wheather it support mysql??
If you are looking for cross platform, MySQL is your best bet. Binary distributions are currently available for Windows, Linux, Solaris, FreeBSD, Mac OS X, HP-UX, IBM AIX and i5 OS, QNX, Novell and SCO:
http://dev.mysql.com/downloads/mysql/5.0.html[^]
OR you can download the source code and compile it on other OS not specified above:
http://dev.mysql.com/downloads/mysql/5.0.html#source[^]
Pete Soheil
DigiOz Multimedia
http://www.digioz.com
|
|
|
|
|
Why does control +C and control +V doesn't work on textbox controls of VB.Net 2005 forms when we run them. But Right click -Copy, Paste works fine on the controls.
Could anybody tell what is the reason.
Sekhar
|
|
|
|
|
They do, as far as I know. What makes you think otherwise ? Are these textboxes you've written any event handlers for ?
Christian Graus - Microsoft MVP - C++
"also I don't think "TranslateOneToTwoBillion OneHundredAndFortySevenMillion FourHundredAndEightyThreeThousand SixHundredAndFortySeven()" is a very good choice for a function name" - SpacixOne ( offering help to someone who really needed it ) ( spaces added for the benefit of people running at < 1280x1024 )
|
|
|
|
|
Hello every one
I am making an application in VB 2005 Express. Hear I am accessing a remote database.
When the networks is disconnected for some time and is connected back, the application still dose not connects to the DB again until I exit and start again.
On looking at the thing in detail I was able to come down to the following things
- Can we some how refresh the connection
- Can we refresh / flush the port on which DB is connected
If any one has any ideas of how is it done then plz let me know. Also is there any other way of place where I should look in the application
Regards
Nishkarsh
|
|
|
|
|
Are you making the mistake of opening a connection when you app starts and keeping it open for the life of your app??
Or are you opening a connection, doing your database query, then closing the connection?? If this is the case, the problem you're describing can't happen.
|
|
|
|
|
Yes i am opening the connection once only at start and using through out...
My application is based on a DB will it not take a real extra time every time opening and closing the connection???
|
|
|
|
|
nishkarsh_k wrote: Yes i am opening the connection once only at start and using through out...
That's a really bad practice. Holding a connection open for the life of your application also holds onto a very expensive SQL Server license, which are usually bought by the seat. This means that, for example, you can have 10 connection licenses on the SQL Server and about 50 machines using them IF they just open a connection for the time it takes to do a query, then close the connection. Using your method, the same server would have to have 50 licenses, at an addition 4 times the cost of 10.
Your database connection is probably, in a normal situation, idle for 99% of it's life. That's a lot of time holding onto a license and dogint nothing with it.
If a customer using your application caught you doing that, you'd probably be fired on the spot.
nishkarsh_k wrote: My application is based on a DB will it not take a real extra time every time opening and closing the connection???
Nope. The first connection is the most expensive (process wise). Subsequent connections using the same connection string are cached by ADO.NET and open and close very quickly.
modified on Sunday, December 23, 2007 10:32:46 AM
|
|
|
|