|
for the properties of the controls you'll need to make a form or something where they can be set.
If you want to save them (most likly you will) you'll need to save them to a db or use serialisation (do some research on this since its not easy).
for the resising you'll need to use the mousedown event then check where the mouse is on the control, if its on the edge of the control then draw the rectangles, change the mouse to the appropriate arrows and put a boolean on true (this boolean indecates that the mousebutton is down also save the mouseposition since you'll need it to calculate how much the user is resising,in the mouseup event you put it to false) then in the mousemove event compare the current with the saved position and resise you'r control. I have some code that does this somewhere, when I have 10min of time I'll look for it.
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
Thanks For Replying ..
Now i have done the things for properties of runtime controls .I used PropertyGrid control which is in vs2005 to get the selected control in runtime .
1) DO u know how to set the properties one by one like in vs2005 properties toolbar ( Example the comboxbox shows all the items present in the form in windows )Presently i am concentrating on this .And have to work on resizing .
2) In the future , I have to save all these controls properties in to an XML file and i have to retrieve the same ,and align and look like before saving the file .
If u have any ideas of these things , Kindly reply me
D.V.Sriram
|
|
|
|
|
haven't used propertygrid before so don't really know about 1)
for 2) you'll need serialisation or write it all you'r self (to xml) if I have time I'll make a small example for serialistion
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
i created the controls at runtime on panel using toolstrip in vs2005 using vb.net , so if add this it is working on the panel, toolstrip that' all . i am not able to access the runtime control like label1 ,checkbox1,RB1 ,TB1 like that . if i am able to access the control like label1 it is showing the squares but not able to resize the runtime controls , --- using Pickbox from codeproject
DVSriram
|
|
|
|
|
in order for you to be able to access the control you'll need to give at a unique name (when created at runtime) also you should add a addhandler to it (with the click event) then in the code of you'r addhandler you can cast the sender object to label and access it like that
so something like this
on creation
dim l as new label
l.name = 'label1'
addhandler l.click, addressof label_click
the handler
private sub label_click(sender as object,e as system.eventargs)
if sender.gettype.equals(gettype(label) then
dim l as label = sender
l.doyourdrawingofthesquareshere
end if
end sub
hope this helps
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
Presently i worked on resizing the controls , it works for dynamic controls also .
Thanks
|
|
|
|
|
hi,
say for example,
i have created one database application in vc, and i access the MS access database through that.
so first i create a DSN from control panel\odbc datasources.
obviously i have to access that database through the dsn from vc++.
now if i want to install it on my clients machine, i have to copy the files first, then map the DSN and then run the application.
now what i want is, is there any method to automate the creation of DSN, such that, just by a single click on my application, this DSN gets created.
thanks.
|
|
|
|
|
Do NOT post the same question in multiple forums. This is called "spamming" is just plain rude.
|
|
|
|
|
Hi
Can anyone help!
I want tot develop a weather reporting software and an Economic tutor. I'm a bit
confused how to get about them. Thanks
|
|
|
|
|
First step is to use a language that is still alive. VB6 is totally unsupported, move to VB.NET. Then, you need to either have a better starting point than 'I have no idea how to write XXX', or you need to pay someone to write it for you.
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 )
|
|
|
|
|
sir,
please tell me how i can make application in which server have database and client can make search through this database in vb.net
|
|
|
|
|
this is simply a matter of using the correct connectionstring just point the data source part to the server: servername\sqlserverinstancename
example:
Data Source=server1\server1_DEV;Initial Catalog=DB;User ID=sa
then you can write you app like any other
If you'r question was how to write the app then you'r asking at the wrong place. Nobody here will write it for you, when you have a specific problem then you can ask for help here
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
|
1. Is the SQL server allowed remote connect?
2. Port blocked? Firewall?
3. And many many reason can cause it.
|
|
|
|
|
Thanks for your response.
What shd i do so that the client machine can allow to remote access.
Thanks once again
vandana
|
|
|
|
|
from the error I would think that you try to use you connection to the db before it has been initialized.
I'd debug the programme from the start and see where the connections with the db is made and where you first use it.
also check if the client can access the server by ip (just ping to the ip and see if it works)
next to that you have to give both the servername or ip and the sqlservername (usaly its the servername_dev)
so if you'r server has ip 1.1.1.1 and is named server and the database is named 'db' and you can login with user sa and pass sa then you'r connectionstring would look like:
Data Source=1.1.1.1\server_DEV;Initial Catalog=db;User ID=sa;Password=sa
hope this helps
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
I used same connection string as you told me but it gives error that
"An error has occured while establising the connection to the server, the failer may be boz the fact that under the default settings sql server does not allow remote connection"
What type of setting i will have to change so that the client would be able to connect with server remotely?
Thanks once again
vandana
|
|
|
|
|
I would first check the settings of sql server to see if it allows remote connection (like the error says)
then check firewall settings
networksettings
...
if the connectionstring is correct it must be something like the above
If my help was helpfull let me know, if not let me know why.
The only way we learn is by making mistaks.
|
|
|
|
|
Actully problem is that the sql server doesn't allow the remote access.
I have changed connection in the configuration wizard
the remote connection to Local and Remote connection from local connection only ,I have also tried to do it by creating server's alias but nothing happened
Can you tell me what shd i do for the remote access of sql server?
Thanks once again
vandana
|
|
|
|
|
Create Console Application in Visual Studio 2005 that prompts the user for a five digit positive integer, separates the number into individual digits and prints the digits separated from one another by three spaces each. For example, if the user types in the number 42339, the program should display at the command prompt
The separated digits of the input number are 4 2 3 3 9
liv2luv
|
|
|
|
|
use divided by (/) and modulo (%) in a loop and print them.
here is the techique for you.
divide the number by 10000.
then you will get 4.
print it and give 3 spaces.
then number=number%10000.
then divide it by 1000
and so on.
|
|
|
|
|
The easiest way to do this is to convert the number to a string, loop through each character in the string and add white space between each digit. The following code demonstrates how to do this:
int number = 12345;
string number_string = number.ToString();
StringBuilder output = new StringBuilder();
for (int i = 0; i < number_string.Length; i++)
{
output.AppendFormat("{0} ", number_String.SubString(i, 1));
}
number_string = output.ToString().Trim();
Paul
|
|
|
|
|
Nothing like doing someones homework for them.
Congratulations!! You've now helped this person fail his class!!
I know this may seem like an odd thing to say, considering he'll use YOUR code to pass HIS little assignment. But, since HE didn't write the code, HE will have LEARNED NOTHING that he MUST LEARN in order to write code for FUTURE projects.
Again, congratulations on helping him fail...
|
|
|
|
|
I think you should calm down a bit. People help each other for free on this site, and I am as entitled to offer assistance as anyone else. If you think this person is posting homework then take issue with him, not me.
Also, please don't shout at me. The forum guidelines forbids it.
Paul
|
|
|
|
|
pmarfleet wrote: If you think this person is posting homework
You didn't read the OP's subject line, did you? "academic problem" screams homework.
Think about the help you're giving and why the person is asking for it before you post. Are you going to tell someone how to write a virus too?
|
|
|
|