|
Hello there,
I am an ameteur programmer in C# and i am currently doing a project related with WLAN design. I intend to take CAD files as input, more precisely, I want to take architectural floor plan as input, process them, i.e. Assign each wall and obstacle a separate factor of say attennuation of RF signal. Based on the structure I create like i told above i want to map the coverage of the wireless device like access point antenna, so i intend to use clipping as well.
I am having no clue as to how do i set these properties of obstacles in CAD file which is .dwg format and then how do i proceed further..i have a few ideas, which are not concrete. and in the first step i am looking for an SDK which can help me to do programming with CAD files.
Please reply ASAP I am in deep trouble...
Thanks
Abhinandan S. Shah
|
|
|
|
|
An "ameteur programmer" with a very ambitious project like this? You're right, you are in deep trouble!
Abhinandan_Shah wrote:
in the first step i am looking for an SDK which can help me to do programming with CAD files.
Have you tried Googling for a library first? Google Search Results[^]
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hey,
Thanks dave. Actually speaking, I am not exactly an ameteur programmer however I am a an ameture CAD programmer, And as only some part of my project involves CAD programming, I think what I am thinking about is possible, as a matter of fact I have come across 2 Options one is using the ObjectDBX technology from autodesk, and the other is using OPenDWG toolkit from OpenDesign Alliance.
As I am doing my project in C#, I would really want someone to help me in using the ObjectDBX library. Because I have finalized on using it. And after loot of googling, and clustying and many more days of hectic searching i have found this solution which i would like to share, otherwise, Cadsofttools.com has also been an useful resource, but they wouldnt respond to my email.
Thanks for showing concern, I would really appreciate if you help me become a professional from an ameture!!and I feel this is the platform to share your programming dreams isnt it?
Regards
Abhinandan Sunil Shah
|
|
|
|
|
I haven't done any CAD work like this at all, and frankly, your going to find a very small community of people here that has. Your best bet would be to find a forum that is specifically for the library your using. At least there, you'll find an experience base that has used the product your using.
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
Hi
this is exact problem.
when i add webmethod to webservice and build it and update
client webreference, client knows the new webmethod without any problem.
but when i add a new class to webservice project and build it and update client webreference, client doesnt know the new class.
Note:this is a new problem and a few days ago when i added
a new class to webservice client could knows new class.
this problem is for new solutions too.
|
|
|
|
|
Hi
For understanding my problem, I will explain what my program does.I will give instructions, what to do , u can see that. And I will say what my requirement is ,, so that u can rectify my problem.
I have a 3 textboxes in the form.
Theer is a xml file with a value named "style_desc" in it.(ie, Field Names.xml in the project directory)
1st Textbox ------ give the schema file.(Input Schema.xsd from the project directory)
2nd TextBox------- give the input xml file( styleData.xml in the project directory)
some about 30 values for a single field named "style_desc."
3rd TextBox-------- give ur own path to create an xml file with data's fo rthe xml schema.
Then click button LOAD----- what it does is that stores the value(from the Feld Nams.xml) in an array and checks for the entered schema(ie, Input Schema.xsd) that there is ay field named "style_desc". Then if it exists in the schema then itreads the values of "style_desc" and stores into a new xml(for the third Textbox file) and the reamining fields of schema will be automatically loaded with values accodring to the datatype for about 200 values.
ie, for string ---- castle hampers1, castle hampers2.... upto 200 names
for float ----- 4.5, 5.5,.... upto 200 values
so for the style_desc column alone(for 200 data's), first 30 values from the styleData.xml (as ther is only 30 values)and the remaining will be castle hampers31, 32.... so on.
this is what I did.
Now my requirement is that I have some other xml file (say billtodata.xml ) with about 30 values for a field named "billto_name"..
Now I should add "billto_name" along with "style_desc" in the xml file(Field Names.xml) . Now it should be also stored in the array and check for the schema whether there is any existence of the field named "billto_name" trhen if it exists it should read the values from billtodata.xml and load it into the new xml with the values for the billto_name.
so Like this I will be adding mor xml file with values for single field . So can u please finish it for me . or else give the correct idea with some coding help.
I think u will be clear now ..
This is very urgent need for me.Here is my coding part. please correct me to do my requrement.
here is my coding part where under the load button I have this.there will some *****************. that is the place wher I will load styledata.xml.
private void button2_Click(object sender, System.EventArgs e)
{
ArrayList FiledNames = new ArrayList();
XmlDocument xdc = new XmlDocument();
//Read the file which contain the field names
xdc.Load(@"C:\CDEV\testdatagenerator\Field Names.xml");
XmlNodeList nodFields = xdc.DocumentElement.SelectNodes("//item");
for(int i=0; i
|
|
|
|
|
I'm trying to connect using DirectoryServices in c# to Active Directory.
I can connect just fine over port 389 using LDAP://server:389/
I can also connect to port 636 (ssl) using LDAP://server:636/ (note, it's LDAP:// not LDAPS://)
I just need to make sure that it's encrypting everything when I connect with LDAP://server:636/
Whenever I try to use LDAPS:// it bombs with an unknown error.
Is it correct to assume that by specifying the port of 636 over LDAP:// it will connect over SSL or is that wrong?
|
|
|
|
|
can anyone tell me how to play/view a quicktime - .mov file inside of a C# windows application
|
|
|
|
|
This isn't built into the framework (nor should it be), but you should be able to use this if you can add a reference to the QuickTime ActiveX control.
Any remotely useful information on my blog will be removed immediately. There are 10 kinds of people in the world. Those who have heard of the ubiquitous, overused, worn-out-like-an-old-shoe binary "joke" and those who haven't.
Judah Himango
|
|
|
|
|
I have a large code under button_click event. I use XML DB. The code consists of 4 blocks of code after each one I save the data [doc.save("DBFileName.xml")].
Each block (starting from the second one) read from the data that was saved by the previous block, but when I let the 4 blocks to work totally the program stops before completeing the code under button_click event. Nearly half of the tasks are performed and saved then the program stops and does not continue.
I want to add a code after each block that make the program to stop for about one or two minutes then continue performing the next block, but I do not know how ?
could any one tell me how ?
|
|
|
|
|
ImanMahmoud wrote:
I want to add a code after each block that make the program to stop for about one or two minutes then continue performing the next block, but I do not know how?
Well, you could use a timer or suspend your thread to achieve this but somehow I doubt that it will solve your problem. And even if it did it would be a rather dirty hack.
ImanMahmoud wrote:
Each block (starting from the second one) read from the data that was saved by the previous block, but when I let the 4 blocks to work totally the program stops before completeing the code under button_click event. Nearly half of the tasks are performed and saved then the program stops and does not continue.
Have you tried to find out where exactly your application hangs? Knowing which operation causes your application to freeze usually is the first hint in order to solve such a problem.
Best regards
Dennis
|
|
|
|
|
It sounds like you probably have a number of performance issues going on here, but let's focus on the obvious.
First, your app freezes when the button is clicked because it's single-threaded. You should queue a user work item or spawn a new thread to do the long-running work in the background. Check out this two-part article from Visual Studio Magazine. It covers exactly this topic.
http://www.ftponline.com/vsm/2004_06/magazine/features/jberes
Second, you say your program "stops" halfway through. Does "stop" mean it crashes or does it mean it hangs or does it mean it just seemingly mysteriously doesn't do what you expect? Run your code with the Visual Studio debugger and step through it to find the problem. Check the documentation for Visual Studio if you need help with this.
Hope this helps
|
|
|
|
|
PatrickShane wrote:
your app freezes when the button is clicked because it's single-threaded. You should queue a user work item or spawn a new thread to do the long-running work in the background.
Threading is not a solution because the 4 blocks must be performed orederly, the 1st is performed and saved then the second, and so on.
Furthermore, the 2nd block reads from the data that was saved by the 1st one, and the 3rd reads from the data that was saved by the 2nd, and so on.
PatrickShane wrote:
Does "stop" mean it crashes or does it mean it hangs or does it mean it just seemingly mysteriously doesn't do what you expect?
My application hangs due to overload, because it performe a task then save it the read from what it saved to perfrome the following task the save it, and so on.
PatrickShane wrote:
Run your code with the Visual Studio debugger and step through it to find the problem.
The Visual Studio debugger is not helpful because I ran each block separately (block by block), and each was working and saving correctly.
|
|
|
|
|
ImanMahmoud wrote:
Threading is not a solution because the 4 blocks must be performed orederly, the 1st is performed and saved then the second, and so on.
Threading has nothing at all to do with what order the blocks are processed in. The worker thread can easily preform all the work, in order.
"hangs due to overload" doesn't mean much to anyone (and I would suspect that you are mis-interpreting what is happening).
More of a code sample might help, but in any case, you should move the entire code out of the click event, and just have the click event start the thread that does the work and return. Have the worker thread signal the UI when it is done (or even signal progress as it works.
Anger is the most impotent of passions. It effects nothing it goes about, and hurts the one who is possessed by it more than the one against whom it is directed.
Carl Sandburg
|
|
|
|
|
ImanMahmoud wrote:
Threading is not a solution because the 4 blocks must be performed orederly, the 1st is performed and saved then the second, and so on.
You misunderstand me. I didn't mean you need a separate thread for each block of work. I mean you need to move the these 4 blocks of work onto a background thread to get them off the thread that services your WinForm. You can do all 4 blocks in the same background thread in the same order that they're done now.
If you leave the long-running work in the main thread, then your application will appear to "hang" to the end user while this work is being performed. Your application won't be able to repaint itself, it won't respond to their mouse clicks, etc. You're setting yourself up for a bad user experience this way. Seriously, go read that 2 part article I gave you a link to.
ImanMahmoud wrote:
My application hangs due to overload, because it performe a task then save it the read from what it saved to perfrome the following task the save it, and so on.
How did you reach the conclusion that you're hanging due to some mysterious "overload" problem? If the code runs correctly in the Visual Studio debugger with the same data you're using when you run it outside of the debugger, then it's highly unlikely that your app is hanging for the reasons you suspect.
Do you have PerfMon data to show whether this is a high-CPU-usage hang or a low-CPU-usage hang? Are you calling any of the classes you use from the .Net Framework asynchronously? Have you put any tracing into your code so that you can tell what point your code gets to when the "hang" occurs? Do you have any exception handling in your code? If so, are you swallowing errors that might give you a clue what the problem is? Have you examined your code for infinite loop issues?
If you're using large amounts of memory in these 4 blocks of code, then it's possible (but not likely) that .Net garbage collection is running and blocking your app. If that were the issue, then it could appear to you that your application is "hung", but it wouldn't stay in that state forever. Your code would eventually resume. Looking at a "hang" dump of your app's process would be the only way to confirm this.
If you've tried everything else that you can think of to determine the source of the "hang", you can always download the Debugging Tools for Windows and use them to take a series of hang dumps of your application. You can then open the hang dumps in the debugger and see exactly what's going on to cause the hang.
http://www.microsoft.com/whdc/devtools/debugging/installx86.mspx[^]
If you're not familiar or comfortable with analyzing hang dumps, I can give you some basic assistance with that in this forum. If you need detailed help, then give us a call at Microsoft Product Support Services and open a ticket - (800) 936-5800. We would be more than happy to help you figure out what's going on in your application. And depending on how you bought Visual Studio (retail or MSDN subscription), you may have support incidents available, so the call wouldn't cost you anything.
PatrickShane
|
|
|
|
|
You can still do your tasks in a separate thread...I don't think he was suggesting that you create multiple threads for each block of code. Create one, let it do all of your tasks, just as your button event handler would have. At least this way you'll have control of your window.
How long is your applications "hanging"? If it never stops hanging, then it's not an issue with overload, there's something in your code that is causing the application to hang. Step through it line by line to see exactly what is going on.
|
|
|
|
|
How could i design two windows forms(Parent & child) like in MSword that the maximum size of the child form does not exceed the max size of the parent form and when maxmizing the child form its control cox still appeare below the control box of the parent form ?
|
|
|
|
|
ImanMahmoud wrote:
How could i design two windows forms(Parent & child) like in MSword that the maximum size of the child form does not exceed the max size of the parent form and when maxmizing the child form its control cox still appeare below the control box of the parent form?
Could it be that you want to create an application with a Multiple Document Interface[^] (MDI)? If so, check out Multiple-Document Interface (MDI) Applications[^] on MSDN.
Best regards
Dennis
|
|
|
|
|
easy,in the properties inspector for the main form, set the "IsMdiContainer" property to true. then create a new form and call it Form2 (the default value, used for the sake of this example) in the load event of the first form (Form1), paste this code.
Form2 Form2 = new Form2();
Form2.MdiParent = this;
Form2.Show();
the Form2 now cannot escape the parent, which is an Mdi, or multiple document interface form.
|
|
|
|
|
hi, I'm making a simple html editor, and in order for it to be actually somewhat useful, I need to color code the text within the <> characters. I've gone through the regular expression tutorial, (which was written very well by the way), and I have a question. How do I change the color of the text that the expression finds. the text I want to change is in a richTextBox1. also, without forgetting the previous question, how do I make an event handler for when to color code these things. I would do it on text change, but that really doesn't work well cause it eats up a lot of memory, and makes the program flicker. atleast I think it does. any help is very very appreciated.
|
|
|
|
|
I am not able to pass values between forms. The main form calls a custom dialog that offeres options. On click, the form sets the string variable that needs to be read by the form. Once you get back to the first form, that string is not able to be read.
Here is the code from form1:
<br />
public class MainParent : System.Windows.Forms.Form<br />
{<br />
public string fromForm2; <br />
<br />
public MainParent()<br />
{<br />
InitializeComponent();<br />
}<br />
static void Main() <br />
{<br />
Application.Run(new MainParent());<br />
}<br />
<br />
private void MainParent_Load(object sender, System.EventArgs e)<br />
{<br />
GetFormTwoData();<br />
}<br />
<br />
public void GetFormTwoData()<br />
{<br />
Form myForm2 = new Form2();
myForm2.Owner = this;<br />
myForm2.ShowDialog();<br />
<br />
}<br />
<br />
ok... here is form 2
<br />
public class Form2 : System.Windows.Forms.Form<br />
{<br />
private System.Windows.Forms.Button button1;<br />
string controllerName = "";<br />
<br />
private System.ComponentModel.Container components = null;<br />
<br />
public Form2()<br />
{<br />
<br />
InitializeComponent();<br />
<br />
}<br />
public string ControllerName<br />
{<br />
get<br />
{<br />
return controllerName;<br />
}<br />
set<br />
{<br />
controllerName = value;<br />
}<br />
}<br />
<br />
#region Windows Form Designer generated code<br />
<br />
<br />
public void button1_Click(object sender, System.EventArgs e)<br />
{<br />
<br />
ControllerName = "UtilitySaver";<br />
this.Hide();<br />
}<br />
<br />
}<br />
}<br />
OK... so when form 1 calls form 2 and user clicks button, the fromForm2String needs to match the ControllerName from Form 2???
Sorry if this does not make sense. I am a tru newbi, but not afraid of the work and so VERY wanting to learn...
Thanks in advance.
|
|
|
|
|
Hi,
I was trying to look into your code?? Where is "fromForm2String" in the code.
Button is on Form2, right. What should happen when one clicks on the button on form2. Please expalin a little more of this.
|
|
|
|
|
Had this nice long reply, and the problem was answered.... Thank you so much for your time anyway.
-dgb
|
|
|
|
|
Your code is fixed quite easily:
First of all, you're creating an instance of Form2 . Then why do you store it in a variable of type Form ? I guess the line should read:
Form2 myForm2 = new Form2();
That way you can access myForm2 's property ControllerName . Form doesn't have such a property, your derived class has.
Second, after the button has been clicked you're just making myForm2 invisible (this.Hide() ). Unless you're actually closing the form, your first form will remain in myForm2.ShowDialog() . So I'd suggest you replace this.Hide() with this.Close() .
Regards,
mav
|
|
|
|
|
OK. I will check tomorrow if that works. I assume it does. I thought you had to ref the Form... not sure why (I was adapting some code from a book). It makes total sense to ref the Form2 myForm2 = new Form2();
Thanks so much.
|
|
|
|
|