Rami's profileYou must enter a title b...PhotosBlogListsMore Tools Help

Rami Shareef

Occupation
Location
Interests
Normal guy, living normal life, how do I hate that, looking forward with hope to the future
Here Without You
Welcome To The Black Parade
Field of Innocence
Regret
November 04

Make your DotNetNuke Module Searchable

Hi,
If you were from those who using DotNetNuke content management system, and you have your own customized module, and wondering how to make these modules searchable, Do the following:

1- Go to your Controller class in your module (or any name you naming the class, the class which handle database requests, usually called [moduleName]Controller), and make it implements ISearchable Interface
VB:
Implements Entities.Modules.ISearchable
C#:
: Entities.Modules.ISearchable

2- Implement GetSearchItems function
VB:
Public Function GetSearchItems(ByVal ModInfo As Entities.Modules.ModuleInfo) _ As Services.Search.SearchItemInfoCollection Implements Entities.Modules.ISearchable.GetSearchItems ' Get the Surveys for this Module instance
Dim colSurveys As List(Of SurveyInfo) = GetSurveys(ModInfo.ModuleID)
Dim SearchItemCollection As New SearchItemInfoCollection
Dim SurveyInfo As SurveyInfo
For Each SurveyInfo In colSurveys
Dim SearchItem As SearchItemInfo SearchItem = New SearchItemInfo _
(ModInfo.ModuleTitle & " - " & SurveyInfo.Question, _ SurveyInfo.Question, _ SurveyInfo.CreatedByUser, _ SurveyInfo.CreatedDate, ModInfo.ModuleID, _ SurveyInfo.SurveyId, _ SurveyInfo.Question) SearchItemCollection.Add(SearchItem) Next
Return SearchItemCollection
End Function

C#:
public SearchItemInfoCollection GetSearchItems(DotNetNuke.Entities.Modules.ModuleInfo ModInfo)
{
// Get the Surveys for this Module instance
List<SurveyInfo> colSurveys = GetSurveys(ModInfo.ModuleID);
SearchItemInfoCollection SearchItemCollection = new SearchItemInfoCollection();
foreach (SurveyInfo SurveyInfo in colSurveys)
{
 SearchItemInfo SearchItem; SearchItem = new SearchItemInfo (ModInfo.ModuleTitle + " - " + SurveyInfo.Question, SurveyInfo.Question, SurveyInfo.CreatedByUser, SurveyInfo.CreatedDate, ModInfo.ModuleID, Convert.ToString(SurveyInfo.SurveyId), SurveyInfo.Question); SearchItemCollection.Add(SearchItem);
}
return SearchItemCollection;
}

Now these search items will be saved in DNN database to perform search operation on them

3- Go to your module definition page and under supported Features you can see 'searchable' is checked, which mean it has been activated

Thank you

November 03

Unable to start debugging on the web server. The type initializer for 'System.Net.DigestClinet' threw an exception.

If you have troubled with this exception when trying to start debugging your web application that hosted in IIS, try on of the following:

·         Check if there is any DLL in bin directory called Security.dll, and rename it using its own project

·         Check IIS ASP.NET Version, should be 2.0….

·         Check web.config for

o   <configuration>
  <system.net>
    <authenticationModules>
      <add type="System.Net.DigestClient" />
    </authenticationModules>
  </system.net>
</configuration>

o   and see if something looks odd (like some incorrect values for Version for the System.Net.DigestClient authentication module.

References:

http://social.msdn.microsoft.com/forums/en-US/vsdebug/thread/9d30fcfd-c872-478c-817e-52e184eb5e55/

http://social.msdn.microsoft.com/forums/en-US/vsdebug/thread/a79fb2ce-8ac6-4092-831b-9858aef72102/

September 11

JavaScript Debugger

Recently at work, I asked to build a web-based report designer, and this must be all at client side, so I turned to play around with JavaScript, it sounds pretty until I reach the point where I have to debug dozen lines of code, classes, functions…. Especially when I have to debug mouseMove event, watching width, height, left, top properties.

Window.alert() does not serve me, so I workaround this and try to make my debugging more dynamic, writing specific value, watching variables …

Div element was the hero in this battle, I put div and dynamically I started to write my individual values and properties to it using .innerHTML property, and everything seems to be okay.

After debugging and writing 10 values, I want to change the values I debugged and watching new values, so I started to comment all last wrote values , It starts to bother me,  type comment operator then remove it, type remove type remove….

So I decided to build a small javaScript debugger using div element as a primary element

I wrote I jsDebugger class and start to put methods support our goals

·         Write(string) //to write to debugging board(div)

·         WriteLine(string)//to write on debugging board with new line

·         Clear()//clears debugging board

·         stopDebugging()//stop writing values on debugging board so you don't have to go an comments all wrote values : )

 

One last thing, you can configure jsDebugger using a config object in constructor (it's optional)

 

Configuration contains

writingColor // the color of write

height//the height of debugging board (div)

bgColor// div background color

borderWidth// div border width

borderStyle// div border style

borderColor// div border color

fontFamily// writing font type

fontSize// writing font size

enabled:true// enable or disable jsDebugger

 

Like this

d = new jsDebugger( {

        writingColor:"black",

        height:"auto",

        bgColor:"#D0CFCC",

        borderWidth:"3px",

        borderStyle:"solid",

        borderColor:"gray",

        fontFamily:"Calibri",

        fontSize:"15px",

        enabled:true}

    );


Downloads:

July 03

Environment Variables Editor - Path Edition

Environment Variables Editor - Path Edition  C#.NET based code tool

(Environment Variables) simply are variables, that store information about your computer, these variables created by windows operating system.
Environment Variables contains part called user variables, and one of (User variables) variables called (path), this variable store paths separated by ( ; ) each variable refer to a path in your hard disk, this stored paths used for fast access.
fast access can be done by using run program (win + r ) or (start --> Run...), and typing the name of the file or folder that you want access (open)

Image

e.g. let's assume that we have the following directory (folder)
D:\pics\friends\summerParty
and you want access to summerParty folder.
all you have to do is add D:\pics\friends\summerParty to (path) environment variables mentioned before (only once)
and then use Run... program (win + r ) and type (summerParty) and the folder will open for you

you can save a lot of time be using something like this

This tool allow users to modify (path) variable to meet their needs.
All questions, suggestion, bugs are welcome

Note: by adding (D:\pics\friends\summerParty ) you can only fast accessing the folders and files stored inside summerParty folder
Need .Net Framework 2.0 or higher

Downloads:
Envaironment Variable Editor - Path Edition

June 14

Gradient Brush Tool

Gradient Brush tool (another generation code)
In these days as we know, Visualization takes an Important part in software manufacture, there for companies of programming languages (who creates and improve the PL) goes to take care of visualization issues, and starts to create and support things like ( classes, method) to implement visualization issues.

http://lastown.com/files/dl.php/download/307/0121618209022e3bc701ef1e581679d1/GBGenerator.JPG 

Gradient Brush tool: is a small tool, allows developers to generate a block of code,which can easily set a [b]Gradient color[/b] for form's background.
how can I use this ?:
This tool oriented to developers, programmers who use C# as programming language, all you have to do is to set "Blend factors "using track bars and see if the corresponding gradient are good for you, after that you have to get the responsible code which can create the selected gradient, Click "Generate Code" and copy generated code "Copy all code" then paste it inside the "paint" Event for your form.... and enjoy watching your gradient  :) 
to create paint event, go to properties window, then to Events tab (his icon like lightening) and search for paint, then double click it !

have a good try !
all suggestions, bugs  are welcome

GradientBrushTool.exe

Note: it needs .NET Frame Work 2.0 or higher

 

Space State


free hit counters
Welcome to my space !
a nice sites that talking about programming languages and such as
Thanks for passing by Smile
I appreciate that
yours holy_spirit
Please wait...
Sorry, the comment you entered is too long. Please shorten it.
You didn't enter anything. Please try again.
Sorry, we can't add your comment right now. Please try again later.
To add a comment, you need permission from your parent. Ask for permission
Your parent has turned off comments.
Sorry, we can't delete your comment right now. Please try again later.
You've exceeded the maximum number of comments that can be left in one day. Please try again in 24 hours.
Your account has had the ability to leave comments disabled because our systems indicate that you may be spamming other users. If you believe that your account has been disabled in error please contact Windows Live support.
Complete the security check below to finish leaving your comment.
The characters you type in the security check must match the characters in the picture or audio.
Majd Eddinwrote:
Nice space bro
 
Keep Going, plz
and happy birthday dear brother?

Gift with a bow
Jan. 19
Rahaf shwrote:
شو هالترحيب .....متل راتبك....كبييير
هه
 
Dec. 28