Solved

how can i print what form and sub i am in side of???

Posted on 2006-11-10
6
178 Views
Last Modified: 2010-04-23
i want to be able to print what form or file im in and the sub im in at the time of the call...

im sorta writing a debug info file ...but i  want to be able to see where i am too


thanks in advance for any code or help you may provide
0
Comment
Question by:Johnny
  • 3
  • 2
6 Comments
 
LVL 6

Expert Comment

by:riyazthad
Comment Utility
Hi,

You can use Call Stack window. If it is not there in , you can add by just perssing Ctrl+Alt+C or go to Debug menu - > Window -> Call stack while debugging.

Thad
0
 

Author Comment

by:Johnny
Comment Utility
no im looking to do something like

PrintToFile(date & "Connection - useing form/sub " & Form.Name & "/" & Form.Sub.Name & VbCrLf)

or something like that that will print the forms name ie Form1.vb and the Sub Form1_Load


thanks
0
 
LVL 17

Accepted Solution

by:
ZeonFlash earned 500 total points
Comment Utility
Something like this?

        MsgBox("Executing in class '" & Me.Name & "', function '" & Reflection.MethodInfo.GetCurrentMethod.Name)
0
What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

 

Author Comment

by:Johnny
Comment Utility
Error      3      'Name' is not a member of 'IrcMX.EndPoint'.      D:\temp\phreikchat\phreikchat\phreikchat\IrcMX\src\connectivity\endpoint.vb      569      70      IrcMX.Net
0
 
LVL 6

Expert Comment

by:riyazthad
Comment Utility
Is EndPoint your form?

I hope you are doing from VS. not using vbc command utility. And make sure your class is inheriting from System.Windows.Forms.form class.

Where you are executing this above code? I hope ZeonFlash's code will work out for your requirement.

Thad
0
 

Author Comment

by:Johnny
Comment Utility
endpoint is the file its in...there is no form(design) there... its a modual i think

and im useing vb express...

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

I think the Typed DataTable and Typed DataSet are very good options when working with data, but I don't like auto-generated code. First, I create an Abstract Class for my DataTables Common Code.  This class Inherits from DataTable. Also, it can …
A while ago, I was working on a Windows Forms application and I needed a special label control with reflection (glass) effect to show some titles in a stylish way. I've always enjoyed working with graphics, but it's never too clever to re-invent …
It is a freely distributed piece of software for such tasks as photo retouching, image composition and image authoring. It works on many operating systems, in many languages.
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now