|
i want my dialogboxes to appear as win-vista dialogboxes? can i do it in vb.net? how can i change the font size/face in a "msgbox"???
(Jameel)
|
|
|
|
|
jamilkhan007 wrote: how can i change the font size/face in a "msgbox"???
You can't. You have no control over the appearance of the built-in MessageBox. You'll have to write your own MessageBox class if you want this kind of control.
|
|
|
|
|
when i apply fonts to unicode language "Urdu" in a rich text box in vb.net, the urdu-fonts dont work at all, i have installed them properly bt.....
(Jameel)
|
|
|
|
|
Hey,
I am trying to capture a screen shot of a form that is in the background. I donot want to display it to the user. I am doing the following:
Dim Pic As Bitmap
Dim SS As Graphics
Pic = New Bitmap(Me.Width, Me.Height, Imaging.PixelFormat.Format32bppArgb)
SS = Graphics.FromImage(Pic)
SS.CopyFromScreen(Me.Location, New Point(0, 0), Me.Size, CopyPixelOperation.SourceCopy)
Pic.Save("C:\test.jpg", ImageFormat.Jpeg)
The problem is it takes a shot of the screen in the region specified excluding the form! This is even if I am displaying the form. Any suggestions?
Thanks
Ahmad
|
|
|
|
|
Ahmad Zaidi wrote: I am trying to capture a screen shot of a form that is in the background.
That's not possible.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Unfortunately you would have to flick to the other form, take the scrren shot then flick back to the original form...it will look annoying but it will achieve your goal. The way a screen displays things exists only on one layer. Although windows stack in many layers...there is no way of detirmining the pixel data from behind the current form because the entire screen image renders in only 2 dimensions.
|
|
|
|
|
Since the non-visible portions of a form are not painted, you'll be grabbing a screen shot of nothing.
|
|
|
|
|
Hi,
there is a different possibility combining the following ideas:
- Control.DrawToBitmap() captures a Control (a Form is a Control) and paints it again
into a bitmap; AFAIK it does not rely on the screen, on covered parts, Z-order and the like.
- if that were to leave out those parts that are covered by some other Window, you could
move the Form to a position "outside your monitor", say at (20000,20000)
Moving the form there will make DrawToBitmap() capture it all
- what remains to be solved now is to move the form back to its original position without
coming topmost; my first attempt would be to just restore its Location, and see what happens.
BTW: whatever the method for capturing the form, since it does not have focus, I expect
it to look a bit different (as compared to when you have the form active and in front of you).
Good luck.
If you try it, let us know the outcome !
|
|
|
|
|
Hello,
Is it possible to catch errors like Run-time error 40006 in Visual Basic 6.0?
So i can write my own error message.
Thanks.
Bas
|
|
|
|
|
Other than the usual On Error Goto , no there isn't. 40006 is a problem with the underlying WinSock Socket. The best solution isn't to hide the error behind a pretty message, but to fix the code that's generating it.
|
|
|
|
|
Hello Dave,
Thanks for the information.
The situation is as follow:
I am making a tool which checks a range of portnumbers.
I made a listener tool, which listens on the portnumbers, and a tool which tries to communicate on the portnumbers. One by one.
I am using a textbox to show a portnumber is open or closed.
When a portnumber is closed (by a firewall or something else) the 40006 error is shown. But i am not sure if error 40006 only pops if a portnumber is closed or also in other situations.
Regards,
Bas
|
|
|
|
|
The error can pop up under any WinSock circumstances, not just when you close a socket.
|
|
|
|
|
I want to change the user input language as soon as my app runs, and then restoring back to the orignal language as my app closes.... bt i cant do it
any help with code snipset plzzz
(Jameel)
|
|
|
|
|
I've never had the opportunity to try, but I don't think you can change the input language for a single application. If you're trying to change the system-wide input language, don't. Remember, Windows is a shared system where multiple apps can run at the same time. Changing the input language system-wide changes it for all applications.
If your app changed a system-side setting on my machine, I wouldn't be able to get to Add/Remove Programs fast enough...
|
|
|
|
|
I thought it was possible to change the input language for a single window
try this (just in windows)
on you're startbar - right mouse - toolbars - language bar
then you get a language bar on wich you can change the input language of every window (currently I'm typing this message witch an EN input while every other window has an NL input)
when you change windows then the input language automaticly goes to the language you've selected for that window
but every time you open a new window the language for that window is set to the default
I wouldn't know how to do this in code but If you can find a way to change the language and you want to make sure that other windows aren't affected by it than you could catch when you're program loses focus and put the language to the one it was and when you're program gets its focus back you put the language to the one you need
(a bit clumsy but ...)
|
|
|
|
|
TDDragon wrote: (a bit clumsy but ...)
I don't "clumsy" is the word, though, "unsupportable" comes to mind...
I didn't think you could do it "by-the-window". I thought it was all or none. If I'm wrong, I have no idea how to change it for a window.
|
|
|
|
|
yeah that would be a better word for it :p (my motherlanguage is not english (dutch) so...)
well I know how to do it in windows but not in code so that's not much help I guess
|
|
|
|
|
Thanx for all of ur supports friends.... i m so happy to know abt such helping site in friends... thanx again,
well i did it programatically as following...
dim culture as new culture("urdu-pk")<br />
dim urdu as inputlanguage=inputlanguage.Fromculture("culture")<br />
inputlanguage.currentinputlanguage=urdu<br />
<br />
dont mind for the syntex are spell mistake
(Jameel)
|
|
|
|
|
Hi All
i want to use Following SQL join in an Adapter
<br />
select Property_Mass.Actual_Extent,Property_Mass.Attrib_code,Property_Mass.Lis_key,Property_Mass.Func_key,Property_Mass.Density,<br />
Property_Mass.New_Net_Usable_Extent,Property_Mass.New_Total_Land_Factor,Property_Mass.New_AdJ_Extent_1,Property_Mass.New_Points_1,Property_Mass.New_ADJ_Extent_2,Property_Mass.New_Points_2,Property_Mass.LS_Prediction,Property_Mass.LS_Confidence,Property_Mass.LS_TYPE,Property_Summary.Purchase_Date,Property_Summary.Purchase_Price<br />
from (Property_Mass Inner Join Property_Summary on Property_Mass.Lis_Key = Property_Summary.Lis_key)<br />
where Property_Mass.Lis_key = Property_Summary.Lis_key<br />
in my Application i will be Updating,Inserting and Deleting. i get warnings in Insert, update and Delete. that
<br />
The original query has a select list that has columns from multiple tables. The statement cannot be generated automatically for this type of query.<br />
How can i overcome this.
Vuyiswa Maseko
|
|
|
|
|
Create a proper data layer, with proper data access code, where you can run any SQL you like.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
DataAdapters only work on single tables. You'll have to write the data layer code to support this query, and it updates, yourself.
|
|
|
|
|
Thanks Dave,i want to Join these two tables, but the second table, that has onyl two field, i dont want to update them, i only want to update the First one in the adapter.
can i create a Procedure for the first and create one Procedure for Update, insert, delete?
please post a link on data layers, remember am new
Vuyiswa Maseko
|
|
|
|
|
The DataAdapter, if used with a xxxCommandBuilder object, will take the initial SQL SELECT statement and build the other three queries from it. If it references more than one table, the other three queries cannot be built. In that case, you will have to provide SQL xxxCommand objects for the other three queries.
|
|
|
|
|
Am still new to Vb.net even i got Successfullfy Finished some small Projects. Dave when it comes to DataLayer, i have no Experience, i tried to google the data layer. but did not get a clear Answer, all i see are Opps codes that has nothing to do with SQl, please point for me a Thread or an article, or site that can help me understand the data layer and and in my situation , having two tables joining them , but the update should be done in one table.
Thanks Dave
Vuyiswa Maseko
|
|
|
|
|
The data layer is simply a class, or collection of classes, that does nothing but interact with and maintain the database. It's where all of your SELECT, INSERT, UPDATE, DELETE, queries get executed from and it passes the results back up to the business logic layer, and sometimes the UI layer, like if you were filling controls with selectable data.
|
|
|
|